From: Vaibhav Chahar <vaibhav.chahar26@gmail.com>
To: jic23@kernel.org, marius.cristea@microchip.com
Cc: crofts@kernel.org, dlechner@baylibre.com, nuno.sa@analog.com,
andy@kernel.org, linux-iio@vger.kernel.org,
linux-kernel@vger.kernel.org,
Vaibhav Chahar <vaibhav.chahar26@gmail.com>
Subject: [PATCH v2 0/2] iio: adc: Use cleanup.h guards for mutex locking
Date: Mon, 23 Nov 2026 22:58:34 +0530 [thread overview]
Message-ID: <20261123172836.130440-1-vaibhav.chahar26@gmail.com> (raw)
In-Reply-To: <20261123070802.14487-1-vaibhav.chahar26@gmail.com>
Modernize mutex locking in the mcp3564 and palmas_gpadc ADC drivers by
replacing manual mutex_lock() and mutex_unlock() calls with cleanup.h
guard(mutex) and scoped_guard() helpers.
Changes in v2:
- Patch 1 (mcp3564): Wrap switch cases containing guard() in braces,
add blank lines around guard() calls, and clean up the commit message.
- Patch 2 (palmas_gpadc): New patch converting palmas_gpadc calls to
guard(mutex).
Vaibhav Chahar (2):
iio: adc: mcp3564: Use guard() and scoped_guard() to manage mutex
iio: adc: palmas_gpadc: Use guard(mutex) to manage locks
drivers/iio/adc/mcp3564.c | 63 +++++++++++++++++++---------------
drivers/iio/adc/palmas_gpadc.c | 46 +++++++++----------------
2 files changed, 53 insertions(+), 56 deletions(-)
--
2.56.0
next prev parent reply other threads:[~2026-11-23 17:29 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-11-23 7:08 [PATCH] iio: adc: mcp3564: Use guard() and scoped_guard() to manage mutex Vaibhav Chahar
2026-11-23 15:22 ` Joshua Crofts
2026-11-23 17:28 ` Vaibhav Chahar [this message]
2026-11-23 17:28 ` [PATCH v2 1/2] " Vaibhav Chahar
2026-11-23 19:05 ` Andy Shevchenko
2026-11-23 17:28 ` [PATCH v2 2/2] iio: adc: palmas_gpadc: Use guard(mutex) to manage locks Vaibhav Chahar
2026-11-23 19:10 ` Andy Shevchenko
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=20261123172836.130440-1-vaibhav.chahar26@gmail.com \
--to=vaibhav.chahar26@gmail.com \
--cc=andy@kernel.org \
--cc=crofts@kernel.org \
--cc=dlechner@baylibre.com \
--cc=jic23@kernel.org \
--cc=linux-iio@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=marius.cristea@microchip.com \
--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
all inboxes | Powered by JetHome®