From patchwork Sun Mar 29 21:11:58 2015 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Richard Cochran X-Patchwork-Id: 455941 X-Patchwork-Delegate: davem@davemloft.net Return-Path: X-Original-To: patchwork-incoming@ozlabs.org Delivered-To: patchwork-incoming@ozlabs.org Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by ozlabs.org (Postfix) with ESMTP id 8B97F1400A0 for ; Mon, 30 Mar 2015 08:18:05 +1100 (AEDT) Authentication-Results: ozlabs.org; dkim=fail reason="verification failed; unprotected key" header.d=gmail.com header.i=@gmail.com header.b=xpNU2452; dkim-adsp=none (unprotected policy); dkim-atps=neutral Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1753185AbbC2VMr (ORCPT ); Sun, 29 Mar 2015 17:12:47 -0400 Received: from mail-wg0-f49.google.com ([74.125.82.49]:33766 "EHLO mail-wg0-f49.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752873AbbC2VMk (ORCPT ); Sun, 29 Mar 2015 17:12:40 -0400 Received: by wgbgs4 with SMTP id gs4so59636593wgb.0; Sun, 29 Mar 2015 14:12:39 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=from:to:cc:subject:date:message-id:in-reply-to:references; bh=QXmy40Vlu346YKRDhqEQzz+1UWIzLM5CTisfYNRPDRg=; b=xpNU24526cLVST90SKzE5DeTlkMgRLPUawgNOMrBC5xDzfhYjCVuL2v8XiK5NwJ1T2 yJ4Qhn+lYE9XLCKwwrx0snSXm4wmgoF/+CWm6twsMss1IfJdxrEXcKm5T0KInVvAdixk EJZut8wxSAnyU/zjfWqF4aAYglv3nHYIoUMDnoSfm/5e8m6Vd1JRgSEhvQP+x9geugrd pyw1u2KTwp3ZDmgK8gO1oN7CyyHpL6ZvwL3IGGskrfSh3VwMgtxZyRv00Cw/IgEDtzdw 3KKuoqcV5oB4JwxMyOSLsFhmo7Y8DNMGFDmb9Gk67I2fSi1kQvfJoqn6o8p7SdoaWPpS 1A+Q== X-Received: by 10.181.9.98 with SMTP id dr2mr15778207wid.62.1427663559455; Sun, 29 Mar 2015 14:12:39 -0700 (PDT) Received: from hoboy.home (188-22-31-248.adsl.highway.telekom.at. [188.22.31.248]) by mx.google.com with ESMTPSA id ub1sm12743604wjc.43.2015.03.29.14.12.36 (version=TLSv1.2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Sun, 29 Mar 2015 14:12:38 -0700 (PDT) From: Richard Cochran To: Cc: , Amir Vadai , Ariel Elior , Arnd Bergmann , Baolin Wang , Ben Hutchings , Bruce Allan , Carolyn Wyborny , Chris Metcalf , David Miller , Frank Li , Giuseppe Cavallaro , Jacob Keller , Jeff Kirsher , John Stultz , Luwei Zhou , Matthew Vick , Michael Chan , Prashant Sreedharan , Rayagond K , Shradha Shah , Solarflare linux maintainers , Sonic Zhang , =?UTF-8?q?Stefan=20S=C3=B8rensen?= , Thomas Gleixner , Tom Lendacky Subject: [PATCH net-next V3 08/23] ptp: fec: convert to the 64 bit get/set time methods. Date: Sun, 29 Mar 2015 23:11:58 +0200 Message-Id: <256b6f98454f7be0f4e3d5a8e79ade9a798a416e.1427662907.git.richardcochran@gmail.com> X-Mailer: git-send-email 1.7.10.4 In-Reply-To: References: Sender: netdev-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: netdev@vger.kernel.org This driver's clock is implemented using a timecounter, and so with this patch the driver is ready for the year 2038. Compile tested only. Signed-off-by: Richard Cochran --- drivers/net/ethernet/freescale/fec_ptp.c | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/drivers/net/ethernet/freescale/fec_ptp.c b/drivers/net/ethernet/freescale/fec_ptp.c index 4585895..b833993 100644 --- a/drivers/net/ethernet/freescale/fec_ptp.c +++ b/drivers/net/ethernet/freescale/fec_ptp.c @@ -390,7 +390,7 @@ static int fec_ptp_adjtime(struct ptp_clock_info *ptp, s64 delta) * read the timecounter and return the correct value on ns, * after converting it into a struct timespec. */ -static int fec_ptp_gettime(struct ptp_clock_info *ptp, struct timespec *ts) +static int fec_ptp_gettime(struct ptp_clock_info *ptp, struct timespec64 *ts) { struct fec_enet_private *adapter = container_of(ptp, struct fec_enet_private, ptp_caps); @@ -417,7 +417,7 @@ static int fec_ptp_gettime(struct ptp_clock_info *ptp, struct timespec *ts) * wall timer value. */ static int fec_ptp_settime(struct ptp_clock_info *ptp, - const struct timespec *ts) + const struct timespec64 *ts) { struct fec_enet_private *fep = container_of(ptp, struct fec_enet_private, ptp_caps); @@ -584,8 +584,8 @@ void fec_ptp_init(struct platform_device *pdev) fep->ptp_caps.pps = 1; fep->ptp_caps.adjfreq = fec_ptp_adjfreq; fep->ptp_caps.adjtime = fec_ptp_adjtime; - fep->ptp_caps.gettime = fec_ptp_gettime; - fep->ptp_caps.settime = fec_ptp_settime; + fep->ptp_caps.gettime64 = fec_ptp_gettime; + fep->ptp_caps.settime64 = fec_ptp_settime; fep->ptp_caps.enable = fec_ptp_enable; fep->cycle_speed = clk_get_rate(fep->clk_ptp);