From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1751483AbdHaNKK (ORCPT ); Thu, 31 Aug 2017 09:10:10 -0400 Received: from mx1.redhat.com ([209.132.183.28]:59682 "EHLO mx1.redhat.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751127AbdHaNKI (ORCPT ); Thu, 31 Aug 2017 09:10:08 -0400 DMARC-Filter: OpenDMARC Filter v1.3.2 mx1.redhat.com 9F2D35F7AD Authentication-Results: ext-mx10.extmail.prod.ext.phx2.redhat.com; dmarc=none (p=none dis=none) header.from=redhat.com Authentication-Results: ext-mx10.extmail.prod.ext.phx2.redhat.com; spf=fail smtp.mailfrom=esyr@redhat.com Date: Thu, 31 Aug 2017 15:10:39 +0200 From: Eugene Syromiatnikov To: Arnd Bergmann Cc: Linux Media Mailing List , Linux Kernel Mailing List , y2038 Mailman List , Mauro Carvalho Chehab , Linux API , "moderated list:ARM/SAMSUNG EXYNOS ARM ARCHITECTURES" , "Dmitry V. Levin" , Gleb Fotengauer-Malinovskiy Subject: Re: [3/7,media] dvb: don't use 'time_t' in event ioctl Message-ID: <20170831131039.GO4037@asgard.redhat.com> References: <1442332148-488079-4-git-send-email-arnd@arndb.de> <20170828153243.GA27121@asgard.redhat.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: User-Agent: Mutt/1.5.23 (2014-03-12) X-Greylist: Sender IP whitelisted, not delayed by milter-greylist-4.5.16 (mx1.redhat.com [10.5.110.39]); Thu, 31 Aug 2017 13:10:08 +0000 (UTC) Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Wed, Aug 30, 2017 at 10:25:01PM +0200, Arnd Bergmann wrote: > >> diff --git a/include/uapi/linux/dvb/video.h b/include/uapi/linux/dvb/video.h > >> index d3d14a59d2d5..6c7f9298d7c2 100644 > >> --- a/include/uapi/linux/dvb/video.h > >> +++ b/include/uapi/linux/dvb/video.h > >> @@ -135,7 +135,8 @@ struct video_event { > >> #define VIDEO_EVENT_FRAME_RATE_CHANGED 2 > >> #define VIDEO_EVENT_DECODER_STOPPED 3 > >> #define VIDEO_EVENT_VSYNC 4 > >> - __kernel_time_t timestamp; > >> + /* unused, make sure to use atomic time for y2038 if it ever gets used */ > >> + long timestamp; > > > > This change breaks x32 ABI (and possibly MIPS n32 ABI), as __kernel_time_t > > there is 64 bit already: > > https://sourceforge.net/p/strace/mailman/message/36015326/ > > > > Note the change in structure size from 0x20 to 0x14 for VIDEO_GET_EVENT > > command in linux/x32/ioctls_inc0.h. > > Are you sure it worked before the change? I don't see any handler in the kernel > for the x32 compat ioctl call here, only the compat_video_event handling, so > my guess is that the change unintentionally fixes x32. Yes, you're right; unfortunately, I decided to check which ioctl handler x32 code is using only after sending the e-mail, and now in the process of preparing some RFC patch for the ioctl commands which have discrepancies between x32 and compat sizes. > > Arnd