linux-stable/drivers/regulator
Johan Hovold 324be157e0 regulator: core: fix debugfs creation regression
commit 2a4b49bb58 upstream.

regulator_get() may sometimes be called more than once for the same
consumer device, something which before commit dbe954d8f1 ("regulator:
core: Avoid debugfs: Directory ...  already present! error") resulted in
errors being logged.

A couple of recent commits broke the handling of such cases so that
attributes are now erroneously created in the debugfs root directory the
second time a regulator is requested and the log is filled with errors
like:

	debugfs: File 'uA_load' in directory '/' already present!
	debugfs: File 'min_uV' in directory '/' already present!
	debugfs: File 'max_uV' in directory '/' already present!
	debugfs: File 'constraint_flags' in directory '/' already present!

on any further calls.

Fixes: 2715bb11cf ("regulator: core: Fix more error checking for debugfs_create_dir()")
Fixes: 08880713ce ("regulator: core: Streamline debugfs operations")
Cc: stable@vger.kernel.org
Cc: Geert Uytterhoeven <geert+renesas@glider.be>
Signed-off-by: Johan Hovold <johan+linaro@kernel.org>
Link: https://lore.kernel.org/r/20240509133304.8883-1-johan+linaro@kernel.org
Signed-off-by: Mark Brown <broonie@kernel.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2024-05-17 11:48:11 +02:00
..
88pg86x.c regulator: 88pg86x: Fix W=1 build warning when CONFIG_OF=n 2020-08-21 17:28:09 +01:00
88pm800-regulator.c regulator: use linear_ranges helper 2020-05-08 18:18:13 +01:00
88pm8607.c treewide: Replace GPLv2 boilerplate/reference with SPDX - rule 500 2019-06-19 17:09:55 +02:00
Kconfig regulator: rtmv20: Adds support for Richtek RTMV20 load switch regulator 2020-09-28 19:26:32 +01:00
Makefile regulator: rtmv20: Adds support for Richtek RTMV20 load switch regulator 2020-09-28 19:26:32 +01:00
aat2870-regulator.c treewide: Replace GPLv2 boilerplate/reference with SPDX - rule 336 2019-06-05 17:37:07 +02:00
ab3100.c treewide: Replace GPLv2 boilerplate/reference with SPDX - rule 194 2019-05-30 11:29:22 -07:00
ab8500-ext.c treewide: Replace GPLv2 boilerplate/reference with SPDX - rule 197 2019-05-30 11:29:22 -07:00
ab8500.c regulator: ab8500: Remove unused embedded struct expand_register 2020-06-25 20:11:13 +01:00
act8865-regulator.c regulator: use linear_ranges helper 2020-05-08 18:18:13 +01:00
act8945a-regulator.c regulator: use linear_ranges helper 2020-05-08 18:18:13 +01:00
ad5398.c treewide: Replace GPLv2 boilerplate/reference with SPDX - rule 149 2019-05-30 11:25:18 -07:00
anatop-regulator.c regulator: anatop: Constify anatop_core_rops 2020-06-18 13:47:31 +01:00
arizona-ldo1.c regulator: use linear_ranges helper 2020-05-08 18:18:13 +01:00
arizona-micsupp.c regulator: use linear_ranges helper 2020-05-08 18:18:13 +01:00
as3711-regulator.c regulator: use linear_ranges helper 2020-05-08 18:18:13 +01:00
as3722-regulator.c regulator: use linear_ranges helper 2020-05-08 18:18:13 +01:00
axp20x-regulator.c regulator: axp20x: Fix reference cout leak 2021-03-04 11:37:58 +01:00
bcm590xx-regulator.c regulator: use linear_ranges helper 2020-05-08 18:18:13 +01:00
bd718x7-regulator.c regulator: bd718x7: Fix the BUCK7 voltage setting on BD71837 2021-06-16 12:01:43 +02:00
bd9571mwv-regulator.c regulator: bd9571mwv: Fix AVS and DVFS voltage range 2021-04-14 08:42:05 +02:00
bd9576-regulator.c regulator: bd9576: Fix return from bd957x_probe() 2021-05-14 09:50:10 +02:00
bd70528-regulator.c regulator: use linear_ranges helper 2020-05-08 18:18:13 +01:00
bd71828-regulator.c regulator: use linear_ranges helper 2020-05-08 18:18:13 +01:00
core.c regulator: core: fix debugfs creation regression 2024-05-17 11:48:11 +02:00
cpcap-regulator.c regulator: cpcap-regulator: Demote kerneldoc header to standard comment 2020-06-25 20:11:16 +01:00
cros-ec-regulator.c regulator: cros-ec: Fix error code in dev_err message 2021-06-23 14:42:47 +02:00
da903x-regulator.c regulator: rename da903x to da903x-regulator 2020-06-25 15:29:21 +01:00
da9052-regulator.c regulator: da9052: Ensure enough delay time for .set_voltage_time_sel 2021-07-14 16:55:56 +02:00
da9055-regulator.c regulator: remove locking around regulator_notifier_call_chain() 2020-09-07 18:35:25 +01:00
da9062-regulator.c regulator: remove locking around regulator_notifier_call_chain() 2020-09-07 18:35:25 +01:00
da9063-regulator.c regulator: remove locking around regulator_notifier_call_chain() 2020-09-07 18:35:25 +01:00
da9210-regulator.c regulator: remove locking around regulator_notifier_call_chain() 2020-09-07 18:35:25 +01:00
da9210-regulator.h regulator: da9xxx: Switch to SPDX identifier 2019-05-03 15:07:39 +09:00
da9211-regulator.c regulator: da9211: Use irq handler when ready 2023-01-18 11:44:58 +01:00
da9211-regulator.h regulator: da9xxx: Switch to SPDX identifier 2019-05-03 15:07:39 +09:00
db8500-prcmu.c regulator: db8500-prcmu: Use true,false for bool variable 2020-05-06 15:16:59 +01:00
dbx500-prcmu.c regulator: dbx500: Remove unused debugfs goto label 2020-08-21 17:38:49 +01:00
dbx500-prcmu.h treewide: Replace GPLv2 boilerplate/reference with SPDX - rule 197 2019-05-30 11:29:22 -07:00
devres.c regulator: devres: Standardise on function documentation headers 2020-07-08 17:37:54 +01:00
dummy.c regulator: dummy: Constify dummy_initdata and dummy_ops 2020-09-14 14:24:36 +01:00
dummy.h treewide: Replace GPLv2 boilerplate/reference with SPDX - rule 152 2019-05-30 11:26:32 -07:00
fan53555.c regulator: fan53555: Explicitly include bits header 2023-04-26 11:27:34 +02:00
fan53880.c regulator: fan53880: Fix vsel_mask setting for FAN53880_BUCK 2021-07-14 16:56:06 +02:00
fixed-helper.c
fixed.c regulator: Handle deferred clk 2023-04-05 11:23:47 +02:00
gpio-regulator.c regulator: gpio: Honor regulator-boot-on property 2020-07-20 16:31:54 +01:00
helpers.c regulator: Add regmap helper for ramp-delay setting 2023-06-05 09:07:03 +02:00
hi655x-regulator.c regulator: hi655x: Fix pass wrong pointer to config.driver_data 2021-07-14 16:56:09 +02:00
hi6421-regulator.c regulator: hi6421: Fix getting wrong drvdata 2021-07-28 14:35:36 +02:00
hi6421v530-regulator.c regulator: Replace HTTP links with HTTPS ones 2020-07-22 14:43:48 +01:00
internal.h regulator: core: Don't try to remove device links if add failed 2019-11-15 12:04:20 +00:00
isl6271a-regulator.c
isl9305.c regulator: Convert i2c drivers to use .probe_new 2020-01-13 15:03:06 +00:00
lm363x-regulator.c regulator: lm363x: Fix n_voltages setting for lm36274 2019-07-22 13:18:13 +01:00
lochnagar-regulator.c regulator: lochnagar: Add additional VDDCORE range 2020-09-07 18:49:13 +01:00
lp872x.c treewide: Replace GPLv2 boilerplate/reference with SPDX - rule 500 2019-06-19 17:09:55 +02:00
lp873x-regulator.c regulator: Replace HTTP links with HTTPS ones 2020-07-22 14:43:48 +01:00
lp3971.c regulator: Convert i2c drivers to use .probe_new 2020-01-13 15:03:06 +00:00
lp3972.c treewide: Replace GPLv2 boilerplate/reference with SPDX - rule 500 2019-06-19 17:09:55 +02:00
lp8755.c regulator: remove locking around regulator_notifier_call_chain() 2020-09-07 18:35:25 +01:00
lp8788-buck.c regulator: use linear_ranges helper 2020-05-08 18:18:13 +01:00
lp8788-ldo.c regulator: lp8788-ldo: make array en_mask static const, makes object smaller 2019-09-09 10:53:48 +01:00
lp87565-regulator.c regulator: Replace HTTP links with HTTPS ones 2020-07-22 14:43:48 +01:00
ltc3589.c regulator: remove locking around regulator_notifier_call_chain() 2020-09-07 18:35:25 +01:00
ltc3676.c regulator: remove locking around regulator_notifier_call_chain() 2020-09-07 18:35:25 +01:00
max1586.c regulator: max1586: Fix W=1 build warning when CONFIG_OF=n 2020-08-21 17:28:14 +01:00
max8649.c treewide: Replace GPLv2 boilerplate/reference with SPDX - rule 500 2019-06-19 17:09:55 +02:00
max8660.c regulator: max8660: remove redundant assignment of variable ret 2019-08-15 15:09:21 +01:00
max8907-regulator.c regulator: max8907: Constify static structs 2020-06-18 13:47:34 +01:00
max8925-regulator.c treewide: Replace GPLv2 boilerplate/reference with SPDX - rule 500 2019-06-19 17:09:55 +02:00
max8952.c Linux 5.2-rc4 2019-06-18 19:12:47 +01:00
max8973-regulator.c
max8997-regulator.c regulator: max8997: Constify struct regulator_ops 2020-06-18 13:47:35 +01:00
max8998.c regulator: max8998: Staticify internal function max8998_get_current_limit() 2020-06-26 15:34:18 +01:00
max14577-regulator.c regulator: max14577-regulator: Demote kerneldoc header to standard comment 2020-06-25 20:11:17 +01:00
max77620-regulator.c regulator: max77620: Use device_set_of_node_from_dev() 2021-06-16 12:01:43 +02:00
max77650-regulator.c regulator: use linear_ranges helper 2020-05-08 18:18:13 +01:00
max77686-regulator.c regulator: max77686: switch to using fwnode_gpiod_get_index 2019-10-07 14:02:20 +01:00
max77693-regulator.c
max77802-regulator.c regulator: max77802: Bounds check regulator id against opmode 2023-03-11 16:39:53 +01:00
max77826-regulator.c regulator: max77826: Fix W=1 build warning when CONFIG_OF=n 2020-08-21 17:28:15 +01:00
mc13xxx-regulator-core.c
mc13xxx.h treewide: Replace GPLv2 boilerplate/reference with SPDX - rule 152 2019-05-30 11:26:32 -07:00
mc13783-regulator.c
mc13892-regulator.c
mcp16502.c regulator: use linear_ranges helper 2020-05-08 18:18:13 +01:00
mp886x.c regulator: mp886x: use "mps,switch-frequency-hz" 2020-08-24 14:17:53 +01:00
mp5416.c regulator: mp5416: Fix output discharge enable bit for LDOs 2020-02-17 19:13:26 +00:00
mp8859.c regulator: use linear_ranges helper 2020-05-08 18:18:13 +01:00
mpq7920.c regulator: mpq7920: Convert to use .probe_new 2020-01-14 15:25:00 +00:00
mpq7920.h regulator: mpq7920: Fix incorrect defines 2020-01-17 15:34:31 +00:00
mt6311-regulator.c regulator: Convert i2c drivers to use .probe_new 2020-01-13 15:03:06 +00:00
mt6311-regulator.h regulator: mt63xx: Switch to SPDX identifier 2019-04-26 10:38:23 +01:00
mt6323-regulator.c regulator: use linear_ranges helper 2020-05-08 18:18:13 +01:00
mt6358-regulator.c regulator: mt6358: Fix vdram2 .vsel_mask 2021-07-14 16:55:56 +02:00
mt6360-regulator.c regulator: mt6360: De-capitalize devicetree regulator subnodes 2024-05-17 11:47:59 +02:00
mt6380-regulator.c regulator: use linear_ranges helper 2020-05-08 18:18:13 +01:00
mt6397-regulator.c regulator: mt6397: Implement of_map_mode 2020-07-02 15:25:45 +01:00
of_regulator.c regulator: of: Fix refcount leak bug in of_get_regulation_constraints() 2022-08-21 15:15:36 +02:00
palmas-regulator.c regulator: use linear_ranges helper 2020-05-08 18:18:13 +01:00
pbias-regulator.c regulator: Replace HTTP links with HTTPS ones 2020-07-22 14:43:48 +01:00
pca9450-regulator.c regulator: pca9450: Fix BUCK2 enable_mask 2023-06-05 09:07:03 +02:00
pcap-regulator.c regulator: pcap-regulator: remove unused variable 'SW3_table' 2019-10-01 12:46:37 +01:00
pcf50633-regulator.c treewide: Replace GPLv2 boilerplate/reference with SPDX - rule 152 2019-05-30 11:26:32 -07:00
pfuze100-regulator.c regulator: pfuze100: Fix the global-out-of-bounds access in pfuze100_regulator_probe() 2022-09-23 14:16:59 +02:00
pv88060-regulator.c regulator: remove locking around regulator_notifier_call_chain() 2020-09-07 18:35:25 +01:00
pv88060-regulator.h regulator: pv880x0: Switch to SPDX identifier 2019-05-03 15:05:52 +09:00
pv88080-regulator.c regulator: remove locking around regulator_notifier_call_chain() 2020-09-07 18:35:25 +01:00
pv88080-regulator.h regulator: pv880x0: Switch to SPDX identifier 2019-05-03 15:05:52 +09:00
pv88090-regulator.c regulator: remove locking around regulator_notifier_call_chain() 2020-09-07 18:35:25 +01:00
pv88090-regulator.h regulator: pv880x0: Switch to SPDX identifier 2019-05-03 15:05:52 +09:00
pwm-regulator.c regulator: pwm-regulator: Add validity checks in continuous .get_voltage 2024-03-01 13:16:44 +01:00
qcom-labibb-regulator.c regulator: qcom: labibb: Constify static structs 2020-10-01 21:43:16 +01:00
qcom-rpmh-regulator.c regulator: qcom-rpmh: Correct the pmic5_hfsmps515 buck 2021-03-30 14:31:51 +02:00
qcom_rpm-regulator.c regulator: qcom_rpm: Fix circular deferral regression 2022-10-26 13:25:09 +02:00
qcom_smd-regulator.c regulator: qcom_smd: Fix pm8916_pldo range 2022-08-21 15:15:34 +02:00
qcom_spmi-regulator.c regulator: qcom_spmi: Add PM660/PM660L regulators 2020-10-01 21:25:23 +01:00
qcom_usb_vbus-regulator.c regulator: set of_node for qcom vbus regulator 2020-08-18 18:38:25 +01:00
rc5t583-regulator.c treewide: Replace GPLv2 boilerplate/reference with SPDX - rule 201 2019-05-30 11:29:52 -07:00
rk808-regulator.c regulator: use linear_ranges helper 2020-05-08 18:18:13 +01:00
rn5t618-regulator.c regulator: Fixes for v5.5 2019-12-17 13:08:41 -08:00
rohm-regulator.c regulator: bd718x7, bd71828, Fix dvs voltage levels 2021-03-04 11:38:07 +01:00
rpi-panel-attiny-regulator.c regulator: rpi-panel: Handle I2C errors/timing to the Atmel 2022-04-08 14:40:30 +02:00
rt4801-regulator.c regulator: rt4801: Fix NULL pointer dereference if priv->enable_gpios is NULL 2021-06-23 14:42:48 +02:00
rt5033-regulator.c treewide: Replace GPLv2 boilerplate/reference with SPDX - rule 450 2019-06-05 17:37:18 +02:00
rtmv20-regulator.c regulator: rtmv20: Fix wrong mask for strobe-polarity-high 2021-08-08 09:05:22 +02:00
s2mpa01.c regulator: samsung: Rename Samsung to lowercase 2020-01-06 20:47:42 +00:00
s2mps11.c regulator: use linear_ranges helper 2020-05-08 18:18:13 +01:00
s5m8767.c regulator: s5m8767: Bounds check id indexing into arrays 2023-03-11 16:39:53 +01:00
sc2731-regulator.c regulator: sc2731: Constify regulators 2019-03-26 13:25:35 +00:00
sky81452-regulator.c regulator: use linear_ranges helper 2020-05-08 18:18:13 +01:00
slg51000-regulator.c regulator: slg51000: Wait after asserting CS pin 2022-12-14 11:31:53 +01:00
slg51000-regulator.h regulator: slg51000: add slg51000 regulator driver 2019-05-13 11:07:43 +01:00
stm32-booster.c regulator: stm32-booster: Fix W=1 build warning when CONFIG_OF=n 2020-08-21 17:28:20 +01:00
stm32-pwr.c regulator: stm32-pwr: fix of_iomap leak 2023-05-17 11:47:45 +02:00
stm32-vrefbuf.c regulator: stm32-vrefbuf: Fix W=1 build warning when CONFIG_OF=n 2020-08-21 17:28:18 +01:00
stpmic1_regulator.c regulator: remove locking around regulator_notifier_call_chain() 2020-09-07 18:35:25 +01:00
stw481x-vmmc.c regulator: stw481x-vmmc: Constify static structs 2020-09-14 14:24:38 +01:00
sy8106a-regulator.c regulator: sy8106a: Fix W=1 build warning when CONFIG_OF=n 2020-08-21 17:28:19 +01:00
sy8824x.c regulator: Convert i2c drivers to use .probe_new 2020-01-13 15:03:06 +00:00
sy8827n.c regulator: sy8827n: Fix W=1 build warning when CONFIG_OF=n 2020-08-18 17:18:40 +01:00
ti-abb-regulator.c regulator: ti-abb: Fix array out of bound read access on the first transition 2020-11-18 17:59:24 +00:00
tps6105x-regulator.c regulator: tps6105x: Constify tps6105x_regulator_ops 2020-09-01 15:48:52 +01:00
tps6507x-regulator.c regulator: Replace HTTP links with HTTPS ones 2020-07-22 14:43:48 +01:00
tps6524x-regulator.c regulator: tps6524x: Remove *rdev[N_REGULATORS] from struct tps6524x 2019-04-15 09:44:41 +01:00
tps6586x-regulator.c regulator: tps6586x: Constify static regulator_ops 2020-09-01 15:48:56 +01:00
tps51632-regulator.c regulator: tps51632: Constify tps51632_dcdc_ops 2020-09-01 15:48:51 +01:00
tps62360-regulator.c regulator: tps62360: Constify tps62360_dcdc_ops 2020-09-01 15:48:53 +01:00
tps65023-regulator.c regulator: tps65023: Fix W=1 build warning when CONFIG_OF=n 2020-08-21 17:28:21 +01:00
tps65086-regulator.c regulator: tps65086: Constify static regulator_ops 2020-09-01 15:48:54 +01:00
tps65090-regulator.c regulator: tps65090: constify static regulator_ops 2020-09-01 15:48:55 +01:00
tps65132-regulator.c regulator: Convert i2c drivers to use .probe_new 2020-01-13 15:03:06 +00:00
tps65217-regulator.c regulator: Replace HTTP links with HTTPS ones 2020-07-22 14:43:48 +01:00
tps65218-regulator.c regulator: Replace HTTP links with HTTPS ones 2020-07-22 14:43:48 +01:00
tps65910-regulator.c regulator: tps65910: Silence deferred probe error 2021-09-15 09:50:23 +02:00
tps65912-regulator.c regulator: tps65912: Constify static regulator_ops 2020-09-01 15:48:56 +01:00
tps80031-regulator.c regulator: tps80031: remove redundant assignment to variables ret and val 2020-04-14 16:57:44 +01:00
twl-regulator.c regulator: use linear_ranges helper 2020-05-08 18:18:13 +01:00
twl6030-regulator.c regulator: twl6030: fix get status of twl6032 regulators 2022-12-14 11:31:54 +01:00
uniphier-regulator.c regulator: uniphier: Add missing MODULE_DEVICE_TABLE 2021-07-14 16:55:50 +02:00
userspace-consumer.c treewide: Replace GPLv2 boilerplate/reference with SPDX - rule 152 2019-05-30 11:26:32 -07:00
vctrl-regulator.c regulator: vctrl: Avoid lockdep warning in enable/disable ops 2021-09-15 09:50:30 +02:00
vexpress-regulator.c regulator: vexpress: Use PTR_ERR_OR_ZERO() to simplify code 2019-11-18 12:58:24 +00:00
virtual.c treewide: Replace GPLv2 boilerplate/reference with SPDX - rule 152 2019-05-30 11:26:32 -07:00
vqmmc-ipq4019-regulator.c regulator: vqmmc-ipq4019: Fix platform_no_drv_owner.cocci warnings 2020-01-17 15:34:21 +00:00
wm831x-dcdc.c regulator: remove locking around regulator_notifier_call_chain() 2020-09-07 18:35:25 +01:00
wm831x-isink.c regulator: remove locking around regulator_notifier_call_chain() 2020-09-07 18:35:25 +01:00
wm831x-ldo.c regulator: remove locking around regulator_notifier_call_chain() 2020-09-07 18:35:25 +01:00
wm8350-regulator.c regulator: remove locking around regulator_notifier_call_chain() 2020-09-07 18:35:25 +01:00
wm8400-regulator.c regulator: wm8400-regulator: Repair dodgy kerneldoc header formatting 2020-06-26 15:34:24 +01:00
wm8994-regulator.c regulator: wm8994: Add an off-on delay for WM8994 variant 2022-04-20 09:23:22 +02:00