linux/drivers/net/pse-pd
Kory Maincent f2767a4195 net: pse-pd: Fix out of bound for loop
Adjust the loop limit to prevent out-of-bounds access when iterating over
PI structures. The loop should not reach the index pcdev->nr_lines since
we allocate exactly pcdev->nr_lines number of PI structures. This fix
ensures proper bounds are maintained during iterations.

Fixes: 9be9567a7c ("net: pse-pd: Add support for PSE PIs")
Signed-off-by: Kory Maincent <kory.maincent@bootlin.com>
Reviewed-by: Simon Horman <horms@kernel.org>
Acked-by: Oleksij Rempel <o.rempel@pengutronix.de>
Message-ID: <20241015130255.125508-1-kory.maincent@bootlin.com>
Signed-off-by: Andrew Lunn <andrew@lunn.ch>
2024-10-19 15:55:56 -05:00
..
Kconfig net: pse-pd: Kconfig: Fix missing firmware loader config select 2024-06-21 11:29:52 +01:00
Makefile net: pse-pd: Add TI TPS23881 PSE controller driver 2024-04-18 18:27:39 -07:00
pd692x0.c net: pse-pd: pd692x0: Fix spelling mistake "availables" -> "available" 2024-07-11 10:00:35 -07:00
pse_core.c net: pse-pd: Fix out of bound for loop 2024-10-19 15:55:56 -05:00
pse_regulator.c net: pse-pd: Use regulator framework within PSE framework 2024-04-18 18:27:39 -07:00
tps23881.c net: pse-pd: tps23881: Support reset-gpios 2024-08-26 13:24:11 -07:00