* [PATCH -next] pinctrl: qcom: spmi-mpp: Fix err handling of pmic_mpp_set_mux
@ 2018-09-20 1:58 YueHaibing
2018-09-21 15:18 ` Linus Walleij
0 siblings, 1 reply; 2+ messages in thread
From: YueHaibing @ 2018-09-20 1:58 UTC (permalink / raw)
To: Bjorn Andersson, Linus Walleij
Cc: YueHaibing, linux-arm-msm, linux-gpio, kernel-janitors, linux-kernel
'ret' should be returned while pmic_mpp_write_mode_ctl fails.
Fixes: 0e948042c420 ("pinctrl: qcom: spmi-mpp: Implement support for sink mode")
Signed-off-by: YueHaibing <yuehaibing@huawei.com>
---
drivers/pinctrl/qcom/pinctrl-spmi-mpp.c | 2 ++
1 file changed, 2 insertions(+)
diff --git a/drivers/pinctrl/qcom/pinctrl-spmi-mpp.c b/drivers/pinctrl/qcom/pinctrl-spmi-mpp.c
index 98f6f40..d6ddc47 100644
--- a/drivers/pinctrl/qcom/pinctrl-spmi-mpp.c
+++ b/drivers/pinctrl/qcom/pinctrl-spmi-mpp.c
@@ -319,6 +319,8 @@ static int pmic_mpp_set_mux(struct pinctrl_dev *pctldev, unsigned function,
pad->function = function;
ret = pmic_mpp_write_mode_ctl(state, pad);
+ if (ret < 0)
+ return ret;
val = pad->is_enabled << PMIC_MPP_REG_MASTER_EN_SHIFT;
^ permalink raw reply related [flat|nested] 2+ messages in thread
* Re: [PATCH -next] pinctrl: qcom: spmi-mpp: Fix err handling of pmic_mpp_set_mux
2018-09-20 1:58 [PATCH -next] pinctrl: qcom: spmi-mpp: Fix err handling of pmic_mpp_set_mux YueHaibing
@ 2018-09-21 15:18 ` Linus Walleij
0 siblings, 0 replies; 2+ messages in thread
From: Linus Walleij @ 2018-09-21 15:18 UTC (permalink / raw)
To: yuehaibing
Cc: Bjorn Andersson, linux-arm-msm, open list:GPIO SUBSYSTEM,
kernel-janitors, linux-kernel
On Wed, Sep 19, 2018 at 6:48 PM YueHaibing <yuehaibing@huawei.com> wrote:
> 'ret' should be returned while pmic_mpp_write_mode_ctl fails.
>
> Fixes: 0e948042c420 ("pinctrl: qcom: spmi-mpp: Implement support for sink mode")
> Signed-off-by: YueHaibing <yuehaibing@huawei.com>
Patch applied.
Yours,
Linus Walleij
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2018-09-21 15:18 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2018-09-20 1:58 [PATCH -next] pinctrl: qcom: spmi-mpp: Fix err handling of pmic_mpp_set_mux YueHaibing
2018-09-21 15:18 ` Linus Walleij
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).