From patchwork Fri Nov 10 15:37:15 2017 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Arnd Bergmann X-Patchwork-Id: 118576 Delivered-To: patch@linaro.org Received: by 10.140.22.164 with SMTP id 33csp8079524qgn; Fri, 10 Nov 2017 07:38:12 -0800 (PST) X-Google-Smtp-Source: AGs4zMbNKSL2HK2lpzTfGECNAYZJdF1Y/ylMOZIobT+NxDsz4vVIUIcheLWhSqkgDPLbn0Ild5Jv X-Received: by 10.84.247.129 with SMTP id o1mr758924pll.6.1510328292722; Fri, 10 Nov 2017 07:38:12 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1510328292; cv=none; d=google.com; s=arc-20160816; b=ccINRgL2EAZGN+pG3rx2UiaOVjUmhREfziSziE7ZDDy3BHPO2izLlk5CQhoiHalYSd +2oDPYJV/jQEuwz2TSFnYRQIP5DksDr3OrgQaCWfC6H5HW3JkAk3agufBni8junE5mzZ ywbuEVNwsZe1VvEfgqq4etWJZAg4lIqFN5GkUFGYGey3keYYnQspBr3rwIV/0UkyFcVx plRlRbYl8YjAXHZNClbg+ZGuA/u+0gZa/8neSt3FPDXQRaldsMjbnlavlR+qzVrMKQar jtYQJ6sLJ7C0ReaxIJe9eziXi6G6mVAOUO8lXFX8MavaLvo/LFPQiE1FW/CGjXW09imT 0pVg== 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:arc-authentication-results; bh=Re0qd7ZQDtieYFNJo7XvHTpSDLGdMSt6AJMZA8RhI98=; b=E0b4dkR9hfqF0YtQEKs6FpBSq1wvdnFJXuIqtrtwoxn7vrhl1lSg4yFgJ4dRIfgJI6 T1pA5vsMK1cUcCLU41zjzHOS17oYRIcst/Ij+h/iY0C+J2U/v77vt2J7dMnANZTcaiW3 vkjg+iTzkf9d/abI+OS031yvpPVDuW28pzN7WibYUR8ElB35y/JMWlIg4mJKR3pDes55 KHRtaiRBV1z7DXs9K3SAkxk4wd6V4b3nfM6hCs3M4Mhj1mC5ZLgoy3eqxeeeXMj8w8L0 rNoGIvOXg6i71nQGeXHcvYX1chmURUKVZtSr4AYc6uy96yqRilFN2u7mYZr49+WYS354 jG8A== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: best guess record for domain of linux-scsi-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-scsi-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id a91si9181285pld.674.2017.11.10.07.38.12; Fri, 10 Nov 2017 07:38:12 -0800 (PST) Received-SPF: pass (google.com: best guess record for domain of linux-scsi-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-scsi-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-scsi-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1752821AbdKJPiL (ORCPT + 1 other); Fri, 10 Nov 2017 10:38:11 -0500 Received: from mout.kundenserver.de ([212.227.17.13]:51544 "EHLO mout.kundenserver.de" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1753264AbdKJPhv (ORCPT ); Fri, 10 Nov 2017 10:37:51 -0500 Received: from wuerfel.lan ([109.193.157.232]) by mrelayeu.kundenserver.de (mreue104 [212.227.15.145]) with ESMTPA (Nemesis) id 0M8QKY-1f8jlc09FC-00vwmM; Fri, 10 Nov 2017 16:37:34 +0100 From: Arnd Bergmann To: Anil Gurumurthy , Sudarsana Kalluru , "James E . J . Bottomley" , "Martin K . Petersen" Cc: linux-scsi@vger.kernel.org, linux-kernel@vger.kernel.org, y2038@lists.linaro.org, hch@lst.de, hare@suse.com, jthumshirn@suse.de, Arnd Bergmann Subject: [PATCH 7/7] scsi: bfa: use 64-bit times in bfa_aen_entry_s ABI Date: Fri, 10 Nov 2017 16:37:15 +0100 Message-Id: <20171110153715.1929456-8-arnd@arndb.de> X-Mailer: git-send-email 2.9.0 In-Reply-To: <20171110153715.1929456-1-arnd@arndb.de> References: <20171110153715.1929456-1-arnd@arndb.de> X-Provags-ID: V03:K0:y+SzW9+7XYzR58gEMw3EDfLoXUuHu1v9blqTHr44JvbDrvyky4m tn6ZgUljHtAZnMgilMB+fzlyYERCEeCWS5/w1076QDWg+7ihatRXTIPMxniOs9yZC7LgJIv s/s9OUAKrCk6aglVC9RHYsRkcAwm3qTaeqrUoet84OnUEjG7UJ+ENELNR7xdRYjVjAumzdw FIaW3CAI09XzpiJifc/Hg== X-UI-Out-Filterresults: notjunk:1; V01:K0:43dHnS8Dfx8=:3r407n5V5vvHerm+iIF6Ne PV4ktmoFF4K/D5p+OIfkB/cn8pKK6ZlKrk1NcmOHorIvsVEQBBSwp+636q9WSC6V3Y09Zi8tM bOUPlW2mVJPq3I4SbJHmXFQyXpn2Nkf0LZCFV2o+MgpB7N3/KSjpTetY9zx4xP8Pnv0rzn6TS GeMy+EqaKZaEXQU0axCB2HgdtdSJJs2JS+4eexiPEdX4G8pRtkBRaPxnkjBnG8PQU0AEUw0p2 pDkv+FclWKAEP6P3ODYsXu4Cetd/ljUE7wWAAJk4Gw4jc5VGrxCJWcpy9zf1IpgsM9BSBO0Tp N5WHXVnJ37JRtdQ2yTnGllme5btTGe3sYgO5aFWZNEcvj0yzIM4p0nhtJP1fuzm3j7WlOks3C gci/2n4kQcEdDo2ENQEkkAhpEAtUAe9ibvWs90vlNbTE57ANOl795gX+kbRFeDEBti89yt1so N4buuzP6ga4zbAhkBioM55QEOlDW+0aG1CpnbuSO6KPflxFi6L2k389Q4ZbacPP+4v0iTZI7y CeRecQp0WBAIGbimgNmAksNm8Ec7azDSRPWqtKGoqTMmsDfgE+6K1tXvFczwI3IjGKa+Mmxb9 dEtInpLOsKUrmmNSDFhCkvwC1QxssaIR15Fb2ExRN1CJLrcDnhFtIWaTsPLOvnW/yo6eyCaI2 WHsjO3pdGL/7BubZURMu8eRtgv/DKpfOlSbstOJ3AQILqGXMhQjyPEMzrFNbUhpO+RPHdO8RM bwbg8g7pV04JxmJcpXBmjmvtHjnJQ3zqIfdWXw== Sender: linux-scsi-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-scsi@vger.kernel.org bfa_aen_entry_s is passed through a netlink socket that can be read by either 32-bit or 64-bit processes, but the data format is different between the two on current implementations. Originally, this was using a 'struct timeval', which also suffers from getting redefined with a new libc implementation. With this patch, the layout gets fixed to having two 64-bit members for the time, making it the same on 32-bit kernels and 64-bit kernels running either compat or native user space including x32. Provided that the new header file gets used to recompile any 32-bit application binaries, this will fix running those on a 64-bit kernel (with or without this patch) e.g. in a container environment, and it will make binaries work that will be built against a future 32-bit glibc that uses a 64-bit time_t, and avoid the y2038 overflow there. However, this also breaks compatibility with any existing 32-bit binary running on a native 32-bit kernel, those must be recompiled against the new header, which in turn makes them incompatible with older kernels unless the same change gets applied there. Obviously this patch should only be applied when the benefits outweigh the possible breakage. I'm posting it under the assumption that there are no open-source tools using the netlink interface, and that users of the binaries provided by qlogic for SLES10/11 and RHEL5/6 are not actually being used on new future systems with 32-bit x86 kernels. Signed-off-by: Arnd Bergmann --- --- drivers/scsi/bfa/bfa_defs_svc.h | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) -- 2.9.0 diff --git a/drivers/scsi/bfa/bfa_defs_svc.h b/drivers/scsi/bfa/bfa_defs_svc.h index df1e874015c4..3d0c96a5c873 100644 --- a/drivers/scsi/bfa/bfa_defs_svc.h +++ b/drivers/scsi/bfa/bfa_defs_svc.h @@ -1455,8 +1455,8 @@ struct bfa_aen_entry_s { enum bfa_aen_category aen_category; u32 aen_type; union bfa_aen_data_u aen_data; - unsigned long aen_tv_sec; - unsigned long aen_tv_usec; + u64 aen_tv_sec; + u64 aen_tv_usec; u32 seq_num; u32 bfad_num; };