wl1271: fix notifier interface supported test
authorDan Carpenter <error27@gmail.com>
Sat, 8 May 2010 16:25:51 +0000 (18:25 +0200)
committerJohn W. Linville <linville@tuxdriver.com>
Tue, 11 May 2010 19:14:20 +0000 (15:14 -0400)
The "(wl == NULL)" test doesn't work here because "wl" is always
non-null.  The intent of the code is to return if the interface
was not supported by the driver.

Signed-off-by: Dan Carpenter <error27@gmail.com>
Acked-by: Luciano Coelho <luciano.coelho@nokia.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
drivers/net/wireless/wl12xx/wl1271_main.c

index b61cd10..55aa813 100644 (file)
@@ -852,7 +852,7 @@ static int wl1271_dev_notify(struct notifier_block *me, unsigned long what,
                if (wl == wl_temp)
                        break;
        }
-       if (wl == NULL)
+       if (wl != wl_temp)
                return NOTIFY_DONE;
 
        /* Get the interface IP address for the device. "ifa" will become