The redundant regulator_enable operation will cause the count
to increase and the following calltrace will appear

WARNING: CPU: 3 PID: 7 at drivers/regulator/core.c:2145 
_regulator_put.part.0+0x15c/0x164
Modules linked in:
CPU: 3 PID: 7 Comm: kworker/u12:0 Not tainted 5.10.25-yocto-standard #1
Hardware name: Freescale i.MX8QM MEK (DT)
Workqueue: events_unbound async_run_entry_fn
pstate: 80000005 (Nzcv daif PAN -UAO -TCO BTYPE=-)
pc: _regulator_put.part.0+0x15c/0x164
lr: regulator_put+0x44/0x60
sp: ffff800011b33bd0
x29: ffff800011b33bd0 x28: 0000000000000000
x27: ffff0008101cb3c8 x26: ffff8000119dbb88
x25: ffff800011914c20 x24: ffff000810a23500
x23: 0000000000000008 x22: ffff800011b33c88
x21: ffff0008101f5100 x20: ffff8000118f8050
x19: ffff000810a23700 x18: 0000000000000020
x17: 0000000000000020 x16: 0000000000000000
x15: ffff0008101f5578 x14: ffffffffffffffff
x13: ffff000811df8a1c x12: 0000000000000030
x11: 0000000000000003 x10: 0101010101010101
x9: ffff800010764c44 x8: ffff800010881fb0
x7: ffff000810ba2ec0 x6: ffff000810a23500
x5: ffff000810ba2ec0 x4: 0000000000000000
x3: 0000000000000000 x2: ffff0008101f5100
x1: 0000000000000000 x0: 0000000000000001
Call trace:
_regulator_put.part.0+0x15c/0x164
regulator_put+0x44/0x60
devm_regulator_release+0x20/0x2c
release_nodes+0x1b8/0x230
devres_release_all+0x44/0x70
really_probe+0x1f4/0x4b4
driver_probe_device+0x64/0xcc
__driver_attach_async_helper+0xcc/0xd0
async_run_entry_fn+0x54/0x120
process_one_work+0x1f0/0x4a0
worker_thread+0x160/0x46c
kthread+0x150/0x160
ret_from_fork+0x10/0x3c

Signed-off-by: Xiaolei Wang <[email protected]>
---
 drivers/pci/controller/dwc/pci-imx6.c | 4 ----
 1 file changed, 4 deletions(-)

diff --git a/drivers/pci/controller/dwc/pci-imx6.c 
b/drivers/pci/controller/dwc/pci-imx6.c
index 1afae9d4b7c0..fad90e0c5e49 100644
--- a/drivers/pci/controller/dwc/pci-imx6.c
+++ b/drivers/pci/controller/dwc/pci-imx6.c
@@ -2454,10 +2454,6 @@ static int imx6_pcie_probe(struct platform_device *pdev)
        if (IS_ERR(imx6_pcie->epdev_on))
                return -EPROBE_DEFER;
 
-       ret = regulator_enable(imx6_pcie->epdev_on);
-       if (ret)
-               dev_err(dev, "failed to enable the epdev_on regulator\n");
-
        imx6_pcie->reset_gpio = of_get_named_gpio(node, "reset-gpio", 0);
        imx6_pcie->gpio_active_high = of_property_read_bool(node,
                                                "reset-gpio-active-high");
-- 
2.25.1

-=-=-=-=-=-=-=-=-=-=-=-
Links: You receive all messages sent to this group.
View/Reply Online (#9664): 
https://lists.yoctoproject.org/g/linux-yocto/message/9664
Mute This Topic: https://lists.yoctoproject.org/mt/81822571/21656
Group Owner: [email protected]
Unsubscribe: https://lists.yoctoproject.org/g/linux-yocto/unsub 
[[email protected]]
-=-=-=-=-=-=-=-=-=-=-=-

Reply via email to