mbox series

[0/5] Simplify code with _scoped() helper functions

Message ID 20240828073825.43072-1-zhangzekun11@huawei.com (mailing list archive)
Headers show
Series Simplify code with _scoped() helper functions | expand

Message

zhangzekun (A) Aug. 28, 2024, 7:38 a.m. UTC
Use _scoped() functions to iterate through the child node, and we don't
need to call of_node_put() manually. This can simplify the code a bit.

Zhang Zekun (5):
  PCI: kirin: Use helper function
    for_each_available_child_of_node_scoped()
  PCI: mediatek: Use helper function
    for_each_available_child_of_node_scoped()
  PCI: mt7621: Use helper function
    for_each_available_child_of_node_scoped()
  PCI: apple: Use helper function for_each_child_of_node_scoped()
  PCI: tegra: Use helper function for_each_child_of_node_scoped()

 drivers/pci/controller/dwc/pcie-kirin.c | 10 ++----
 drivers/pci/controller/pci-tegra.c      | 41 +++++++++----------------
 drivers/pci/controller/pcie-apple.c     |  4 +--
 drivers/pci/controller/pcie-mediatek.c  | 11 +++----
 drivers/pci/controller/pcie-mt7621.c    |  9 ++----
 5 files changed, 25 insertions(+), 50 deletions(-)