Linux kernel -stable discussions
 help / color / mirror / Atom feed
From: Johan Hovold <johan@kernel.org>
To: Philipp Zabel <p.zabel@pengutronix.de>
Cc: Maarten Lankhorst <maarten.lankhorst@linux.intel.com>,
	Maxime Ripard <mripard@kernel.org>,
	Thomas Zimmermann <tzimmermann@suse.de>,
	David Airlie <airlied@gmail.com>, Simona Vetter <simona@ffwll.ch>,
	dri-devel@lists.freedesktop.org, imx@lists.linux.dev,
	linux-kernel@vger.kernel.org, stable@vger.kernel.org
Subject: Re: [PATCH] drm/imx/tve: fix probe device leak
Date: Thu, 30 Oct 2025 17:36:03 +0100	[thread overview]
Message-ID: <aQOT8zD1hsK4SJ_c@hovoldconsulting.com> (raw)
In-Reply-To: <89a86fc1c48f921aa3b06146f43a32dc58515548.camel@pengutronix.de>

On Thu, Oct 30, 2025 at 04:27:39PM +0100, Philipp Zabel wrote:
> On Di, 2025-09-23 at 17:13 +0200, Johan Hovold wrote:

> >  static int imx_tve_probe(struct platform_device *pdev)
> >  {
> >  	struct device *dev = &pdev->dev;
> > @@ -546,6 +553,11 @@ static int imx_tve_probe(struct platform_device *pdev)
> >  	if (ddc_node) {
> >  		tve->ddc = of_find_i2c_adapter_by_node(ddc_node);
> >  		of_node_put(ddc_node);
> > +
> > +		ret = devm_add_action_or_reset(dev, imx_tve_put_device,
> > +					       &tve->ddc->dev);
> 
> I think this needs to be wrapped in "if (tve->ddc) { }",
> of_find_i2c_adapter_by_node() can return NULL.

Indeed, thanks for catching that. Just sent a v2.

Johan

      reply	other threads:[~2025-10-30 16:35 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2025-09-23 15:13 [PATCH] drm/imx/tve: fix probe device leak Johan Hovold
2025-09-23 19:26 ` Frank Li
2025-10-27 13:36 ` Johan Hovold
2025-10-30 15:27 ` Philipp Zabel
2025-10-30 16:36   ` Johan Hovold [this message]

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=aQOT8zD1hsK4SJ_c@hovoldconsulting.com \
    --to=johan@kernel.org \
    --cc=airlied@gmail.com \
    --cc=dri-devel@lists.freedesktop.org \
    --cc=imx@lists.linux.dev \
    --cc=linux-kernel@vger.kernel.org \
    --cc=maarten.lankhorst@linux.intel.com \
    --cc=mripard@kernel.org \
    --cc=p.zabel@pengutronix.de \
    --cc=simona@ffwll.ch \
    --cc=stable@vger.kernel.org \
    --cc=tzimmermann@suse.de \
    /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