From patchwork Mon Feb 12 14:58:28 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Jerome Brunet X-Patchwork-Id: 128143 Delivered-To: patch@linaro.org Received: by 10.46.124.24 with SMTP id x24csp3296741ljc; Mon, 12 Feb 2018 07:07:13 -0800 (PST) X-Google-Smtp-Source: AH8x225UaoIayI61/KfZgew5Q157ydnhBmJWdC5MUg7JLZdg29XmBdfsD8zblRX4B+nRuKlN3P57 X-Received: by 10.98.138.70 with SMTP id y67mr12145729pfd.176.1518448033115; Mon, 12 Feb 2018 07:07:13 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1518448033; cv=none; d=google.com; s=arc-20160816; b=Yi2WAIkTw/NX7TFtTmbiuEKPe1qVkdVNVbCZKJ2JIId1gimCCzDBX0X5fk0Y8HyAvq lhc2MqXLiKKJblvZnz+u4iZ0rf/fcVYYc0Ab2G5Q25ochqGXclOY1MmWqdrPjXkv4Q8g jpQv4yeEGU89LJdg4vo1iUNsRTRAum+e12q4tQg0hZFXWYGEf9FhRTZ48qFE/iYVp73k uZ/7Jjwqo9ZsduRVFbl8MPHM/hV922bLID+flb/2Xou3e8SOS+CIbeTPINpPCNBBZWSI o2yStv87fR2940HjgsxV/RYLdqTrwGXhKlqW0avolcdrE5FtRKfIR3uFttYGm1V9RnvN 8s8A== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:references:in-reply-to:message-id:date :subject:cc:to:from:dkim-signature:arc-authentication-results; bh=1r6UtNaqlpeI8IHSSUmjJQadr+t+nZpwOk9+kyDl2uM=; b=iPPWOSNU+RlYfYJ4YLOtX3xr7/zW/0WKcQ7iQU4+SC3x1+OCQxy/FhJxHiotn8z0L0 QoQwrlZ6vMph9SncEaiWqdvfPpnMABBgJnwaZ2b//egXdGG22pd8YFmlrMkKopl8bhhl nUcF0MF7+LxQCs9ce2FjKZtQM6LvXqFMMJTB14yRYIiFi5EwCjI5ZasTNHeyUFvKJdGK QACZtCz3FSrai4gRvqOi3asdzxniU1YhB4uOSDgDhs7213P7I9sljiOqF2EaIw23Qv3S pd5S6NrUI49RGOQMR2gyYcOByBeN6T/rks1cX64W/ZT2mLy64g70DXbpfu2obK+5DViw JfjQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@baylibre-com.20150623.gappssmtp.com header.s=20150623 header.b=K+1hyVNT; 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 k136si5268776pga.44.2018.02.12.07.07.12; Mon, 12 Feb 2018 07:07:13 -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=@baylibre-com.20150623.gappssmtp.com header.s=20150623 header.b=K+1hyVNT; 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 S934980AbeBLPHJ (ORCPT + 15 others); Mon, 12 Feb 2018 10:07:09 -0500 Received: from mail-wr0-f194.google.com ([209.85.128.194]:44123 "EHLO mail-wr0-f194.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S932250AbeBLO6w (ORCPT ); Mon, 12 Feb 2018 09:58:52 -0500 Received: by mail-wr0-f194.google.com with SMTP id v65so8695811wrc.11 for ; Mon, 12 Feb 2018 06:58:51 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=baylibre-com.20150623.gappssmtp.com; s=20150623; h=from:to:cc:subject:date:message-id:in-reply-to:references; bh=1r6UtNaqlpeI8IHSSUmjJQadr+t+nZpwOk9+kyDl2uM=; b=K+1hyVNTgwguCKBZZqkF2GAmfW7eqnHpoiTbNXZV+TwINciYGD307pwR3jjZq6taBB qOJTrZJcOKVBusg8cX5UdMP2I4CJ2zdVQeUZGqsNPrBpOyNOdhi0F6HsbEmNthUmyTuP HuN60by3dBu5SPQ1IxPUAA8iqXmN3HWF3AR8PfjKw9fRUhRSvcYDnx8Y4Bm15pD9deAb tj6zqD9g/O2Ibosm/f+gimY4JMa/DnE2MbS2GB95RfInAwBCBh4jy7uTF0Y/eKEVlHcH SY0U5Kd8PhoHc+7Loyagixk/UBfWrrdKl3BTUzTgo05hL0zqeB9KTpEzfRcJ30tNPbSE Bnjg== 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; bh=1r6UtNaqlpeI8IHSSUmjJQadr+t+nZpwOk9+kyDl2uM=; b=mKex4D080IfJE7gCVWV3cr5zgmty4WKSt5JPgCx4+B31FjKw1HuuW7uQmVNigMk2+4 sxvfiXWESJE2azIphumX5LUc1u0/C3PmcwzIr+T3HlAR4/SQbHq1OeH3TdWFd/YgyR0L 4zaHxbxiFIV/+Ij9WS0lvz5w+D0AuWj9M+kRwTJK31eM4LS7hkRCXByBQ9Al4HuDuvge PkibDT8iiNlARTR8DuZVBj7SwV8M8qEHyZO/eVJHKUZ4JaNfMuB1I1xm9eIa4eEEywTR kPEkSmFjzJryA2eZfKbINeffNqXBM5qaEielA2Sbi/so6l9k/53nVhSHt3danjk3SMsp mmIg== X-Gm-Message-State: APf1xPBiRfdkmnJSTfVqn2RK/zGdcp2c165K5LiKUbztUlkJpjM3KBzX WFCSmcs7vGoO84qCYdq++khOhA== X-Received: by 10.223.144.46 with SMTP id h43mr6077899wrh.125.1518447531180; Mon, 12 Feb 2018 06:58:51 -0800 (PST) Received: from boomer.baylibre.local ([90.63.244.31]) by smtp.googlemail.com with ESMTPSA id p21sm4633218wmc.28.2018.02.12.06.58.50 (version=TLS1_2 cipher=ECDHE-RSA-CHACHA20-POLY1305 bits=256/256); Mon, 12 Feb 2018 06:58:50 -0800 (PST) From: Jerome Brunet To: Neil Armstrong , Kevin Hilman Cc: Jerome Brunet , Stephen Boyd , Michael Turquette , Carlo Caione , linux-amlogic@lists.infradead.org, linux-clk@vger.kernel.org, linux-kernel@vger.kernel.org Subject: [PATCH v2 01/19] clk: meson: use dev pointer where possible Date: Mon, 12 Feb 2018 15:58:28 +0100 Message-Id: <20180212145846.19380-2-jbrunet@baylibre.com> X-Mailer: git-send-email 2.14.3 In-Reply-To: <20180212145846.19380-1-jbrunet@baylibre.com> References: <20180212145846.19380-1-jbrunet@baylibre.com> Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org The 'dev' pointer is directly available in gxbb and axg clock controller, so consistently use it instead of going the through the 'pdev' pointer once in while Signed-off-by: Jerome Brunet --- drivers/clk/meson/axg.c | 8 ++++---- drivers/clk/meson/gxbb.c | 2 +- 2 files changed, 5 insertions(+), 5 deletions(-) -- 2.14.3 diff --git a/drivers/clk/meson/axg.c b/drivers/clk/meson/axg.c index 2dc70e0e925c..1f48649a7d2a 100644 --- a/drivers/clk/meson/axg.c +++ b/drivers/clk/meson/axg.c @@ -804,7 +804,7 @@ static int axg_clkc_probe(struct platform_device *pdev) void __iomem *clk_base; int ret, clkid, i; - clkc_data = of_device_get_match_data(&pdev->dev); + clkc_data = of_device_get_match_data(dev); if (!clkc_data) return -EINVAL; @@ -812,9 +812,9 @@ static int axg_clkc_probe(struct platform_device *pdev) res = platform_get_resource(pdev, IORESOURCE_MEM, 0); if (!res) return -EINVAL; - clk_base = devm_ioremap(&pdev->dev, res->start, resource_size(res)); + clk_base = devm_ioremap(dev, res->start, resource_size(res)); if (!clk_base) { - dev_err(&pdev->dev, "Unable to map clk base\n"); + dev_err(dev, "Unable to map clk base\n"); return -ENXIO; } @@ -849,7 +849,7 @@ static int axg_clkc_probe(struct platform_device *pdev) ret = devm_clk_hw_register(dev, clkc_data->hw_onecell_data->hws[clkid]); if (ret) { - dev_err(&pdev->dev, "Clock registration failed\n"); + dev_err(dev, "Clock registration failed\n"); return ret; } } diff --git a/drivers/clk/meson/gxbb.c b/drivers/clk/meson/gxbb.c index a5f25cc1944c..423abcb8ef88 100644 --- a/drivers/clk/meson/gxbb.c +++ b/drivers/clk/meson/gxbb.c @@ -1950,7 +1950,7 @@ static int gxbb_clkc_probe(struct platform_device *pdev) int ret, clkid, i; struct device *dev = &pdev->dev; - clkc_data = of_device_get_match_data(&pdev->dev); + clkc_data = of_device_get_match_data(dev); if (!clkc_data) return -EINVAL;