mmc: core: Normalize the error handling branch in sd_read_ext_regs()
authorZhen Lei <thunder.leizhen@huawei.com>
Wed, 30 Nov 2022 13:49:20 +0000 (21:49 +0800)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Sat, 31 Dec 2022 12:14:17 +0000 (13:14 +0100)
commitecf1b317a86bbc7115da01f1c79c603dcaf80bb9
tree5842b3668c4d6136791e759bc89bc2566257fe5c
parent7fecca429e6eb5b6f4a8e8d3f8c75212aedfb0d7
mmc: core: Normalize the error handling branch in sd_read_ext_regs()

[ Upstream commit fc02e2b52389c8fde02852b2f959c0b45f042bbd ]

Let's use pr_err() to output the error messages and let's extend a comment
to clarify why returning 0 (success) in one case make sense.

Fixes: c784f92769ae ("mmc: core: Read the SD function extension registers for power management")
Signed-off-by: Zhen Lei <thunder.leizhen@huawei.com>
[Ulf: Clarified the comment and the commit-msg]
Link: https://lore.kernel.org/r/20221130134920.2109-1-thunder.leizhen@huawei.com
Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org>
Signed-off-by: Sasha Levin <sashal@kernel.org>
drivers/mmc/core/sd.c