From patchwork Mon Oct 27 05:46:36 2014 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: "pang.xunlei" X-Patchwork-Id: 39554 Return-Path: X-Original-To: linaro@patches.linaro.org Delivered-To: linaro@patches.linaro.org Received: from mail-wg0-f70.google.com (mail-wg0-f70.google.com [74.125.82.70]) by ip-10-151-82-157.ec2.internal (Postfix) with ESMTPS id 5E51F24026 for ; Mon, 27 Oct 2014 05:49:19 +0000 (UTC) Received: by mail-wg0-f70.google.com with SMTP id x13sf521330wgg.9 for ; Sun, 26 Oct 2014 22:49:18 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:mime-version:delivered-to:from:to:cc:subject :date:message-id:in-reply-to:references:sender:precedence:list-id :x-original-sender:x-original-authentication-results:mailing-list :list-post:list-help:list-archive:list-unsubscribe; bh=cGEECV8hCCFLchkBPzJL0k1D7NDXQY2p6riv7hJLSBo=; b=EmWZn8kHlA2tfNUcr71AzG7Yz7vvjkoyA9l8WfaUTkssCyVYYK9EQxv1rLu2x/97xO OHjHhk1jXCWmkjsQNjkTJsvttcclqSdKP0PtaNEcMzIRfqAuIwytsQJiDzbEfWxWpLlu J5K5k9kLwjsS3mZiox+MrazUO8abiEEl1taroP6l4NWz+jL3UzqV9claL9K0yZRCFO6r fuNSTp3JWU20fFpwU07qtFBmPgV2bn/kvSuupA9xxTdHefwPlqYTQQDSTAEOFXJtMuTi fUso/0RFYVKO2VYJaTntl9Tj+3WhWWqMBA8p/NwQpKC1NOuTtPERdV1nYP5kWQreg/+3 2ohw== X-Gm-Message-State: ALoCoQmEetRj0HsQflhXeYtSv/lLiQ0sttmKIDVZmGGtuBzjMteFy7wNj0F1uJWtfEW9xUTNPL0O X-Received: by 10.112.38.101 with SMTP id f5mr818127lbk.7.1414388958550; Sun, 26 Oct 2014 22:49:18 -0700 (PDT) MIME-Version: 1.0 X-BeenThere: patchwork-forward@linaro.org Received: by 10.152.36.97 with SMTP id p1ls538941laj.87.gmail; Sun, 26 Oct 2014 22:49:18 -0700 (PDT) X-Received: by 10.112.134.39 with SMTP id ph7mr20971966lbb.45.1414388958385; Sun, 26 Oct 2014 22:49:18 -0700 (PDT) Received: from mail-la0-f49.google.com (mail-la0-f49.google.com. [209.85.215.49]) by mx.google.com with ESMTPS id rt5si18291041lbb.2.2014.10.26.22.49.18 for (version=TLSv1 cipher=ECDHE-RSA-RC4-SHA bits=128/128); Sun, 26 Oct 2014 22:49:18 -0700 (PDT) Received-SPF: pass (google.com: domain of patch+caf_=patchwork-forward=linaro.org@linaro.org designates 209.85.215.49 as permitted sender) client-ip=209.85.215.49; Received: by mail-la0-f49.google.com with SMTP id ge10so4287lab.22 for ; Sun, 26 Oct 2014 22:49:18 -0700 (PDT) X-Received: by 10.152.5.38 with SMTP id p6mr20829740lap.44.1414388958296; Sun, 26 Oct 2014 22:49:18 -0700 (PDT) X-Forwarded-To: patchwork-forward@linaro.org X-Forwarded-For: patch@linaro.org patchwork-forward@linaro.org Delivered-To: patch@linaro.org Received: by 10.112.84.229 with SMTP id c5csp235807lbz; Sun, 26 Oct 2014 22:49:17 -0700 (PDT) X-Received: by 10.68.202.1 with SMTP id ke1mr2836824pbc.60.1414388956685; Sun, 26 Oct 2014 22:49:16 -0700 (PDT) Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id fr3si9709441pbd.34.2014.10.26.22.49.16 for ; Sun, 26 Oct 2014 22:49:16 -0700 (PDT) Received-SPF: none (google.com: linux-kernel-owner@vger.kernel.org does not designate permitted sender hosts) client-ip=209.132.180.67; Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1752164AbaJ0Fra (ORCPT + 26 others); Mon, 27 Oct 2014 01:47:30 -0400 Received: from mail-pd0-f169.google.com ([209.85.192.169]:40578 "EHLO mail-pd0-f169.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752006AbaJ0Fr1 (ORCPT ); Mon, 27 Oct 2014 01:47:27 -0400 Received: by mail-pd0-f169.google.com with SMTP id y10so639481pdj.28 for ; Sun, 26 Oct 2014 22:47:27 -0700 (PDT) X-Received: by 10.67.11.42 with SMTP id ef10mr6901800pad.49.1414388847069; Sun, 26 Oct 2014 22:47:27 -0700 (PDT) Received: from wangdeqiang.com ([210.21.227.66]) by mx.google.com with ESMTPSA id jq5sm9723922pbc.32.2014.10.26.22.47.23 for (version=TLSv1.1 cipher=ECDHE-RSA-RC4-SHA bits=128/128); Sun, 26 Oct 2014 22:47:26 -0700 (PDT) From: "pang.xunlei" To: linux-kernel@vger.kernel.org, rtc-linux@googlegroups.com Cc: John Stultz , Thomas Gleixner , Alessandro Zummo , "pang.xunlei" Subject: [PATCH RFC 06/12] time: Fix build warnings for time64_t to __kernel_time_t warning on 64-bit systems. Date: Mon, 27 Oct 2014 13:46:36 +0800 Message-Id: <1414388802-5866-5-git-send-email-pang.xunlei@linaro.org> X-Mailer: git-send-email 1.7.9.5 In-Reply-To: <1414388802-5866-1-git-send-email-pang.xunlei@linaro.org> References: <1414388802-5866-1-git-send-email-pang.xunlei@linaro.org> Sender: linux-kernel-owner@vger.kernel.org Precedence: list List-ID: X-Mailing-List: linux-kernel@vger.kernel.org X-Removed-Original-Auth: Dkim didn't pass. X-Original-Sender: pang.xunlei@linaro.org X-Original-Authentication-Results: mx.google.com; spf=pass (google.com: domain of patch+caf_=patchwork-forward=linaro.org@linaro.org designates 209.85.215.49 as permitted sender) smtp.mail=patch+caf_=patchwork-forward=linaro.org@linaro.org Mailing-list: list patchwork-forward@linaro.org; contact patchwork-forward+owners@linaro.org X-Google-Group-Id: 836684582541 List-Post: , List-Help: , List-Archive: List-Unsubscribe: , The kernel uses 32-bit signed value(time_t) for seconds since 1970-01-01:00:00:00, so it will overflow at 2038-01-19 03:14:08 on 32-bit systems. We call this "2038 safety" issue. This patch fixed the build warnings brought by former patches. Signed-off-by: pang.xunlei --- include/linux/time64.h | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/include/linux/time64.h b/include/linux/time64.h index a383147..02f2c87 100644 --- a/include/linux/time64.h +++ b/include/linux/time64.h @@ -3,15 +3,15 @@ #include -typedef __s64 time64_t; - /* * This wants to go into uapi/linux/time.h once we agreed about the * userspace interfaces. */ #if __BITS_PER_LONG == 64 -# define timespec64 timespec +typedef __kernel_time_t time64_t; +#define timespec64 timespec #else +typedef __s64 time64_t; struct timespec64 { time64_t tv_sec; /* seconds */ long tv_nsec; /* nanoseconds */