Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

regulator: rtq2208: Fix uninitialized use of regulator_config

Fix rtq2208 driver uninitialized use to cause kernel error.

Fixes: 85a11f55621a ("regulator: rtq2208: Add Richtek RTQ2208 SubPMIC")
Signed-off-by: ChiYuan Huang <cy_huang@richtek.com>
Link: https://patch.msgid.link/00d691cfcc0eae9ce80a37b62e99851e8fdcffe2.1729829243.git.cy_huang@richtek.com
Signed-off-by: Mark Brown <broonie@kernel.org>

authored by

ChiYuan Huang and committed by
Mark Brown
2feb0231 8e929cb5

+1 -1
+1 -1
drivers/regulator/rtq2208-regulator.c
··· 568 568 struct regmap *regmap; 569 569 struct rtq2208_regulator_desc *rdesc[RTQ2208_LDO_MAX]; 570 570 struct regulator_dev *rdev; 571 - struct regulator_config cfg; 571 + struct regulator_config cfg = {}; 572 572 struct rtq2208_rdev_map *rdev_map; 573 573 int i, ret = 0, idx, n_regulator = 0; 574 574 unsigned int regulator_idx_table[RTQ2208_LDO_MAX],