]> git.baikalelectronics.ru Git - kernel.git/commit
rtc: sunplus: fix return value in sp_rtc_probe()
authorYang Yingliang <yangyingliang@huawei.com>
Thu, 6 Jan 2022 07:57:11 +0000 (15:57 +0800)
committerAlexandre Belloni <alexandre.belloni@bootlin.com>
Sun, 16 Jan 2022 22:50:34 +0000 (23:50 +0100)
commit0ac2b4e8b2af3fbf44749a10fe0b7ee87b2afc38
tree7c25b3d731341cbc0c00aebcb75710fc46349f55
parent42f27261f868fe26bd38cff6d10cb705822fe234
rtc: sunplus: fix return value in sp_rtc_probe()

If devm_ioremap_resource() fails, it should return error
code from sp_rtc->reg_base in sp_rtc_probe().

Fixes: 50480315741c ("rtc: Add driver for RTC in Sunplus SP7021")
Reported-by: Hulk Robot <hulkci@huawei.com>
Signed-off-by: Yang Yingliang <yangyingliang@huawei.com>
Signed-off-by: Alexandre Belloni <alexandre.belloni@bootlin.com>
Link: https://lore.kernel.org/r/20220106075711.3216468-1-yangyingliang@huawei.com
drivers/rtc/rtc-sunplus.c