mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Guangshuo Li <lgs201920130244@gmail.com>
To: Mauro Carvalho Chehab <mchehab@kernel.org>,
	Kees Cook <kees@kernel.org>,
	Guangshuo Li <lgs201920130244@gmail.com>,
	Tomi Valkeinen <tomi.valkeinen@ti.com>,
	linux-media@vger.kernel.org, linux-kernel@vger.kernel.org
Cc: stable@vger.kernel.org
Subject: [PATCH] media: ti: omap: release DSS compatibility layer on remove
Date: Tue, 15 Sep 2026 22:24:40 +0800	[thread overview]
Message-ID: <20260915142440.2442011-1-lgs201920130244@gmail.com> (raw)

omap_vout_probe() calls omapdss_compat_init(), while omap_vout_remove()
does not call the corresponding omapdss_compat_uninit().

The probe failure paths release the DSS compatibility layer, but the
normal remove path leaves it initialized after the video output device
has been removed.

Call omapdss_compat_uninit() during remove after releasing the video
device resources, matching the cleanup performed by the probe failure
paths.

This issue was found by manual code inspection.

Fixes: a9ee9f08b615 ("OMAPDSS: use omapdss_compat_init() in other drivers")
Cc: stable@vger.kernel.org
Signed-off-by: Guangshuo Li <lgs201920130244@gmail.com>
---
 drivers/media/platform/ti/omap/omap_vout.c | 1 +
 1 file changed, 1 insertion(+)

diff --git a/drivers/media/platform/ti/omap/omap_vout.c b/drivers/media/platform/ti/omap/omap_vout.c
index 8d0319a37ba8..0efaff4d343d 100644
--- a/drivers/media/platform/ti/omap/omap_vout.c
+++ b/drivers/media/platform/ti/omap/omap_vout.c
@@ -1586,6 +1586,7 @@ static void omap_vout_remove(struct platform_device *pdev)
 		omap_dss_put_device(vid_dev->displays[k]);
 	}
 	kfree(vid_dev);
+	omapdss_compat_uninit();
 }
 
 static int __init omap_vout_probe(struct platform_device *pdev)
-- 
2.43.0


                 reply	other threads:[~2026-09-15 14:24 UTC|newest]

Thread overview: [no followups] expand[flat|nested]  mbox.gz  Atom feed

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20260915142440.2442011-1-lgs201920130244@gmail.com \
    --to=lgs201920130244@gmail.com \
    --cc=kees@kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-media@vger.kernel.org \
    --cc=mchehab@kernel.org \
    --cc=stable@vger.kernel.org \
    --cc=tomi.valkeinen@ti.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
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®