Received: by 2002:ac0:a582:0:0:0:0:0 with SMTP id m2-v6csp3275455imm; Mon, 8 Oct 2018 00:51:04 -0700 (PDT) X-Google-Smtp-Source: ACcGV63TcwU659gois2Z3RFHecb3i6BoLPmfuvhiLwnAVivqYabvznRvihB2vVDI1EYqMQo/XtI3 X-Received: by 2002:a17:902:20c9:: with SMTP id v9-v6mr16400120plg.156.1538985064635; Mon, 08 Oct 2018 00:51:04 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1538985064; cv=none; d=google.com; s=arc-20160816; b=L8+dVILm7EQ265SanwoNd3hKOk5UKAI6YwgP23NDYeYpplKwueXN2R3Zyt8hQMEMKp NQq2ER6JzjqHqQS+8YGOKIpMmbO6XNKNAqfD/ORcFChGM33Fe2hmybRQ32+6xFA8lQJ3 43lhD0tD0k/Jhb35B11YZQSK5VPxqLTiqu4oMkPbParA/ihYrwZXOjO+WCvioGx6ax4Q OaQ6TkuREogFwKKjMkJcaP2+iGvxirwTWvCF/VACHOPyLzFEzpW3/O8bCMBD2Na6AWWz WY5Um7m42h/HJYolvGDIWKFn4jiBGP24WblFYFReDB+i7WOT4L/sZldM8r6qN7DBaLVS iDHA== 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; bh=bKtGuJm/toHEVogp9TsKtgAMFLSFOvjjQcDzVTciMFE=; b=itYqDLgz093Ley+u+GsBdCSaSnV/POtO44SLcpox5UqBKiQo5qWWPHLaRiMaQh5/yy Q70P3RgjpEqac6AtGP5Mj4m39DloIjhA6X4TeBbQlKyJonGFXBf3xGz8abEms7cVPaoi z0MvtcDIbPVlfl7oARwGZz//muQq9/V/UqPwFjyF6QQHIvsEBL0s5mx+7X55TDW56Bd+ k+aWMf7056xYn5CZo9+9j0BeGwHojhpxdJyMbD2JlP97ADjulI10kiuk4BXU8D369fTx pkE2pBFYRRUJvgkvRWSabAFil6ma61mZ9+F61HuB0e4VgwEYLxjmgheU3FnLMfJ5hid+ s4Vg== 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=nxp.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id k14-v6si16088630pga.149.2018.10.08.00.50.49; Mon, 08 Oct 2018 00:51:04 -0700 (PDT) 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=nxp.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1727166AbeJHO6t (ORCPT + 99 others); Mon, 8 Oct 2018 10:58:49 -0400 Received: from inva021.nxp.com ([92.121.34.21]:46752 "EHLO inva021.nxp.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1725983AbeJHO6t (ORCPT ); Mon, 8 Oct 2018 10:58:49 -0400 Received: from inva021.nxp.com (localhost [127.0.0.1]) by inva021.eu-rdc02.nxp.com (Postfix) with ESMTP id 38CC52000F2; Mon, 8 Oct 2018 09:48:23 +0200 (CEST) Received: from invc005.ap-rdc01.nxp.com (invc005.ap-rdc01.nxp.com [165.114.16.14]) by inva021.eu-rdc02.nxp.com (Postfix) with ESMTP id DC4CB200011; Mon, 8 Oct 2018 09:48:18 +0200 (CEST) Received: from titan.ap.freescale.net (TITAN.ap.freescale.net [10.192.208.233]) by invc005.ap-rdc01.nxp.com (Postfix) with ESMTP id C522A40309; Mon, 8 Oct 2018 15:48:12 +0800 (SGT) From: Yangbo Lu To: linux-kernel@vger.kernel.org, devel@driverdev.osuosl.org, netdev@vger.kernel.org, Richard Cochran , "David S . Miller" , Ioana Radulescu , Greg Kroah-Hartman , Andrew Lunn Cc: Yangbo Lu Subject: [v3, 4/6] net: dpaa2: rename rtc as ptp in dpaa2-ptp driver Date: Mon, 8 Oct 2018 15:44:28 +0800 Message-Id: <20181008074430.34379-4-yangbo.lu@nxp.com> X-Mailer: git-send-email 2.14.1 In-Reply-To: <20181008074430.34379-1-yangbo.lu@nxp.com> References: <20181008074430.34379-1-yangbo.lu@nxp.com> X-Virus-Scanned: ClamAV using ClamSMTP Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org In dpaa2-ptp driver, it's odd to use rtc in names of some functions and structures except these dprtc APIs. This patch is to use ptp instead of rtc in names. Signed-off-by: Yangbo Lu --- Changes for v2: - Added this patch. Changes for v3: - Modified commit message. --- drivers/net/ethernet/freescale/dpaa2/dpaa2-ptp.c | 30 +++++++++++----------- 1 files changed, 15 insertions(+), 15 deletions(-) diff --git a/drivers/net/ethernet/freescale/dpaa2/dpaa2-ptp.c b/drivers/net/ethernet/freescale/dpaa2/dpaa2-ptp.c index 2e90d5a..c73eef2 100644 --- a/drivers/net/ethernet/freescale/dpaa2/dpaa2-ptp.c +++ b/drivers/net/ethernet/freescale/dpaa2/dpaa2-ptp.c @@ -12,7 +12,7 @@ #include "dpaa2-ptp.h" struct ptp_dpaa2_priv { - struct fsl_mc_device *rtc_mc_dev; + struct fsl_mc_device *ptp_mc_dev; struct ptp_clock *clock; struct ptp_clock_info caps; u32 freq_comp; @@ -23,7 +23,7 @@ static int ptp_dpaa2_adjfreq(struct ptp_clock_info *ptp, s32 ppb) { struct ptp_dpaa2_priv *ptp_dpaa2 = container_of(ptp, struct ptp_dpaa2_priv, caps); - struct fsl_mc_device *mc_dev = ptp_dpaa2->rtc_mc_dev; + struct fsl_mc_device *mc_dev = ptp_dpaa2->ptp_mc_dev; struct device *dev = &mc_dev->dev; u64 adj; u32 diff, tmr_add; @@ -53,7 +53,7 @@ static int ptp_dpaa2_adjtime(struct ptp_clock_info *ptp, s64 delta) { struct ptp_dpaa2_priv *ptp_dpaa2 = container_of(ptp, struct ptp_dpaa2_priv, caps); - struct fsl_mc_device *mc_dev = ptp_dpaa2->rtc_mc_dev; + struct fsl_mc_device *mc_dev = ptp_dpaa2->ptp_mc_dev; struct device *dev = &mc_dev->dev; s64 now; int err = 0; @@ -78,7 +78,7 @@ static int ptp_dpaa2_gettime(struct ptp_clock_info *ptp, struct timespec64 *ts) { struct ptp_dpaa2_priv *ptp_dpaa2 = container_of(ptp, struct ptp_dpaa2_priv, caps); - struct fsl_mc_device *mc_dev = ptp_dpaa2->rtc_mc_dev; + struct fsl_mc_device *mc_dev = ptp_dpaa2->ptp_mc_dev; struct device *dev = &mc_dev->dev; u64 ns; u32 remainder; @@ -100,7 +100,7 @@ static int ptp_dpaa2_settime(struct ptp_clock_info *ptp, { struct ptp_dpaa2_priv *ptp_dpaa2 = container_of(ptp, struct ptp_dpaa2_priv, caps); - struct fsl_mc_device *mc_dev = ptp_dpaa2->rtc_mc_dev; + struct fsl_mc_device *mc_dev = ptp_dpaa2->ptp_mc_dev; struct device *dev = &mc_dev->dev; u64 ns; int err = 0; @@ -129,7 +129,7 @@ static int ptp_dpaa2_settime(struct ptp_clock_info *ptp, .settime64 = ptp_dpaa2_settime, }; -static int rtc_probe(struct fsl_mc_device *mc_dev) +static int dpaa2_ptp_probe(struct fsl_mc_device *mc_dev) { struct device *dev = &mc_dev->dev; struct ptp_dpaa2_priv *ptp_dpaa2; @@ -153,7 +153,7 @@ static int rtc_probe(struct fsl_mc_device *mc_dev) goto err_free_mcp; } - ptp_dpaa2->rtc_mc_dev = mc_dev; + ptp_dpaa2->ptp_mc_dev = mc_dev; err = dprtc_get_freq_compensation(mc_dev->mc_io, 0, mc_dev->mc_handle, &tmr_add); @@ -187,7 +187,7 @@ static int rtc_probe(struct fsl_mc_device *mc_dev) return err; } -static int rtc_remove(struct fsl_mc_device *mc_dev) +static int dpaa2_ptp_remove(struct fsl_mc_device *mc_dev) { struct ptp_dpaa2_priv *ptp_dpaa2; struct device *dev = &mc_dev->dev; @@ -204,26 +204,26 @@ static int rtc_remove(struct fsl_mc_device *mc_dev) return 0; } -static const struct fsl_mc_device_id rtc_match_id_table[] = { +static const struct fsl_mc_device_id dpaa2_ptp_match_id_table[] = { { .vendor = FSL_MC_VENDOR_FREESCALE, .obj_type = "dprtc", }, {} }; -MODULE_DEVICE_TABLE(fslmc, rtc_match_id_table); +MODULE_DEVICE_TABLE(fslmc, dpaa2_ptp_match_id_table); -static struct fsl_mc_driver rtc_drv = { +static struct fsl_mc_driver dpaa2_ptp_drv = { .driver = { .name = KBUILD_MODNAME, .owner = THIS_MODULE, }, - .probe = rtc_probe, - .remove = rtc_remove, - .match_id_table = rtc_match_id_table, + .probe = dpaa2_ptp_probe, + .remove = dpaa2_ptp_remove, + .match_id_table = dpaa2_ptp_match_id_table, }; -module_fsl_mc_driver(rtc_drv); +module_fsl_mc_driver(dpaa2_ptp_drv); MODULE_LICENSE("GPL v2"); MODULE_DESCRIPTION("DPAA2 PTP Clock Driver"); -- 1.7.1