summaryrefslogtreecommitdiff
path: root/drivers/of/address.c
diff options
context:
space:
mode:
authorRob Herring <robh@kernel.org>2018-08-29 08:36:12 -0500
committerRob Herring <robh@kernel.org>2018-11-27 11:27:04 -0600
commite8b1dee21420f871e300d46342f2c98a2e08158d (patch)
treedb4ce7732a8044e52a17f681bb15e537fa69a3ea /drivers/of/address.c
parente31d0fc6fd1bf62e56e7e3d0b69e7e64d8b7db58 (diff)
of: Use device_type helpers to access the node type
Remove directly accessing device_node.type pointer and use the accessors instead. This will eventually allow removing the type pointer. Cc: Frank Rowand <frowand.list@gmail.com> Cc: devicetree@vger.kernel.org Signed-off-by: Rob Herring <robh@kernel.org>
Diffstat (limited to 'drivers/of/address.c')
-rw-r--r--drivers/of/address.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/drivers/of/address.c b/drivers/of/address.c
index 7ddbf0a1ab86..ae48e121b6e7 100644
--- a/drivers/of/address.c
+++ b/drivers/of/address.c
@@ -110,8 +110,8 @@ static int of_bus_pci_match(struct device_node *np)
* "vci" is for the /chaos bridge on 1st-gen PCI powermacs
* "ht" is hypertransport
*/
- return !strcmp(np->type, "pci") || !strcmp(np->type, "pciex") ||
- !strcmp(np->type, "vci") || !strcmp(np->type, "ht");
+ return of_node_is_type(np, "pci") || of_node_is_type(np, "pciex") ||
+ of_node_is_type(np, "vci") || of_node_is_type(np, "ht");
}
static void of_bus_pci_count_cells(struct device_node *np,