Linux-ARM-Kernel Archive on lore.kernel.org
 help / color / mirror / Atom feed
From: Jonathan Cameron <jic23@kernel.org>
To: mdshahid03@gmail.com
Cc: "Jonathan Cameron" <jic23@kernel.org>,
	"Marcelo Schmitt" <marcelo.schmitt1@gmail.com>,
	"David Lechner" <dlechner@baylibre.com>,
	"Nuno Sá" <nuno.sa@analog.com>,
	"Andy Shevchenko" <andy@kernel.org>,
	"Ray Jui" <rjui@broadcom.com>,
	"Scott Branden" <sbranden@broadcom.com>,
	bcm-kernel-feedback-list@broadcom.com, linux-iio@vger.kernel.org,
	linux-arm-kernel@lists.infradead.org,
	linux-kernel@vger.kernel.org
Subject: Re: [PATCH v2 3/5] iio: adc: bcm_iproc_adc: use devm-managed cleanup
Date: Sun, 30 Aug 2026 21:18:41 +0100	[thread overview]
Message-ID: <178812112191.2788519.1724251718821055090.b4-review@b4> (raw)
In-Reply-To: <20260830170919.470974-4-mdshahid03@gmail.com>

> Use devm_clk_get_enabled() to manage the ADC clock and
> devm_add_action_or_reset() to manage ADC cleanup.
> 
> Since the clock is only needed during probe, keep it as a local
> variable instead of storing it in struct iproc_adc_priv.
>

Given this section needed discussion...

> Register the ADC cleanup action immediately after enabling the ADC
> so that it is automatically performed on probe failure and device
> removal.

I would have left this for a follow up patch rather than
doing it in this one. Here it is not really the number of changes but
rather focusing the reasoning on one thing.  Even without that
splitting the two changes would have been fine.

> 
> This removes the manual clock cleanup callback and simplifies the
> probe error paths.
> 
> Signed-off-by: Mohammad Shahid <mdshahid03@gmail.com>

Otherwise LGTM.  Note this is a minor thing so if nothing else
comes up after we've let this sit for a few days on the list
I'll probably apply it as it stands anyway.

Thanks,

Jonathan

-- 
Jonathan Cameron <jonathan.cameron@oss.qualcomm.com>


  reply	other threads:[~2026-08-30 20:19 UTC|newest]

Thread overview: 13+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-08-30 17:09 [PATCH v2 0/5] iio: adc: bcm_iproc_adc: use device-managed resources mdshahid03
2026-08-30 17:09 ` [PATCH v2 1/5] iio: adc: bcm_iproc_adc: sort headers alphabetically mdshahid03
2026-08-30 17:09 ` [PATCH v2 2/5] iio: adc: bcm_iproc_adc: fix include dependencies mdshahid03
2026-09-01  2:27   ` Marcelo Schmitt
2026-09-01  3:16     ` Jonathan Cameron
2026-09-01  6:57     ` Andy Shevchenko
2026-08-30 17:09 ` [PATCH v2 3/5] iio: adc: bcm_iproc_adc: use devm-managed cleanup mdshahid03
2026-08-30 20:18   ` Jonathan Cameron [this message]
2026-08-30 17:09 ` [PATCH v2 4/5] iio: adc: bcm_iproc_adc: use devm-managed mutex initialization mdshahid03
2026-08-30 17:09 ` [PATCH v2 5/5] iio: adc: bcm_iproc_adc: use devm_iio_device_register() mdshahid03
2026-08-30 20:18   ` Jonathan Cameron
2026-09-01  2:13   ` Marcelo Schmitt
2026-09-01 14:40 ` [PATCH v2 0/5] iio: adc: bcm_iproc_adc: use device-managed resources mdshahid03

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=178812112191.2788519.1724251718821055090.b4-review@b4 \
    --to=jic23@kernel.org \
    --cc=andy@kernel.org \
    --cc=bcm-kernel-feedback-list@broadcom.com \
    --cc=dlechner@baylibre.com \
    --cc=linux-arm-kernel@lists.infradead.org \
    --cc=linux-iio@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=marcelo.schmitt1@gmail.com \
    --cc=mdshahid03@gmail.com \
    --cc=nuno.sa@analog.com \
    --cc=rjui@broadcom.com \
    --cc=sbranden@broadcom.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