Received: by 2002:ad5:474a:0:0:0:0:0 with SMTP id i10csp4570808imu; Tue, 29 Jan 2019 04:01:23 -0800 (PST) X-Google-Smtp-Source: ALg8bN7K7N9u/BiSVozOg03ZnV+PuZbkjQEYOm6VPdH4rMfTDujDA2Y5ItEHc1MJ6678wUxjQH77 X-Received: by 2002:a63:7c13:: with SMTP id x19mr22193674pgc.336.1548763283656; Tue, 29 Jan 2019 04:01:23 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1548763283; cv=none; d=google.com; s=arc-20160816; b=U5zqrKF0Dv6Be3CxHsoyY4vNHcDcdmjUPodt5Z0NpgOkGhRMKV8QaJO2vyAg8xm+ES eMfO45oznx4b5iq8LchYSDGrShLHCn48REbKFJcLaVLIz7YEoE2qGITKb6YpUmXD+DqI t8l2q6pjxtYe7uGu/jpIyfyCnJEOUM812YhDFjPpxVE8NqoG5kstMUjpLavzfTsHEfsA 9GEWfAYpESsYfVnymqEUPagdYSUBAB5pWol6aDI4g4dt/uwU+PgN+D+4tU7K0/fQGQaM punzoRd3NAYHF0+SoxekyYv8UMSQQL+dSnRt5wCrr8SApzHjOWMEJ/fzJMRlolpONp/a 9AJw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:content-transfer-encoding:mime-version :user-agent:references:in-reply-to:message-id:date:subject:cc:to :from:dkim-signature; bh=nBcH52Ch+l/Fb5lSbPgEFMuYdjKeat00qBf2GuWS1g0=; b=D9i1YNvAt99YxlNoiblsNQJLgdVRKwOuPliPHdPYvTCailwPyC1N7Cz4evMnDzJ0vF gAC5BADpVt51yiShEEsX4Cmo2tnUVzLQKl9MniWMBdXLImp8SpzgVy0qdtE6R9Yv9SyT 8wxAjvzbcPaIX+bSOaKTTazxcRARSiKQcgVgZiwAEwWZ9NER+FiZ42iZ36Ofv9jKa5Ak /eU8/iLpHFBoYOyvp9200A0kcwL5hfJAlNBH9dPNmXtun8oJT6xpnQE8sDpy9E2edHA0 +xR2SEEiN7cEevT3+2x1CEAHuZuG9tgklP1xgYfk/OFQTKLG8GOB0rE/szxiTESz4E90 Wq4Q== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@kernel.org header.s=default header.b="x0dK/9Xs"; 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 Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id h3si14947625pgc.354.2019.01.29.04.01.08; Tue, 29 Jan 2019 04:01:23 -0800 (PST) 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=@kernel.org header.s=default header.b="x0dK/9Xs"; 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 Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1730443AbfA2Lpu (ORCPT + 99 others); Tue, 29 Jan 2019 06:45:50 -0500 Received: from mail.kernel.org ([198.145.29.99]:36302 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1729523AbfA2Lpr (ORCPT ); Tue, 29 Jan 2019 06:45:47 -0500 Received: from localhost (5356596B.cm-6-7b.dynamic.ziggo.nl [83.86.89.107]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPSA id AFEF22083B; Tue, 29 Jan 2019 11:45:46 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=default; t=1548762347; bh=QgJD/T9lCWiyWoChVaStS+gbKGCQyMsC6biQZm/qqu0=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=x0dK/9XsRppiO5cpzqHUqOBGdJsiEGx4P8p6fu78s/yjsd+SxIg5WCkEeMrf5FMZL gm1mtQMMocTmNdXDUY7Y0aybyxSUuuhazF/Lepl7Pe5NIOeCwlZJcrua4kvCH4BX1L LQPEY+sN8IhTlJIrrVG512vQCN1QSvn8FUe6B6Iw= From: Greg Kroah-Hartman To: linux-kernel@vger.kernel.org Cc: Greg Kroah-Hartman , stable@vger.kernel.org, Arnd Bergmann , Deepa Dinamani , Dmitry Torokhov Subject: [PATCH 4.19 059/103] Input: input_event - provide override for sparc64 Date: Tue, 29 Jan 2019 12:35:36 +0100 Message-Id: <20190129113204.233323662@linuxfoundation.org> X-Mailer: git-send-email 2.20.1 In-Reply-To: <20190129113159.567154026@linuxfoundation.org> References: <20190129113159.567154026@linuxfoundation.org> User-Agent: quilt/0.65 X-stable: review X-Patchwork-Hint: ignore MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org 4.19-stable review patch. If anyone has any objections, please let me know. ------------------ From: Deepa Dinamani commit 2e746942ebacf1565caa72cf980745e5ce297c48 upstream. The usec part of the timeval is defined as __kernel_suseconds_t tv_usec; /* microseconds */ Arnd noticed that sparc64 is the only architecture that defines __kernel_suseconds_t as int rather than long. This breaks the current y2038 fix for kernel as we only access and define the timeval struct for non-kernel use cases. But, this was hidden by an another typo in the use of __KERNEL__ qualifier. Fix the typo, and provide an override for sparc64. Fixes: 152194fe9c3f ("Input: extend usable life of event timestamps to 2106 on 32 bit systems") Reported-by: Arnd Bergmann Signed-off-by: Deepa Dinamani Cc: stable@vger.kernel.org Signed-off-by: Dmitry Torokhov Signed-off-by: Greg Kroah-Hartman --- include/uapi/linux/input.h | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) --- a/include/uapi/linux/input.h +++ b/include/uapi/linux/input.h @@ -26,13 +26,17 @@ */ struct input_event { -#if (__BITS_PER_LONG != 32 || !defined(__USE_TIME_BITS64)) && !defined(__KERNEL) +#if (__BITS_PER_LONG != 32 || !defined(__USE_TIME_BITS64)) && !defined(__KERNEL__) struct timeval time; #define input_event_sec time.tv_sec #define input_event_usec time.tv_usec #else __kernel_ulong_t __sec; +#ifdef CONFIG_SPARC64 + unsigned int __usec; +#else __kernel_ulong_t __usec; +#endif #define input_event_sec __sec #define input_event_usec __usec #endif