Input: gf2k - fix &&/|| confusion in gf2k_connect()
authorRoel Kluin <roel.kluin@gmail.com>
Sat, 2 Jan 2010 02:35:11 +0000 (18:35 -0800)
committerDmitry Torokhov <dmitry.torokhov@gmail.com>
Sat, 2 Jan 2010 02:45:52 +0000 (18:45 -0800)
This always evaluates to true.

Signed-off-by: Roel Kluin <roel.kluin@gmail.com>
Signed-off-by: Dmitry Torokhov <dtor@mail.ru>
drivers/input/joystick/gf2k.c

index 67c207f5b1a16cd56e88b140c63bbfdefb8f498b..45ac70eae0aa7d95e5a61118cb45456b20abacea 100644 (file)
@@ -277,7 +277,7 @@ static int gf2k_connect(struct gameport *gameport, struct gameport_driver *drv)
        }
 
 #ifdef RESET_WORKS
-       if ((gf2k->id != (GB(19,2,0) | GB(15,3,2) | GB(12,3,5))) ||
+       if ((gf2k->id != (GB(19,2,0) | GB(15,3,2) | GB(12,3,5))) &&
            (gf2k->id != (GB(31,2,0) | GB(27,3,2) | GB(24,3,5)))) {
                err = -ENODEV;
                goto fail2;