Commit 0b64150c authored by Krzysztof Kozlowski's avatar Krzysztof Kozlowski Committed by Dmitry Torokhov

Input: bcm-keypad - correct dev_err_probe() error

Pass proper PTR_ERR as dev_err_probe() argument.

Fixes: a2c795b6 ("Input: bcm-keypad - simplify with dev_err_probe()")
Reported-by: default avatarkernel test robot <lkp@intel.com>
Reported-by: default avatarDan Carpenter <dan.carpenter@linaro.org>
Closes: https://lore.kernel.org/r/202306261505.wTjCXRIO-lkp@intel.com/Signed-off-by: default avatarKrzysztof Kozlowski <krzysztof.kozlowski@linaro.org>
Link: https://lore.kernel.org/r/20230711072449.43569-1-krzysztof.kozlowski@linaro.orgSigned-off-by: default avatarDmitry Torokhov <dmitry.torokhov@gmail.com>
parent f1efdf7f
......@@ -359,7 +359,7 @@ static int bcm_kp_probe(struct platform_device *pdev)
/* Enable clock */
kp->clk = devm_clk_get_optional(&pdev->dev, "peri_clk");
if (IS_ERR(kp->clk)) {
return dev_err_probe(&pdev->dev, error, "Failed to get clock\n");
return dev_err_probe(&pdev->dev, PTR_ERR(kp->clk), "Failed to get clock\n");
} else if (!kp->clk) {
dev_dbg(&pdev->dev, "No clock specified. Assuming it's enabled\n");
} else {
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment