backlight: PTR_ERR return of wrong pointer in cr_backlight_probe()
authorRoel Kluin <roel.kluin@gmail.com>
Mon, 7 Dec 2009 13:35:32 +0000 (14:35 +0100)
committerRichard Purdie <rpurdie@linux.intel.com>
Thu, 17 Dec 2009 11:19:07 +0000 (11:19 +0000)
Return the PTR_ERR of the correct pointer.

Signed-off-by: Roel Kluin <roel.kluin@gmail.com>
Signed-off-by: Richard Purdie <rpurdie@linux.intel.com>
drivers/video/backlight/cr_bllcd.c

index 2914bf1..da86db4 100644 (file)
@@ -201,7 +201,7 @@ static int cr_backlight_probe(struct platform_device *pdev)
        if (IS_ERR(ldp)) {
                backlight_device_unregister(bdp);
                pci_dev_put(lpc_dev);
-               return PTR_ERR(bdp);
+               return PTR_ERR(ldp);
        }
 
        pci_read_config_dword(lpc_dev, CRVML_REG_GPIOBAR,