Skip to content

Commit 154fc1f

Browse files
robherringkwilczynski
authored andcommitted
PCI: dwc: Use of_property_present() for non-boolean properties
The use of of_property_read_bool() for non-boolean properties is deprecated in favor of of_property_present() when testing for property presence. Link: https://lore.kernel.org/r/20241104190714.275977-1-robh@kernel.org Signed-off-by: Rob Herring (Arm) <robh@kernel.org> Signed-off-by: Krzysztof Wilczyński <kwilczynski@kernel.org> Signed-off-by: Bjorn Helgaas <bhelgaas@google.com> Acked-by: Manivannan Sadhasivam <manivannan.sadhasivam@linaro.org>
1 parent 12dd128 commit 154fc1f

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

drivers/pci/controller/dwc/pcie-designware-host.c

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -474,8 +474,8 @@ int dw_pcie_host_init(struct dw_pcie_rp *pp)
474474

475475
if (pci_msi_enabled()) {
476476
pp->has_msi_ctrl = !(pp->ops->msi_init ||
477-
of_property_read_bool(np, "msi-parent") ||
478-
of_property_read_bool(np, "msi-map"));
477+
of_property_present(np, "msi-parent") ||
478+
of_property_present(np, "msi-map"));
479479

480480
/*
481481
* For the has_msi_ctrl case the default assignment is handled

0 commit comments

Comments
 (0)