From: sashiko-bot@kernel.org
To: "Romain TISSERAND" <romain.tisserand@gmail.com>
Cc: devicetree@vger.kernel.org, linux-sunxi@lists.linux.dev,
robh@kernel.org, conor+dt@kernel.org
Subject: Re: [PATCH 4/4] iio: adc: Add the PocketGo S30 analog stick MCU
Date: Fri, 27 Nov 2026 01:34:16 +0000 [thread overview]
Message-ID: <sashiko-outbox-236397@kernel.org> (raw)
In-Reply-To: <20261127012612.1589039-5-romain.tisserand@gmail.com>
Thank you for your contribution! Sashiko AI review found 2 potential
issues to consider:
- [Medium] iio: adc: missing vdd-supply regulator enable in
s30_stick_probe()
- [Low] iio: adc: positional initializer in struct i2c_device_id table
s30_stick_id
--
commit c592863ae00c89b0a1034f60c564180d8b5bb825
Author: Romain TISSERAND <romain.tisserand@gmail.com>
iio: adc: Add the PocketGo S30 analog stick MCU
This commit adds an I2C driver for the PocketGo S30 analog stick
microcontroller, exposing the two potentiometer readings as raw IIO
voltage channels.
> diff --git a/drivers/iio/adc/pocketgo-s30-stick.c b/drivers/iio/adc/pocketgo-s30-stick.c
> new file mode 100644
> index 0000000000000..09a60cb307d97
> --- /dev/null
> +++ b/drivers/iio/adc/pocketgo-s30-stick.c
[ ... ]
> +static int s30_stick_probe(struct i2c_client *client)
> +{
> + struct device *dev = &client->dev;
> + struct iio_dev *indio_dev;
> + u8 v[2];
> + int ret;
> +
> + indio_dev = devm_iio_device_alloc(dev, 0);
> + if (!indio_dev)
> + return -ENOMEM;
> +
> + ret = s30_stick_read(client, v);
> + if (ret)
> + return dev_err_probe(dev, ret, "no answer from the stick MCU\n");
[Severity: Medium]
Should s30_stick_probe() enable the vdd regulator via
devm_regulator_get_enable(dev, "vdd") before communicating with the MCU?
The miyoo,pocketgo-s30-stick device tree binding declares vdd-supply. If
a board wires vdd-supply to a switchable regulator, the MCU can be
unpowered during probe or powered off at late_initcall when the regulator
core disables unused supplies.
[ ... ]
> +static const struct i2c_device_id s30_stick_id[] = {
> + { "pocketgo-s30-stick" },
> + { }
> +};
[Severity: Low]
This isn't a bug, but I2C subsystem convention prefers named initializers
({ .name = "pocketgo-s30-stick" }) for struct i2c_device_id entries.
--
Sashiko AI review · https://sashiko.dev/#/patchset/20261127012612.1589039-1-romain.tisserand@gmail.com?part=4
next prev parent reply other threads:[~2026-11-27 1:34 UTC|newest]
Thread overview: 14+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-11-27 1:26 [PATCH 0/4] iio: adc: Add the Miyoo A30 and PocketGo S30 analog stick MCUs Romain TISSERAND
2026-11-27 1:26 ` [PATCH 1/4] dt-bindings: iio: adc: Add the Miyoo A30 analog stick MCU Romain TISSERAND
2026-11-27 1:26 ` [PATCH 2/4] " Romain TISSERAND
2026-11-27 1:40 ` sashiko-bot
2026-11-27 8:47 ` Uwe Kleine-König
2026-11-28 2:21 ` Jonathan Cameron
2026-11-27 1:26 ` [PATCH 3/4] dt-bindings: iio: adc: Add the PocketGo S30 " Romain TISSERAND
2026-11-27 1:26 ` [PATCH 4/4] " Romain TISSERAND
2026-11-27 1:34 ` sashiko-bot [this message]
2026-11-28 2:33 ` Jonathan Cameron
2026-11-28 16:29 ` Romain TISSERAND
2026-11-27 11:49 ` [PATCH 0/4] iio: adc: Add the Miyoo A30 and PocketGo S30 analog stick MCUs Andy Shevchenko
2026-11-28 2:11 ` Jonathan Cameron
2026-11-28 16:29 ` Romain TISSERAND
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=sashiko-outbox-236397@kernel.org \
--to=sashiko-bot@kernel.org \
--cc=conor+dt@kernel.org \
--cc=devicetree@vger.kernel.org \
--cc=linux-sunxi@lists.linux.dev \
--cc=robh@kernel.org \
--cc=romain.tisserand@gmail.com \
--cc=sashiko-reviews@lists.linux.dev \
/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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.