Commit c930b10
PCI: dw-rockchip: Simplify regulator setup with devm_regulator_get_enable_optional()
Replace manual get/enable logic with devm_regulator_get_enable_optional()
to reduce boilerplate and improve error handling. This devm helper ensures
the regulator is enabled during probe and automatically disabled when the
platform device is freed.
Also drop the redundant 'rockchip_pcie::vpcie3v3' pointer.
Signed-off-by: Anand Moon <linux.amoon@gmail.com>
Signed-off-by: Manivannan Sadhasivam <mani@kernel.org>
Link: https://patch.msgid.link/20250905112736.6401-1-linux.amoon@gmail.com1 parent 3a86608 commit c930b10
1 file changed
Lines changed: 6 additions & 17 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
82 | 82 | | |
83 | 83 | | |
84 | 84 | | |
85 | | - | |
86 | 85 | | |
87 | 86 | | |
88 | 87 | | |
| |||
652 | 651 | | |
653 | 652 | | |
654 | 653 | | |
655 | | - | |
656 | | - | |
657 | | - | |
658 | | - | |
659 | | - | |
660 | | - | |
661 | | - | |
662 | | - | |
663 | | - | |
664 | | - | |
665 | | - | |
666 | | - | |
| 654 | + | |
| 655 | + | |
| 656 | + | |
| 657 | + | |
667 | 658 | | |
668 | 659 | | |
669 | 660 | | |
670 | | - | |
| 661 | + | |
| 662 | + | |
671 | 663 | | |
672 | 664 | | |
673 | 665 | | |
| |||
700 | 692 | | |
701 | 693 | | |
702 | 694 | | |
703 | | - | |
704 | | - | |
705 | | - | |
706 | 695 | | |
707 | 696 | | |
708 | 697 | | |
| |||
0 commit comments