From: Jorijn van der Graaf <jorijnvdgraaf@catcrafts.net>
To: Jonathan Cameron <jic23@kernel.org>, linux-iio@vger.kernel.org
Cc: "David Lechner" <dlechner@baylibre.com>,
"Nuno Sá" <nuno.sa@analog.com>,
"Andy Shevchenko" <andy@kernel.org>,
"Rob Herring" <robh@kernel.org>,
"Krzysztof Kozlowski" <krzk+dt@kernel.org>,
"Conor Dooley" <conor+dt@kernel.org>,
devicetree@vger.kernel.org, "Kees Cook" <kees@kernel.org>,
"Gustavo A . R . Silva" <gustavoars@kernel.org>,
linux-hardening@vger.kernel.org, linux-kernel@vger.kernel.org,
"Luca Weiss" <luca.weiss@fairphone.com>,
"Jorijn van der Graaf" <jorijnvdgraaf@catcrafts.net>,
"Andy Shevchenko" <andriy.shevchenko@intel.com>
Subject: [PATCH v2 1/5] iio: light: stk3310: lower-case the i2c device ID names
Date: Wed, 26 Aug 2026 19:54:05 +0200 [thread overview]
Message-ID: <20260826175409.326131-2-jorijnvdgraaf@catcrafts.net> (raw)
In-Reply-To: <20260826175409.326131-1-jorijnvdgraaf@catcrafts.net>
The i2c device IDs were introduced in capitals, mirroring the ACPI
_HID entries added by the same commit be9e6229d676 ("iio: light: Add
support for Sensortek STK3310"); at that point the driver enumerated
through ACPI only, with no OF table and no i2c module alias export.
ACPI _HIDs have their own naming rules; i2c device names
conventionally use the lower-case part name, matching the devicetree
compatible suffix.
The spelling is visible: a client instantiated through the i2c sysfs
interface under the lower-case name taken from a compatible string
binds through the OF table's name fallback, but has no firmware node,
so i2c_match_id() is the only way for it to reach driver match data,
and its string comparison is case-sensitive, so the capitals can never
match. Lower-case the names so such clients match the id table, and
receive the per-chip match data a subsequent change attaches to it.
The module aliases follow the rename (i2c:STK3310 becomes
i2c:stk3310), and a sysfs client instantiated under a capitals name no
longer binds.
Suggested-by: Andy Shevchenko <andriy.shevchenko@intel.com>
Assisted-by: Claude:claude-fable-5
Signed-off-by: Jorijn van der Graaf <jorijnvdgraaf@catcrafts.net>
---
drivers/iio/light/stk3310.c | 8 ++++----
1 file changed, 4 insertions(+), 4 deletions(-)
diff --git a/drivers/iio/light/stk3310.c b/drivers/iio/light/stk3310.c
index 7c8a1d2b2ed0..5b5b6812edc7 100644
--- a/drivers/iio/light/stk3310.c
+++ b/drivers/iio/light/stk3310.c
@@ -766,10 +766,10 @@ static DEFINE_SIMPLE_DEV_PM_OPS(stk3310_pm_ops, stk3310_suspend,
stk3310_resume);
static const struct i2c_device_id stk3310_i2c_id[] = {
- { .name = "STK3013" },
- { .name = "STK3310" },
- { .name = "STK3311" },
- { .name = "STK3335" },
+ { .name = "stk3013" },
+ { .name = "stk3310" },
+ { .name = "stk3311" },
+ { .name = "stk3335" },
{ }
};
MODULE_DEVICE_TABLE(i2c, stk3310_i2c_id);
--
2.55.0
next prev parent reply other threads:[~2026-08-26 17:54 UTC|newest]
Thread overview: 13+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-08-26 17:54 [PATCH v2 0/5] iio: light: stk3310: per-chip match data and STK36C61 support Jorijn van der Graaf
2026-08-26 17:54 ` Jorijn van der Graaf [this message]
2026-08-26 18:03 ` [PATCH v2 1/5] iio: light: stk3310: lower-case the i2c device ID names sashiko-bot
2026-08-27 6:45 ` Andy Shevchenko
2026-08-26 17:54 ` [PATCH v2 2/5] dt-bindings: iio: light: stk33xx: document the Sensortek STK36C61 Jorijn van der Graaf
2026-08-26 17:54 ` [PATCH v2 3/5] iio: light: stk3310: move the data registers into the channel address Jorijn van der Graaf
2026-08-26 18:07 ` sashiko-bot
2026-08-27 6:47 ` Andy Shevchenko
2026-08-26 17:54 ` [PATCH v2 4/5] iio: light: stk3310: add per-chip match data Jorijn van der Graaf
2026-08-26 18:03 ` sashiko-bot
2026-08-27 7:47 ` Andy Shevchenko
2026-08-26 17:54 ` [PATCH v2 5/5] iio: light: stk3310: support the Sensortek STK36C61 Jorijn van der Graaf
2026-08-27 7:53 ` 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=20260826175409.326131-2-jorijnvdgraaf@catcrafts.net \
--to=jorijnvdgraaf@catcrafts.net \
--cc=andriy.shevchenko@intel.com \
--cc=andy@kernel.org \
--cc=conor+dt@kernel.org \
--cc=devicetree@vger.kernel.org \
--cc=dlechner@baylibre.com \
--cc=gustavoars@kernel.org \
--cc=jic23@kernel.org \
--cc=kees@kernel.org \
--cc=krzk+dt@kernel.org \
--cc=linux-hardening@vger.kernel.org \
--cc=linux-iio@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=luca.weiss@fairphone.com \
--cc=nuno.sa@analog.com \
--cc=robh@kernel.org \
/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