提交 c155ba88 编写于 作者: W Wolfram Sang

i2c: sun6i-p2wi: use proper return value in probe

Fixes:
>> drivers/i2c/busses/i2c-sun6i-p2wi.c:243:10: warning: 'ret' may be used uninitialized in this function [-Wmaybe-uninitialized]
Reported-by: Nkbuild test robot <fengguang.wu@intel.com>
Signed-off-by: NWolfram Sang <wsa@the-dreams.de>
上级 3e833490
......@@ -240,7 +240,7 @@ static int p2wi_probe(struct platform_device *pdev)
snprintf(p2wi->adapter.name, sizeof(p2wi->adapter.name), pdev->name);
irq = platform_get_irq(pdev, 0);
if (irq < 0) {
dev_err(dev, "failed to retrieve irq: %d\n", ret);
dev_err(dev, "failed to retrieve irq: %d\n", irq);
return irq;
}
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册