aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorNikita Shubin <nikita.shubin@maquefel.me>2024-02-05 11:23:34 +0100
committerArnd Bergmann <arnd@arndb.de>2024-02-20 17:19:49 +0100
commitfdf87a0dc26d0550c60edc911cda42f9afec3557 (patch)
treebfed6aff4bd97d617e3846c0ad2c2fc7499ba8cf
parent841c35169323cd833294798e58b9bf63fa4fa1de (diff)
downloadlinux-fdf87a0dc26d0550c60edc911cda42f9afec3557.tar.gz
ARM: ep93xx: Add terminator to gpiod_lookup_table
Without the terminator, if a con_id is passed to gpio_find() that does not exist in the lookup table the function will not stop looping correctly, and eventually cause an oops. Cc: stable@vger.kernel.org Fixes: b2e63555592f ("i2c: gpio: Convert to use descriptors") Reported-by: Andy Shevchenko <andriy.shevchenko@intel.com> Signed-off-by: Nikita Shubin <nikita.shubin@maquefel.me> Reviewed-by: Linus Walleij <linus.walleij@linaro.org> Acked-by: Alexander Sverdlin <alexander.sverdlin@gmail.com> Signed-off-by: Alexander Sverdlin <alexander.sverdlin@gmail.com> Link: https://lore.kernel.org/r/20240205102337.439002-1-alexander.sverdlin@gmail.com Signed-off-by: Arnd Bergmann <arnd@arndb.de>
Notes
Fixes: b2e63555592f ("i2c: gpio: Convert to use descriptors") # v4.15-rc1 Stable: 97ba7c1f9c0a # v6.6.19 Stable: 786f089086b5 # v6.1.80 Stable: eec6cbbfa1e8 # v5.15.150 Stable: 70d92abbe296 # v5.10.211 Stable: 999a8bb70da2 # v5.4.270 Stable: 9e200a06ae2a # v4.19.308 Lore: https://lore.kernel.org/r/20231212-ep93xx-v6-1-c307b8ac9aa8@maquefel.me # b4-sent, linux-arm-kernel, lkml Lore: https://lore.kernel.org/r/20240118-ep93xx-v7-1-d953846ae771@maquefel.me # b4-sent, linux-arm-kernel, lkml Lore: https://lore.kernel.org/r/20240205102337.439002-1-alexander.sverdlin@gmail.com # soc, stable Lore: https://lore.kernel.org/r/20240227131549.588085742@linuxfoundation.org # linux-patches, stable Lore: https://lore.kernel.org/r/20240227131554.759821590@linuxfoundation.org # linux-patches, stable Lore: https://lore.kernel.org/r/20240227131601.391052191@linuxfoundation.org # linux-patches, stable Lore: https://lore.kernel.org/r/20240227131614.129179043@linuxfoundation.org # linux-patches, stable Lore: https://lore.kernel.org/r/20240227131618.053495467@linuxfoundation.org # linux-patches, stable Lore: https://lore.kernel.org/r/20240227131631.538178990@linuxfoundation.org # linux-patches, stable Lore: https://lore.kernel.org/r/20240227131637.106690641@linuxfoundation.org # linux-patches, stable
-rw-r--r--arch/arm/mach-ep93xx/core.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/arch/arm/mach-ep93xx/core.c b/arch/arm/mach-ep93xx/core.c
index 71b1139764204..8b1ec60a9a467 100644
--- a/arch/arm/mach-ep93xx/core.c
+++ b/arch/arm/mach-ep93xx/core.c
@@ -339,6 +339,7 @@ static struct gpiod_lookup_table ep93xx_i2c_gpiod_table = {
GPIO_ACTIVE_HIGH | GPIO_OPEN_DRAIN),
GPIO_LOOKUP_IDX("G", 0, NULL, 1,
GPIO_ACTIVE_HIGH | GPIO_OPEN_DRAIN),
+ { }
},
};