From: Jonathan Cameron <jic23@kernel.org>
To: Joshua Crofts via B4 Relay <devnull+joshua.crofts1.gmail.com@kernel.org>
Cc: joshua.crofts1@gmail.com, "David Lechner" <dlechner@baylibre.com>,
"Nuno Sá" <nuno.sa@analog.com>,
"Andy Shevchenko" <andy@kernel.org>,
linux-iio@vger.kernel.org, linux-kernel@vger.kernel.org,
"Andy Shevchenko" <andriy.shevchenko@linux.intel.com>
Subject: Re: [PATCH v8 5/5] iio: magnetometer: ak8975: make use of the macros from bits.h
Date: Wed, 20 May 2026 16:38:03 +0100 [thread overview]
Message-ID: <20260520163803.161541e3@jic23-huawei> (raw)
In-Reply-To: <20260518-magnetometer-fixes-post-pickup-v8-5-088d610108a0@gmail.com>
On Mon, 18 May 2026 09:50:29 +0200
Joshua Crofts via B4 Relay <devnull+joshua.crofts1.gmail.com@kernel.org> wrote:
> From: Andy Shevchenko <andriy.shevchenko@linux.intel.com>
>
> Make use of BIT() and GENMASK() where it makes sense.
>
> Signed-off-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com>
> Reviewed-by: Nuno Sá <nuno.sa@analog.com>
> Co-developed-by: Joshua Crofts <joshua.crofts1@gmail.com>
> Signed-off-by: Joshua Crofts <joshua.crofts1@gmail.com>
>
> @@ -858,7 +851,10 @@ static const struct iio_chan_spec ak8975_channels[] = {
> IIO_CHAN_SOFT_TIMESTAMP(AK8975_SCAN_TS),
> };
>
> -static const unsigned long ak8975_scan_masks[] = { 0x7, 0 };
> +static const unsigned long ak8975_scan_masks[] = {
> + BIT(AK8975_SCAN_X) | BIT(AK8975_SCAN_Y) | BIT(AK8975_SCAN_Z),
Ah. Here it is. Fair enough.
Maybe I'll remember it next time!
> + 0
> +};
>
> static const struct iio_info ak8975_info = {
> .read_raw = &ak8975_read_raw,
>
prev parent reply other threads:[~2026-05-20 15:38 UTC|newest]
Thread overview: 10+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-05-18 7:50 [PATCH v8 0/5] iio: magnetometer: ak8975: driver cleanup Joshua Crofts via B4 Relay
2026-05-18 7:50 ` [PATCH v8 1/5] iio: magnetometer: ak8975: switch to using managed resources Joshua Crofts via B4 Relay
2026-05-20 15:31 ` Jonathan Cameron
2026-05-21 7:06 ` Joshua Crofts
2026-05-18 7:50 ` [PATCH v8 2/5] iio: magnetometer: ak8975: unify messages with help of dev_err_probe() Joshua Crofts via B4 Relay
2026-05-18 7:50 ` [PATCH v8 3/5] iio: magnetometer: ak8975: use temporary variable for struct device Joshua Crofts via B4 Relay
2026-05-18 7:50 ` [PATCH v8 4/5] iio: magnetometer: ak8975: add scan mask index enum Joshua Crofts via B4 Relay
2026-05-20 15:37 ` Jonathan Cameron
2026-05-18 7:50 ` [PATCH v8 5/5] iio: magnetometer: ak8975: make use of the macros from bits.h Joshua Crofts via B4 Relay
2026-05-20 15:38 ` Jonathan Cameron [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=20260520163803.161541e3@jic23-huawei \
--to=jic23@kernel.org \
--cc=andriy.shevchenko@linux.intel.com \
--cc=andy@kernel.org \
--cc=devnull+joshua.crofts1.gmail.com@kernel.org \
--cc=dlechner@baylibre.com \
--cc=joshua.crofts1@gmail.com \
--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
all inboxes | Powered by JetHome®