* [PATCH] fbdev: s1d13xxxfb: add missed unregister_framebuffer in remove
@ 2019-11-18 8:09 ` Chuhong Yuan
2020-01-15 15:27 ` Bartlomiej Zolnierkiewicz
0 siblings, 1 reply; 2+ messages in thread
From: Chuhong Yuan @ 2019-11-18 8:09 UTC (permalink / raw)
Cc: Kristoffer Ericson, Bartlomiej Zolnierkiewicz, dri-devel,
linux-fbdev, linux-kernel, Chuhong Yuan
The driver calls register_framebuffer in probe but does not call
unregister_framebuffer in remove.
Add the missed call to fix it.
Signed-off-by: Chuhong Yuan <hslester96@gmail.com>
---
drivers/video/fbdev/s1d13xxxfb.c | 1 +
1 file changed, 1 insertion(+)
diff --git a/drivers/video/fbdev/s1d13xxxfb.c b/drivers/video/fbdev/s1d13xxxfb.c
index e04efb567b5c..162003ea6b79 100644
--- a/drivers/video/fbdev/s1d13xxxfb.c
+++ b/drivers/video/fbdev/s1d13xxxfb.c
@@ -729,6 +729,7 @@ s1d13xxxfb_remove(struct platform_device *pdev)
struct s1d13xxxfb_par *par = NULL;
if (info) {
+ unregister_framebuffer(info);
par = info->par;
if (par && par->regs) {
/* disable output & enable powersave */
--
2.24.0
^ permalink raw reply [flat|nested] 2+ messages in thread
* Re: [PATCH] fbdev: s1d13xxxfb: add missed unregister_framebuffer in remove
2019-11-18 8:09 ` [PATCH] fbdev: s1d13xxxfb: add missed unregister_framebuffer in remove Chuhong Yuan
@ 2020-01-15 15:27 ` Bartlomiej Zolnierkiewicz
0 siblings, 0 replies; 2+ messages in thread
From: Bartlomiej Zolnierkiewicz @ 2020-01-15 15:27 UTC (permalink / raw)
To: Chuhong Yuan; +Cc: Kristoffer Ericson, dri-devel, linux-fbdev, linux-kernel
On 11/18/19 9:09 AM, Chuhong Yuan wrote:
> The driver calls register_framebuffer in probe but does not call
> unregister_framebuffer in remove.
> Add the missed call to fix it.
>
> Signed-off-by: Chuhong Yuan <hslester96@gmail.com>
> ---
> drivers/video/fbdev/s1d13xxxfb.c | 1 +
> 1 file changed, 1 insertion(+)
>
> diff --git a/drivers/video/fbdev/s1d13xxxfb.c b/drivers/video/fbdev/s1d13xxxfb.c
> index e04efb567b5c..162003ea6b79 100644
> --- a/drivers/video/fbdev/s1d13xxxfb.c
> +++ b/drivers/video/fbdev/s1d13xxxfb.c
> @@ -729,6 +729,7 @@ s1d13xxxfb_remove(struct platform_device *pdev)
> struct s1d13xxxfb_par *par = NULL;
>
> if (info) {
> + unregister_framebuffer(info);
s1d13xxxfb_remove() is not only called on removal operation but also
by s1d13xxxfb_probe() on register_framebuffer() failure. After above
change the code in s1d13xxxfb_probe() will break. The issue needs to
be fixed in different way, i.e.
- rename existing s1d13xxxfb_remove() to __s1d13xxxfb_remove()
- add s1d13xxxfb_remove() which does unregister_framebuffer() and
then calls __s1d13xxxfb_remove())
> par = info->par;
> if (par && par->regs) {
> /* disable output & enable powersave */
>
Best regards,
--
Bartlomiej Zolnierkiewicz
Samsung R&D Institute Poland
Samsung Electronics
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2020-01-15 15:27 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
[not found] <CGME20191118080914eucas1p2fce1f43568b8453b9d513108df54f384@eucas1p2.samsung.com>
2019-11-18 8:09 ` [PATCH] fbdev: s1d13xxxfb: add missed unregister_framebuffer in remove Chuhong Yuan
2020-01-15 15:27 ` Bartlomiej Zolnierkiewicz
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
all inboxes | Powered by JetHome®