summaryrefslogtreecommitdiff
path: root/drivers/ide
diff options
context:
space:
mode:
authorRob Herring <robh@kernel.org>2018-12-05 13:50:25 -0600
committerMichael Ellerman <mpe@ellerman.id.au>2018-12-22 21:29:50 +1100
commitc1fa31b0fc90a80d64a334e5d35dca211f9187f6 (patch)
treef2f31568de788f450d50210c3dc39abb04fc5bfd /drivers/ide
parent2c8e65b595cf0bf7c1413404dff9b928a64d27cb (diff)
downloadlinux-next-c1fa31b0fc90a80d64a334e5d35dca211f9187f6.tar.gz
ide: Use of_node_name_eq for node name comparisons
Convert string compares of DT node names to use of_node_name_eq helper instead. This removes direct access to the node name pointer. Cc: "David S. Miller" <davem@davemloft.net> Cc: Benjamin Herrenschmidt <benh@kernel.crashing.org> Cc: Paul Mackerras <paulus@samba.org> Cc: Michael Ellerman <mpe@ellerman.id.au> Cc: linux-ide@vger.kernel.org Cc: linuxppc-dev@lists.ozlabs.org Signed-off-by: Rob Herring <robh@kernel.org> Signed-off-by: Michael Ellerman <mpe@ellerman.id.au>
Diffstat (limited to 'drivers/ide')
-rw-r--r--drivers/ide/pmac.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/ide/pmac.c b/drivers/ide/pmac.c
index c5b902b86b44..ec46aa84d18d 100644
--- a/drivers/ide/pmac.c
+++ b/drivers/ide/pmac.c
@@ -1045,7 +1045,7 @@ static int pmac_ide_setup_device(pmac_ide_hwif_t *pmif, struct ide_hw *hw)
d.port_ops = &pmac_ide_ata4_port_ops;
d.udma_mask = ATA_UDMA5;
} else if (of_device_is_compatible(np, "keylargo-ata")) {
- if (strcmp(np->name, "ata-4") == 0) {
+ if (of_node_name_eq(np, "ata-4")) {
pmif->kind = controller_kl_ata4;
d.port_ops = &pmac_ide_ata4_port_ops;
d.udma_mask = ATA_UDMA4;