From patchwork Thu Apr 19 06:51:03 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: "\(Exiting\) Baolin Wang" X-Patchwork-Id: 133700 Delivered-To: patch@linaro.org Received: by 10.46.66.142 with SMTP id h14csp294149ljf; Wed, 18 Apr 2018 23:51:51 -0700 (PDT) X-Google-Smtp-Source: AIpwx4/UwOasXeB9N/g0Jz3oUG+PwNKqIkyDiXTBu/WU5qt1z3URQxJise3dxZHd3Lzo+G+wAQNj X-Received: by 10.99.139.202 with SMTP id j193mr3985569pge.300.1524120711359; Wed, 18 Apr 2018 23:51:51 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1524120711; cv=none; d=google.com; s=arc-20160816; b=uAdinoAsamaVZYEpO8T2rw1nz/17sOLoDDSFfVeadSVQCcG/R9AYQb0KRfYJkJzzxe 1Pqk0qf+eaBmLXS9JGNTWNiILOMfpuf/N+DIEsTXbE721/QEyMEjTyU9xF87lWwBacJb EhE2CdM8nMC1OodkrrjeQBxeQtGQMjBF1CqL7YzutfTCi7h4pKerBYKqGWeMsz5Fd0zv HzdyEFJtJMo+hh6IH3yzAQz9WNvi784rAkT5K3aK/EFEsGxsyfDdTZE2Ba/uOxak0bTo g+1A6PcK9j7I4QGjd5pVhlb4gcy8zGpBhwAmhYs/f/4f6MNXkUzBJF6Z0WmawtjwRck3 ydtw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:message-id:date:subject:cc:to:from :dkim-signature:arc-authentication-results; bh=aElWJpOtrwLEtUogDowdYYjo6Z48Bjs0JSoeUdrjOm4=; b=LZ8kCc8bxo3Guibri44eDbvNs350wGfllOzoHxQB+KnxypI4eRkb5FFaVXBayFjnZQ dI9usyJPG0GP3kSkde7rvEpdz8OJYX/8DE7FRJa0WI+bqzXx2EAKRHp93YSIY3rYNsJk ksZkTzH95zE5dGzr1da0HcIXWnjsvEgDM5vorodCIo+Z6UcHEXuQjYZA+ZGt8Wf3y/RL H117RHWlzFOip3O5a63cfN0SfFkiqbbrDfQ70QanxYZ5HlFW6oxQqsh1jIogsbGJWRe6 J4Fj4jQ/cXvOxyHdqj93f02A4hm5Csm+zc1nOrns4WIo+xzOQ1TaNhu++Md5KgsQGXst U7QQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=gyiTm2h+; 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=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id d14si874319pfl.122.2018.04.18.23.51.51; Wed, 18 Apr 2018 23:51:51 -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; dkim=pass header.i=@linaro.org header.s=google header.b=gyiTm2h+; 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=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1752028AbeDSGvt (ORCPT + 29 others); Thu, 19 Apr 2018 02:51:49 -0400 Received: from mail-pf0-f195.google.com ([209.85.192.195]:37132 "EHLO mail-pf0-f195.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751375AbeDSGvr (ORCPT ); Thu, 19 Apr 2018 02:51:47 -0400 Received: by mail-pf0-f195.google.com with SMTP id p6so2156993pfn.4 for ; Wed, 18 Apr 2018 23:51:47 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=from:to:cc:subject:date:message-id; bh=aElWJpOtrwLEtUogDowdYYjo6Z48Bjs0JSoeUdrjOm4=; b=gyiTm2h+MnjdYeewz0se4sQDWBm0OeDg99uII3MZclL1nGeYDB2TwKMqTauf9YNdjn aQUiPIddBuo30NU7yAN3UC1aS4AB/ANWWAExFVPA/DWwDS2hggLUVnENT5X+aI5+yXCt 2jCJgVNNLfAauo630DrsSmwWAaBoqqeSOlltE= 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; bh=aElWJpOtrwLEtUogDowdYYjo6Z48Bjs0JSoeUdrjOm4=; b=Y5pUzrjXAkpjTmk8YWVZaFzkwP4IWMNmguLcNKgyuxi0H6Y7pSksFuWnoG0w9XX94z AhPBmrWJga/I+WIc5czaengLIBbbhawo7N07vQR+ak9r203RRBUHgpOGyiOWFuN5VpVb SBYdSmLcw3EDowktJUlmCPaD1N0sLzKlMiNhfKNkklIhjzyLdowzLkrVrMGKl62s2rOk z/VmktMEM2EuV1LiUUMKKcFLm7SsMXLPHzcC+PGBN3A+Be6ecXmHZTOhKHRTXr/MevxP GOmA7cm2VL7v+O2NdYGn68yaXujLankudV5LzbsvG8EIrzTF0a0UMeB+qkFz+IJ8JS7X c8Wg== X-Gm-Message-State: ALQs6tCPxpPfnuQpDf1nnqBnj1FYONnE9qCDZPwGZGqEolzyb83QYDHz RFUdw1BOH50zDuex3IpcNOngXw== X-Received: by 10.101.102.198 with SMTP id c6mr2986086pgw.127.1524120707000; Wed, 18 Apr 2018 23:51:47 -0700 (PDT) Received: from baolinwangubtpc.spreadtrum.com ([117.18.48.82]) by smtp.gmail.com with ESMTPSA id c26sm5343260pfj.85.2018.04.18.23.51.42 (version=TLS1 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Wed, 18 Apr 2018 23:51:46 -0700 (PDT) From: Baolin Wang To: jejb@parisc-linux.org, deller@gmx.de Cc: alexandre.belloni@bootlin.com, kstewart@linuxfoundation.org, gregkh@linuxfoundation.org, tglx@linutronix.de, linux-parisc@vger.kernel.org, arnd@arndb.de, broonie@kernel.org, linux-kernel@vger.kernel.org, baolin.wang@linaro.org Subject: [PATCH] parisc: time: Convert read_persistent_clock() to read_persistent_clock64() Date: Thu, 19 Apr 2018 14:51:03 +0800 Message-Id: <4914b33abd8969906d2db0ae5c3da4f205f0bfe9.1524120572.git.baolin.wang@linaro.org> X-Mailer: git-send-email 1.7.9.5 Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org The read_persistent_clock() uses a timespec, which is not year 2038 safe on 32bit systems. On parisc architecture, we have implemented generic RTC drivers that can be used to compensate the system suspend time, but the RTC time can not represent the nanosecond resolution, so this patch just converts to read_persistent_clock64() with timespec64. Signed-off-by: Baolin Wang --- arch/parisc/kernel/time.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) -- 1.7.9.5 Acked-by: Arnd Bergmann diff --git a/arch/parisc/kernel/time.c b/arch/parisc/kernel/time.c index c383040..a1e772f 100644 --- a/arch/parisc/kernel/time.c +++ b/arch/parisc/kernel/time.c @@ -205,7 +205,7 @@ static int __init rtc_init(void) device_initcall(rtc_init); #endif -void read_persistent_clock(struct timespec *ts) +void read_persistent_clock64(struct timespec64 *ts) { static struct pdc_tod tod_data; if (pdc_tod_read(&tod_data) == 0) {