usb: otg: ab8500-usb: make probe() work again
authorDan Carpenter <dan.carpenter@oracle.com>
Fri, 2 Mar 2012 08:08:14 +0000 (11:08 +0300)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Sat, 3 Mar 2012 00:22:11 +0000 (16:22 -0800)
The probe() function will always fail because we're testing the wrong
variable.

Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com>
Cc: stable <stable@vger.kernel.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/usb/otg/ab8500-usb.c

index e6371ff..a84af67 100644 (file)
@@ -489,7 +489,7 @@ static int __devinit ab8500_usb_probe(struct platform_device *pdev)
                return -ENOMEM;
 
        otg = kzalloc(sizeof *otg, GFP_KERNEL);
-       if (!ab->phy.otg) {
+       if (!otg) {
                kfree(ab);
                return -ENOMEM;
        }