From patchwork Wed Dec 5 19:50:25 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: "Rob Herring \(Arm\)" X-Patchwork-Id: 152967 Delivered-To: patch@linaro.org Received: by 2002:a2e:299d:0:0:0:0:0 with SMTP id p29-v6csp9697419ljp; Wed, 5 Dec 2018 11:53:41 -0800 (PST) X-Google-Smtp-Source: AFSGD/WCsn/5vQs1kv6KF5fwQTxbZZlmIUj2QpWY3UeAJMU4/IUIZei5ITKGMhDFBJo++t/goB66 X-Received: by 2002:a17:902:6bc9:: with SMTP id m9mr6340056plt.173.1544039621119; Wed, 05 Dec 2018 11:53:41 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1544039621; cv=none; d=google.com; s=arc-20160816; b=ilE3w0yAF3ixSpqbgF411RhYb4/JCkCLUBBo3up7kezrRSShhCPz/xGy67/dn4x8wv fJdHtm+n3ZoftCssFyOWloiOoANXzPMX05NN28Gb2MEkxQO4CbScIP0x4/whsKkuS70C ZKbpoXnAsRUFfSxCE4syhWqxgEsXamUBNP+hZ+IrvM0pnhQoPHlu4eRpS9J0YcFKvTWG B5VKTjRh6gJWzyyEXooCbX9dlm7KDrHbG0zEFbMIu3aR3EiRjo83NpM11c3Isw3XT1A8 0Srwc8IuAX8dxoUV/xbSeq+k+app+7PLb0M0ojHmz6/d7TXxOO/sltn8LUNqzJt1hg7B eXZg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:content-transfer-encoding:mime-version :message-id:date:subject:cc:to:from; bh=SJ9ws45Vv3vAPydB9eOaRCa8LnZGc1t7yjxAlBirVB0=; b=Yf5Oplp/xrHcabf750buh9AQB3zkRDJTC8zGrP86Nsjaw/ePCOpyavuFT1tGFSqL8N w0intvxm4Ycnh+nzoZ6xIlOCYJ89fcTwn7IZggQbjXy7X7JqpndZyZpCTBhYpuvpt+O+ +pe91IZbsKR7hsN4AUI67S24A0rnewQ+YtXUwVp0BVGW3tYPumiCHJSVzpIoWUt0QBk0 pzj7gEEYhjP30Yj9AUzLvgdq/glcjx5H99/t3dR06K+Jrq8Pdx2qafZcEqWFTlLrx1Sf vO1NsFHQU7pjSZa0P0ytpkYT0lOmuJSMBi63e0trihundoRdXCbweUroDgPplhtdWpKp B25g== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id z6si19212709pln.66.2018.12.05.11.53.40; Wed, 05 Dec 2018 11:53:41 -0800 (PST) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1728921AbeLETxj (ORCPT + 31 others); Wed, 5 Dec 2018 14:53:39 -0500 Received: from mail-oi1-f196.google.com ([209.85.167.196]:43180 "EHLO mail-oi1-f196.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1728664AbeLETvC (ORCPT ); Wed, 5 Dec 2018 14:51:02 -0500 Received: by mail-oi1-f196.google.com with SMTP id u18so18623373oie.10; Wed, 05 Dec 2018 11:51:01 -0800 (PST) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:mime-version :content-transfer-encoding; bh=SJ9ws45Vv3vAPydB9eOaRCa8LnZGc1t7yjxAlBirVB0=; b=a7SEdWWKb7lD1EA4Ekt+36TeN74a0F9+ZfvPbHtJovekSXt4tFRC53UITgZn58IxJx 8q0hP7CGo3fUe/c7kq+5oIeKn00bf8Q/+5XuyQ4crZbUQYUnG518JMt+D4aWa/I8xdHz bwY/d/NxWnLNxmjvWC8TeGUhQ6Z7VJvQQJK+6hwJIzbKYxTwYW6LLe+ODuElhnwlJShP oEYcPgFN6+rbTW308KtDJ4flpzsByIIF+oRIamG8+W0oFVLgqL9YR0447zFXLxLHz2wY LSinGTd7guD00VOhHbXbL8SrJcp+ADg2ZzVTXdy8H0DnodORn8CzjYD3h0U2+XVebSQ7 IgSQ== X-Gm-Message-State: AA+aEWbe+SomKoVD+AdyiJfhafz1DDq1HTCGqSRXGaGIfKKLh+rktTwn INbhoApkWbAMbBTB5lpr7tRwiqY= X-Received: by 2002:aca:da02:: with SMTP id r2mr15033923oig.66.1544039461139; Wed, 05 Dec 2018 11:51:01 -0800 (PST) Received: from xps15.herring.priv (24-155-109-49.dyn.grandenetworks.net. [24.155.109.49]) by smtp.googlemail.com with ESMTPSA id k13sm25759879otj.19.2018.12.05.11.51.00 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Wed, 05 Dec 2018 11:51:00 -0800 (PST) From: Rob Herring To: devicetree@vger.kernel.org, linux-kernel@vger.kernel.org Cc: "David S. Miller" , Benjamin Herrenschmidt , Paul Mackerras , Michael Ellerman , linux-ide@vger.kernel.org, linuxppc-dev@lists.ozlabs.org Subject: [PATCH] ide: Use of_node_name_eq for node name comparisons Date: Wed, 5 Dec 2018 13:50:25 -0600 Message-Id: <20181205195050.4759-9-robh@kernel.org> X-Mailer: git-send-email 2.19.1 MIME-Version: 1.0 Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org 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" Cc: Benjamin Herrenschmidt Cc: Paul Mackerras Cc: Michael Ellerman Cc: linux-ide@vger.kernel.org Cc: linuxppc-dev@lists.ozlabs.org Signed-off-by: Rob Herring --- drivers/ide/pmac.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) -- 2.19.1 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;