Re: [PATCH] staging: mfd: hi6421-spmi-pmic: fix error return code in hi6421_spmi_pmic_probe()

2020-11-18 Thread Dan Carpenter
Not necessarily related to your patch but it should just return -ENOMEM instead of the "goto irq_malloc;". drivers/staging/hikey9xx/hi6421-spmi-pmic.c 251 if (!gpio_is_valid(pmic->gpio)) 252 return -EINVAL; 253 254 ret = devm_gpio_request_one(dev,

[PATCH] staging: mfd: hi6421-spmi-pmic: fix error return code in hi6421_spmi_pmic_probe()

2020-11-18 Thread Wang Hai
Fix to return a negative error code from the error handling case instead of 0, as done elsewhere in this function. Fixes: 4524ac56cdca ("staging: mfd: add a PMIC driver for HiSilicon 6421 SPMI version") Reported-by: Hulk Robot Signed-off-by: Wang Hai ---