]> git.baikalelectronics.ru Git - kernel.git/commit
fbdev: via: Fix error in via_core_init()
authorShang XiaoJing <shangxiaojing@huawei.com>
Mon, 14 Nov 2022 01:08:52 +0000 (09:08 +0800)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Wed, 18 Jan 2023 10:41:26 +0000 (11:41 +0100)
commit53a73c186c18a63815eab43d70c60427c789471c
tree6d2172d687fd12ca2c2e8cb437d741218a39c679
parent2c2199b76b6661fe54eca5c582a36108f9a7347f
fbdev: via: Fix error in via_core_init()

[ Upstream commit 9eeb358398d5a0be25db4abb4089e4b2875facfa ]

via_core_init() won't exit the driver when pci_register_driver() failed.
Exit the viafb-i2c and the viafb-gpio in failed path to prevent error.

VIA Graphics Integration Chipset framebuffer 2.4 initializing
Error: Driver 'viafb-i2c' is already registered, aborting...
Error: Driver 'viafb-gpio' is already registered, aborting...

Fixes: 251fd1d1d401 ("viafb: Turn GPIO and i2c into proper platform devices")
Signed-off-by: Shang XiaoJing <shangxiaojing@huawei.com>
Signed-off-by: Helge Deller <deller@gmx.de>
Signed-off-by: Sasha Levin <sashal@kernel.org>
drivers/video/fbdev/via/via-core.c