浏览代码

backlight: PTR_ERR return of wrong pointer in cr_backlight_probe()

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>
Roel Kluin 15 年之前
父节点
当前提交
5b0582ea42
共有 1 个文件被更改,包括 1 次插入1 次删除
  1. 1 1
      drivers/video/backlight/cr_bllcd.c

+ 1 - 1
drivers/video/backlight/cr_bllcd.c

@@ -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,