Received: by 2002:a25:7ec1:0:0:0:0:0 with SMTP id z184csp6880330ybc; Thu, 28 Nov 2019 07:04:28 -0800 (PST) X-Google-Smtp-Source: APXvYqzt7sV7I4zzCf/eL1lnNPJHWMGq/z10eU/AJ7XmcSdHliCtRrffWzh3J3iGa5aQwHBUMl2y X-Received: by 2002:a05:6214:2b4:: with SMTP id m20mr11353137qvv.48.1574953467869; Thu, 28 Nov 2019 07:04:27 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1574953467; cv=none; d=google.com; s=arc-20160816; b=sZMF/Bs6VHUeD/700QpTzo9EbbWeaJJNKQ7+GqYOA9CsAvIwguRyD1/zR8Uva9d9E3 qjlSgtBycnlmYMb2FXFETzCdsA19k097ccjVyAt6lam+0EFL4+t7yZKh4+IFp/jRe667 tDpRuN/hCpSSvFZlXt/MaQ4mrvufGrHXCVApyCW/9Av32H0/n07EPEgjlMwTM/c7Tzz8 lwwOcKRxsxsfIBklRI495TTfm1+3j7zQOshnFt75A2f5IDT04XV7f4gACyPabTQW1EwE 44KpWLuzj15kmx+MyWAH5O2u4TzlTewfgV8+xMdBiL1xD94MSDSlHNI/sXo22WuYvhgT l44w== 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 :references:in-reply-to:message-id:date:subject:cc:to:from :dkim-signature; bh=nzzyzsivy+YcXl/jyzCYf1SBk8p4BrEyK9ScDwPsYTY=; b=PG/y0ICHYXfR9tlgIOfhDLG+GJvJgNjgNM0yL/+NaD2kwZF8+lCkCKptgdILhy3ZXO 4j1InhbzKB/UrOZsXN1xDjDptz5LFlouEv6Mnd6f1NbioProecJVp0c6xG+EmOEyazbZ VKSYd/aucuCEjkPfYW8y/pcfS9vnQrUdMQDTC87+HyrYEgThOOORaAyt0jYiaLbQZUWZ eilO742Zsky69AosE8969K0eo1dNjrEIwgmViTsIChk5NxtKIfq77V63s/cWU7A1GybP u6u+Hf1DB6klxsgDQ4D+HB2yZAoGAhgLiksVPbNlZvt42kcUVGy0uPf1p1G56xfnOM+W YxPw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@rasmusvillemoes.dk header.s=google header.b=K2wEiOKx; 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 Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id bt12si12241884edb.85.2019.11.28.07.03.59; Thu, 28 Nov 2019 07:04:27 -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; dkim=pass header.i=@rasmusvillemoes.dk header.s=google header.b=K2wEiOKx; 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 Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1727428AbfK1O7d (ORCPT + 99 others); Thu, 28 Nov 2019 09:59:33 -0500 Received: from mail-lj1-f194.google.com ([209.85.208.194]:42484 "EHLO mail-lj1-f194.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1727391AbfK1O5h (ORCPT ); Thu, 28 Nov 2019 09:57:37 -0500 Received: by mail-lj1-f194.google.com with SMTP id e28so4647807ljo.9 for ; Thu, 28 Nov 2019 06:57:35 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=rasmusvillemoes.dk; s=google; h=from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=nzzyzsivy+YcXl/jyzCYf1SBk8p4BrEyK9ScDwPsYTY=; b=K2wEiOKx+dAnA20pPj/gC7k2WKFK03JPBFAMB2+x1KJ6IuQ/uzYy9NIfORoCqtv3pO dWqQg66agfm4ME7e+/iKZAKKQcUv7xPOdFY+K30U/ZIKEFr2OWIUlEL30xH0BCtMLQa4 fBZ6XqpmIXYhwdW204OYq/yNppQkLMCsU8gWI= 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:in-reply-to :references:mime-version:content-transfer-encoding; bh=nzzyzsivy+YcXl/jyzCYf1SBk8p4BrEyK9ScDwPsYTY=; b=B0yCp/iHJbdefbX8UUvq98HZYF3L0udVwfyJmX+lljsVWwyD1XbkwXzb8yyna+YyhM SZW0bRe3Xey+ySuyrh1Z3pGBGyoUNy+9kCLlmStsUegClF5modzlzUTeeFkRL/QaqwNu LnuDcXChH6B8GPuSHNhhPkTRvYCVskcI/JXsgS77e2mt+g96UZNqmj3aWQi7n80p/0VN vBB+TjAe6HfsUMEAWCzwcdzeKUOV1T6OzGtTzjJnNnLCvIt02EstE5+7WYrWotsKo7za rDTyP+9RAR+UIj+837CJypO2NadbOeWGtVD3AgCvh6Z9uAbvwxEA6YIf0yXqQPSwRKM5 syFQ== X-Gm-Message-State: APjAAAVkJsJvT2ItViF+9co/DMYQNe+hXTD7zbp730BeT4fz/uWkzIw2 AO7HYgaSxwz69jdO0/BIa+uYZQ== X-Received: by 2002:a2e:9f4d:: with SMTP id v13mr35083259ljk.78.1574953054971; Thu, 28 Nov 2019 06:57:34 -0800 (PST) Received: from prevas-ravi.prevas.se ([81.216.59.226]) by smtp.gmail.com with ESMTPSA id u2sm2456803lfl.18.2019.11.28.06.57.33 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 28 Nov 2019 06:57:34 -0800 (PST) From: Rasmus Villemoes To: Qiang Zhao , Li Yang , Christophe Leroy Cc: linuxppc-dev@lists.ozlabs.org, linux-arm-kernel@lists.infradead.org, linux-kernel@vger.kernel.org, Scott Wood , Timur Tabi , Rasmus Villemoes Subject: [PATCH v6 23/49] soc: fsl: qe: qe_io.c: don't open-code of_parse_phandle() Date: Thu, 28 Nov 2019 15:55:28 +0100 Message-Id: <20191128145554.1297-24-linux@rasmusvillemoes.dk> X-Mailer: git-send-email 2.23.0 In-Reply-To: <20191128145554.1297-1-linux@rasmusvillemoes.dk> References: <20191128145554.1297-1-linux@rasmusvillemoes.dk> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Reviewed-by: Timur Tabi Signed-off-by: Rasmus Villemoes --- drivers/soc/fsl/qe/qe_io.c | 7 ++----- 1 file changed, 2 insertions(+), 5 deletions(-) diff --git a/drivers/soc/fsl/qe/qe_io.c b/drivers/soc/fsl/qe/qe_io.c index f6b10f38b2f4..99aeb01586bd 100644 --- a/drivers/soc/fsl/qe/qe_io.c +++ b/drivers/soc/fsl/qe/qe_io.c @@ -141,7 +141,6 @@ EXPORT_SYMBOL(par_io_data_set); int par_io_of_config(struct device_node *np) { struct device_node *pio; - const phandle *ph; int pio_map_len; const unsigned int *pio_map; @@ -150,14 +149,12 @@ int par_io_of_config(struct device_node *np) return -1; } - ph = of_get_property(np, "pio-handle", NULL); - if (ph == NULL) { + pio = of_parse_phandle(np, "pio-handle", 0); + if (pio == NULL) { printk(KERN_ERR "pio-handle not available\n"); return -1; } - pio = of_find_node_by_phandle(*ph); - pio_map = of_get_property(pio, "pio-map", &pio_map_len); if (pio_map == NULL) { printk(KERN_ERR "pio-map is not set!\n"); -- 2.23.0