From patchwork Fri Feb 12 09:36:05 2016 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Deepa Dinamani X-Patchwork-Id: 8289361 Return-Path: X-Original-To: patchwork-linux-fsdevel@patchwork.kernel.org Delivered-To: patchwork-parsemail@patchwork1.web.kernel.org Received: from mail.kernel.org (mail.kernel.org [198.145.29.136]) by patchwork1.web.kernel.org (Postfix) with ESMTP id 3890D9FBE9 for ; Fri, 12 Feb 2016 09:37:36 +0000 (UTC) Received: from mail.kernel.org (localhost [127.0.0.1]) by mail.kernel.org (Postfix) with ESMTP id 5A330203B5 for ; Fri, 12 Feb 2016 09:37:35 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.kernel.org (Postfix) with ESMTP id 696A5203B7 for ; Fri, 12 Feb 2016 09:37:34 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1752022AbcBLJh1 (ORCPT ); Fri, 12 Feb 2016 04:37:27 -0500 Received: from mail-pa0-f45.google.com ([209.85.220.45]:35293 "EHLO mail-pa0-f45.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751974AbcBLJhV (ORCPT ); Fri, 12 Feb 2016 04:37:21 -0500 Received: by mail-pa0-f45.google.com with SMTP id ho8so44436154pac.2; Fri, 12 Feb 2016 01:37:21 -0800 (PST) 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=tgykEhZiwSB4VN+F/w+eA7KGKa2W2zlt9guyQCLHa34=; b=tvidmXxiH2w780J4nz48U57DMVK6I04Z0Qi0y1VL3U688oCTEMLENk2w5PGIYKRPke Y/5okThzazL9Ao6JOC7FcfOj7Pr6Kc984zWeymBAYK3BTAdQCqAY01RD/Embu7xvuwzk BiR8qeZ0Qgs/WPe9E9KIKTpvWJq2qXhzs/Yp+8qtbARWpm7Tr4PgzD+6T4zAEy6/pnA7 POxzXmJOQ6WVZzz1Kz3EmIhMdDVvb/GzqP/4++DXivy/xnwPwHedn5gp8HVlj4p64plx 3gkCeWf2/R7bR4OxYNKupX49NA4wuKfadvac5LFxR1ejo2NyAyOBiVCeghgeQBmCOMkQ awSA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references; bh=tgykEhZiwSB4VN+F/w+eA7KGKa2W2zlt9guyQCLHa34=; b=HHTO4NIkZq4TT2qOPau2cwpRuBZGvm13pm3qf+dbTGG+PsgFwJhiEDuWG7WFgEml4N v/PAJDcW0zBXrZRblFZh0H3/V5BFCNhOsgkVd5RK/SFiMRHo8DkQ98N1nM7SyAOiiEUR I1znabOAhCVjWjrnVq7+IfxtQTGepGcNIu+URhkMfijRSreKdcHYENeUDKevSdV62SIB tqHWgzOuygVxfeBYZ1//Htc602LMUImo5by/1yDeTK0yMs1iLGqW9iscyC0aceDj1Yjx 3Jl6EjBwaJTKk3gpP8WjHxPGo0NDQRLpFRGPJJrX7FQolXxszrvoEDdbrwmr9ujAf0Py 1qbg== X-Gm-Message-State: AG10YOQW/tFWMkC/7omnzJGA+Xe/FzKgNXrXVQ3k8X2ytkYBu5EkHtiSyd6bmgyTA1pPjg== X-Received: by 10.66.100.163 with SMTP id ez3mr660318pab.27.1455269841258; Fri, 12 Feb 2016 01:37:21 -0800 (PST) Received: from localhost.localdomain ([106.51.31.162]) by smtp.gmail.com with ESMTPSA id g25sm17972250pfg.35.2016.02.12.01.37.18 (version=TLS1_2 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Fri, 12 Feb 2016 01:37:20 -0800 (PST) From: Deepa Dinamani To: linux-fsdevel@vger.kernel.org, y2038@lists.linaro.org Cc: Arnd Bergmann , Dave Chinner , "Theodore Ts'o" , linux-kernel@vger.kernel.org Subject: [RFC v2a 11/12] net: ceph: use vfs_time data type instead of timespec Date: Fri, 12 Feb 2016 01:36:05 -0800 Message-Id: <1455269766-2994-12-git-send-email-deepa.kernel@gmail.com> X-Mailer: git-send-email 1.9.1 In-Reply-To: <1455269766-2994-1-git-send-email-deepa.kernel@gmail.com> References: <20160212092153.GA2368@deepa-ubuntu> <1455269766-2994-1-git-send-email-deepa.kernel@gmail.com> Sender: linux-fsdevel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-fsdevel@vger.kernel.org X-Spam-Status: No, score=-6.9 required=5.0 tests=BAYES_00, DKIM_ADSP_CUSTOM_MED, DKIM_SIGNED, FREEMAIL_FROM, RCVD_IN_DNSWL_HI, RP_MATCHES_RCVD, T_DKIM_INVALID, UNPARSEABLE_RELAY autolearn=ham version=3.3.1 X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on mail.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP The VFS inode timestamps are not y2038 safe as they use struct timespec. These will be changed to use struct timespec64 instead and that is y2038 safe. But, since the above data type conversion will break the end file systems, use vfs_time aliases here to access inode times. These timestamps are passed in as arguments to functions using inode timestamps. Hence, these need to change along with vfs to support 64 bit timestamps. vfs_time helps do this transition. Signed-off-by: Deepa Dinamani --- include/linux/ceph/messenger.h | 1 + include/linux/ceph/osd_client.h | 4 ++-- net/ceph/osd_client.c | 2 +- 3 files changed, 4 insertions(+), 3 deletions(-) diff --git a/include/linux/ceph/messenger.h b/include/linux/ceph/messenger.h index afe886b..28bba12 100644 --- a/include/linux/ceph/messenger.h +++ b/include/linux/ceph/messenger.h @@ -8,6 +8,7 @@ #include #include #include +#include #include #include diff --git a/include/linux/ceph/osd_client.h b/include/linux/ceph/osd_client.h index 7506b48..2b6f08b 100644 --- a/include/linux/ceph/osd_client.h +++ b/include/linux/ceph/osd_client.h @@ -322,7 +322,7 @@ extern struct ceph_osd_request *ceph_osdc_alloc_request(struct ceph_osd_client * extern void ceph_osdc_build_request(struct ceph_osd_request *req, u64 off, struct ceph_snap_context *snapc, u64 snap_id, - struct timespec *mtime); + struct vfs_time *mtime); extern struct ceph_osd_request *ceph_osdc_new_request(struct ceph_osd_client *, struct ceph_file_layout *layout, @@ -364,7 +364,7 @@ extern int ceph_osdc_writepages(struct ceph_osd_client *osdc, struct ceph_snap_context *sc, u64 off, u64 len, u32 truncate_seq, u64 truncate_size, - struct timespec *mtime, + struct vfs_time *mtime, struct page **pages, int nr_pages); /* watch/notify events */ diff --git a/net/ceph/osd_client.c b/net/ceph/osd_client.c index f8f2359..1273db6 100644 --- a/net/ceph/osd_client.c +++ b/net/ceph/osd_client.c @@ -2401,7 +2401,7 @@ bad: */ void ceph_osdc_build_request(struct ceph_osd_request *req, u64 off, struct ceph_snap_context *snapc, u64 snap_id, - struct timespec *mtime) + struct vfs_time *mtime) { struct ceph_msg *msg = req->r_request; void *p;