]> git.ipfire.org Git - thirdparty/openwrt.git/commit
realtek: i2c: fix i2c-shared-gpio range check
authorMarkus Stockhausen <markus.stockhausen@gmx.de>
Sat, 21 Mar 2026 13:01:23 +0000 (14:01 +0100)
committerRobert Marko <robimarko@gmail.com>
Wed, 25 Mar 2026 09:28:10 +0000 (10:28 +0100)
commit323b75002be50f181fee706d455f4de50be3f06d
tree908ea3d69160423c2a5fb087af7643efb1df0dda
parent28165ed3d4dbbecf3ff92971a01e250e67113294
realtek: i2c: fix i2c-shared-gpio range check

The i2c-shared-gpio driver is designed to emulate up to four
i2c busses with distinct sda lines and a a shared scl line.
For some reason the check for the number of allowed busses
is one off and the driver can only allocate three busses.
Fix that.

Fixes: acd7ecc9ed8 ("realtek: add new i2c-gpio-shared driver")
Signed-off-by: Markus Stockhausen <markus.stockhausen@gmx.de>
Link: https://github.com/openwrt/openwrt/pull/22543
Signed-off-by: Robert Marko <robimarko@gmail.com>
target/linux/realtek/files-6.12/drivers/i2c/busses/i2c-gpio-shared.c