From: Andy Shevchenko <andriy.shevchenko@intel.com>
To: Archit Anant <architanant5@gmail.com>
Cc: jic23@kernel.org, dlechner@baylibre.com, lars@metafoo.de,
Michael.Hennerich@analog.com, nuno.sa@analog.com,
andy@kernel.org, linux-iio@vger.kernel.org,
linux-kernel@vger.kernel.org
Subject: Re: [PATCH v8 0/5] iio: adc: ad799x: modernize resource management
Date: Tue, 14 Apr 2026 20:09:58 +0300 [thread overview]
Message-ID: <ad505ojCcZgkyIFg@ashevche-desk.local> (raw)
In-Reply-To: <20260412093739.17116-1-architanant5@gmail.com>
On Sun, Apr 12, 2026 at 03:07:34PM +0530, Archit Anant wrote:
> This series modernizes the ad799x driver by converting resource
> management to the devm_ infrastructure. This results in cleaner
> probe error handling, the removal of the ad799x_remove() function,
> and improved overall code maintainability and safety.
>
> Key changes in this series include:
> - A prerequisite cleanup to sort headers alphabetically.
> - Static allocation of the rx_buf using IIO_DECLARE_BUFFER_WITH_TS()
> to avoid dynamic memory leaks during scan mode updates.
> - Caching of VCC and VREF regulator voltages during probe() to
> optimize read_raw() performance and simplify power management logic.
> - Migration of regulators and mutex initialization to device-managed
> resources (devm).
> - Fixing a potential race condition by moving mutex initialization
> before IRQ registration.
> - Removal of the manual ad799x_remove() function and all goto-based
> error cleanup labels in ad799x_probe().
>
> These changes ensure the teardown sequence is always correct,
> following the reverse order of allocation, and remove unnecessary
> boilerplate code from the driver.
Some pieces still can be polished, but this is good enough, let's go with it!
Reviewed-by: Andy Shevchenko <andriy.shevchenko@intel.com>
--
With Best Regards,
Andy Shevchenko
prev parent reply other threads:[~2026-04-14 17:10 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-04-12 9:37 [PATCH v8 0/5] iio: adc: ad799x: modernize resource management Archit Anant
2026-04-12 9:37 ` [PATCH v8 1/5] iio: adc: ad799x: sort headers alphabetically Archit Anant
2026-04-12 9:37 ` [PATCH v8 2/5] iio: adc: ad799x: use local device pointer in probe Archit Anant
2026-04-12 9:37 ` [PATCH v8 3/5] iio: adc: ad799x: use a static buffer for scan data Archit Anant
2026-04-12 9:37 ` [PATCH v8 4/5] iio: adc: ad799x: cache regulator voltages during probe Archit Anant
2026-04-12 9:37 ` [PATCH v8 5/5] iio: adc: ad799x: convert to fully managed resources and drop remove() Archit Anant
2026-04-14 17:09 ` Andy Shevchenko [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=ad505ojCcZgkyIFg@ashevche-desk.local \
--to=andriy.shevchenko@intel.com \
--cc=Michael.Hennerich@analog.com \
--cc=andy@kernel.org \
--cc=architanant5@gmail.com \
--cc=dlechner@baylibre.com \
--cc=jic23@kernel.org \
--cc=lars@metafoo.de \
--cc=linux-iio@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=nuno.sa@analog.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