From patchwork Sat Jan 19 16:18:45 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: Guenter Roeck X-Patchwork-Id: 1027983 Return-Path: X-Original-To: patchwork-incoming@ozlabs.org Delivered-To: patchwork-incoming@ozlabs.org Received: from lists.ozlabs.org (lists.ozlabs.org [IPv6:2401:3900:2:1::3]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (2048 bits)) (No client certificate requested) by ozlabs.org (Postfix) with ESMTPS id 43hjhN44Cfz9sBQ for ; Sun, 20 Jan 2019 03:20:04 +1100 (AEDT) Authentication-Results: ozlabs.org; dmarc=none (p=none dis=none) header.from=roeck-us.net Authentication-Results: ozlabs.org; dkim=fail reason="signature verification failed" (2048-bit key; unprotected) header.d=gmail.com header.i=@gmail.com header.b="ZLiTw/CX"; dkim-atps=neutral Received: from lists.ozlabs.org (lists.ozlabs.org [IPv6:2401:3900:2:1::3]) by lists.ozlabs.org (Postfix) with ESMTP id 43hjhN2nGMzDqVH for ; Sun, 20 Jan 2019 03:20:04 +1100 (AEDT) X-Original-To: linuxppc-dev@lists.ozlabs.org Delivered-To: linuxppc-dev@lists.ozlabs.org Authentication-Results: lists.ozlabs.org; spf=pass (mailfrom) smtp.mailfrom=gmail.com (client-ip=2607:f8b0:4864:20::443; helo=mail-pf1-x443.google.com; envelope-from=groeck7@gmail.com; receiver=) Authentication-Results: lists.ozlabs.org; dmarc=none (p=none dis=none) header.from=roeck-us.net Authentication-Results: lists.ozlabs.org; dkim=pass (2048-bit key; unprotected) header.d=gmail.com header.i=@gmail.com header.b="ZLiTw/CX"; dkim-atps=neutral Received: from mail-pf1-x443.google.com (mail-pf1-x443.google.com [IPv6:2607:f8b0:4864:20::443]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by lists.ozlabs.org (Postfix) with ESMTPS id 43hjg04H9jzDqtr for ; Sun, 20 Jan 2019 03:18:52 +1100 (AEDT) Received: by mail-pf1-x443.google.com with SMTP id z9so8114367pfi.2 for ; Sat, 19 Jan 2019 08:18:52 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=sender:from:to:cc:subject:date:message-id:mime-version :content-transfer-encoding; bh=p2JF6kCxDVwm8ztbo8DbVkB8buCPaFSdA3+ZOMTjwkM=; b=ZLiTw/CXvBtjwyP+b3HA/yOdrHasdukHyaN6/wZirWWGx9OG3v+a30Py2h9jHoJ7Ry /rSnbzrzDwQuD94mhLoVlk7PrhHb+uzYi8BtA4exDWbI+2RKHspc8EQAP8iYaz8dVJ1d YZutH9PtQd0wDltZuooF6B83Oz7EYRFMxbTQdLhaj2MvnC7sy4p+N7cUz384f3mlYg8X JT4FmSyt1YIjy1Gled6wthM43OhU8JggppJnBQ+xLEaSoFdiHFkFh0EMYJxJSlcPulNo EpAOqActKeYTd8IAR7r/hECfF2YhBgJw00kYBjpgJedOQIKgHSOA/zYTNviXA/UknD79 qJPw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:sender:from:to:cc:subject:date:message-id :mime-version:content-transfer-encoding; bh=p2JF6kCxDVwm8ztbo8DbVkB8buCPaFSdA3+ZOMTjwkM=; b=SVs/WGU8Amad8VwhzBxrFzK2JI1mJNChSrM4GsgbDK6RTZfynSG1YZbZSOns1KHLZt ruywocKyPdS7u206f5Bte5PbrWzbP5jQc64KZPknxoS0An5jSuCXN6Q9DBgIDzW5BC+f 2Fm3QlwSdwKoK7R14IjIrc/6TF64BaEmZS1ApzBucsq9XjUw/dF2heLQduMtBveKvgyT Y/gerkKUMdnlDy9U4pTrwn+OZuBV37OSY2cMr5z41lIquX6xsG+XUBtsDuuQ4h8FTuvy uf2+FsarISq/XyfBigU/uHB3espvv6g+8amMoxMatCDPrnTDhznpA1VPDHqASP9MVSQm Kexw== X-Gm-Message-State: AJcUukf0NxRU/HZHYY99VUo9HPiCH3QAhPD5G5yCDjCdZExHnDi8zflS 31imCJbRHlOsccAKk9y/kac= X-Google-Smtp-Source: ALg8bN4HtuFQjUdq0KEw4xzV43Dbambc7GeLtCaeSodr71/pe2oY5aBPk6qJM9PbTzbp1CLLaMQCSw== X-Received: by 2002:a62:2cf:: with SMTP id 198mr23792285pfc.67.1547914730497; Sat, 19 Jan 2019 08:18:50 -0800 (PST) Received: from localhost ([2600:1700:e321:62f0:329c:23ff:fee3:9d7c]) by smtp.gmail.com with ESMTPSA id d16sm8748888pgj.21.2019.01.19.08.18.49 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Sat, 19 Jan 2019 08:18:49 -0800 (PST) From: Guenter Roeck To: Benjamin Herrenschmidt Subject: [PATCH v2] powerpc: chrp: Use device_type helpers to access the node type Date: Sat, 19 Jan 2019 08:18:45 -0800 Message-Id: <1547914725-12125-1-git-send-email-linux@roeck-us.net> X-Mailer: git-send-email 2.7.4 MIME-Version: 1.0 X-BeenThere: linuxppc-dev@lists.ozlabs.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Linux on PowerPC Developers Mail List List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: Rob Herring , linux-kernel@vger.kernel.org, Paul Mackerras , linuxppc-dev@lists.ozlabs.org, Guenter Roeck Errors-To: linuxppc-dev-bounces+patchwork-incoming=ozlabs.org@lists.ozlabs.org Sender: "Linuxppc-dev" The node type can no longer be accessed directly, resulting in the following build error. Use accessor function instead. arch/powerpc/platforms/chrp/setup.c: In function ‘chrp_init_IRQ’: arch/powerpc/platforms/chrp/setup.c:541:33: error: ‘struct device_node’ has no member named ‘type’ Fixes: 8ce5f8415753 ("of: Remove struct device_node.type pointer") Cc: Rob Herring Signed-off-by: Guenter Roeck --- v2: of_node_is_type() checks if the node pointer is NULL, so there is no need to check it before calling the function. arch/powerpc/platforms/chrp/setup.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/arch/powerpc/platforms/chrp/setup.c b/arch/powerpc/platforms/chrp/setup.c index e66644e0fb40..9438fa0fc355 100644 --- a/arch/powerpc/platforms/chrp/setup.c +++ b/arch/powerpc/platforms/chrp/setup.c @@ -538,8 +538,7 @@ static void __init chrp_init_IRQ(void) /* see if there is a keyboard in the device tree with a parent of type "adb" */ for_each_node_by_name(kbd, "keyboard") - if (kbd->parent && kbd->parent->type - && strcmp(kbd->parent->type, "adb") == 0) + if (of_node_is_type(kbd->parent, "adb")) break; of_node_put(kbd); if (kbd)