]> git.baikalelectronics.ru Git - kernel.git/commit
video: fbdev: w100fb: Reset global state
authorEvgeny Novikov <novikov@ispras.ru>
Wed, 11 Aug 2021 16:58:26 +0000 (19:58 +0300)
committerHelge Deller <deller@gmx.de>
Sat, 29 Jan 2022 21:24:26 +0000 (22:24 +0100)
commit021ece98d8d2d4be05f7b9a46e462f4910e280db
treea8b0139676d6e97dbe98d6dd1ffa327848dff672
parent7433e8977702c64b8d209aa6173035e19922621a
video: fbdev: w100fb: Reset global state

w100fb_probe() did not reset the global state to its initial state. This
can result in invocation of iounmap() even when there was not the
appropriate successful call of ioremap(). For instance, this may be the
case if first probe fails after two successful ioremap() while second
probe fails when first ioremap() fails. The similar issue is with
w100fb_remove(). The patch fixes both bugs.

Found by Linux Driver Verification project (linuxtesting.org).

Signed-off-by: Evgeny Novikov <novikov@ispras.ru>
Co-developed-by: Kirill Shilimanov <kirill.shilimanov@huawei.com>
Signed-off-by: Kirill Shilimanov <kirill.shilimanov@huawei.com>
Signed-off-by: Helge Deller <deller@gmx.de>
drivers/video/fbdev/w100fb.c