regulator: rtq2208: Fix invalid memory access when devm_of_regulator_put_matches...
authorAlina Yu <alina_yu@richtek.com>
Tue, 28 May 2024 06:01:13 +0000 (14:01 +0800)
committerMark Brown <broonie@kernel.org>
Tue, 28 May 2024 12:22:54 +0000 (13:22 +0100)
commit72b6a2d6506843375c7b91197f49ef38ca0c6d0f
tree3bb53c21f36389eda84870f1c17f82edb157ccf7
parent1613e604df0cd359cf2a7fbd9be7a0bcfacfabd0
regulator: rtq2208: Fix invalid memory access when devm_of_regulator_put_matches is called

In this patch, a software bug has been fixed.
rtq2208_ldo_match is no longer a local variable.
It prevents invalid memory access when devm_of_regulator_put_matches
 is called.

Signed-off-by: Alina Yu <alina_yu@richtek.com>
Link: https://msgid.link/r/4ce8c4f16f1cf3aa4e5f36c0694dd3c5ccf3cd1c.1716870419.git.alina_yu@richtek.com
Signed-off-by: Mark Brown <broonie@kernel.org>
drivers/regulator/rtq2208-regulator.c