Skip to content
Commit f1476242 authored by Mark Brown's avatar Mark Brown Committed by Linus Walleij
Browse files

pinctrl: sunxi: Add some defensiveness for regulators array



The sunxi pinctrl has a fixed size array it uses to store regulators used
in the driver. There is currently nothing that ensures that the number of
elements in the array is large enough to map the regulators defined by the
individual SoCs. While this is currently the case having an explicit check
in there will make life easier for anyone debugging memory issues that
manifest in the driver so let's add one.

Signed-off-by: default avatarMark Brown <broonie@kernel.org>
Reviewed-by: default avatarChen-Yu Tsai <wens@csie.org>
Reviewed-by: default avatarJernej Skrabec <jernej.skrabec@gmail.com>
Link: https://lore.kernel.org/r/20230712-pinctrl-sunxi-boudns-v1-1-85f37de79b9f@kernel.org


Signed-off-by: default avatarLinus Walleij <linus.walleij@linaro.org>
parent 99084881
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment