From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from verein.lst.de ([213.95.11.211]:49914 "EHLO newverein.lst.de" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751175AbdKQSln (ORCPT ); Fri, 17 Nov 2017 13:41:43 -0500 Date: Fri, 17 Nov 2017 19:41:42 +0100 From: Christoph Hellwig To: Jeff Layton Cc: linux-fsdevel@vger.kernel.org, Vitaly Lipatov , hch@lst.de, bfields@fieldses.org, Alexander Viro , linux-kernel@vger.kernel.org Subject: Re: [PATCH v2] fcntl: don't cap l_start and l_end values for F_GETLK64 in compat syscall Message-ID: <20171117184142.GA28617@lst.de> References: <20171115180345.8219-1-jlayton@kernel.org> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20171115180345.8219-1-jlayton@kernel.org> Sender: linux-fsdevel-owner@vger.kernel.org List-ID: On Wed, Nov 15, 2017 at 01:03:45PM -0500, Jeff Layton wrote: > From: Jeff Layton > > Currently, we're capping the values too low in the F_GETLK64 case. The > fields in that structure are 64-bit values, so we shouldn't need to do > any sort of fixup there. > > Make sure we check that assumption at build time in the future however > by ensuring that the sizes we're copying will fit. > > With this, we no longer need COMPAT_OFF_T_MAX either, so remove it. Sounds like the COMPAT_LOFF_T_MAX should be a separate patch, but otherwise this looks good. Reviewed-by: Christoph Hellwig Btw, I seems like arm has another copy of the old broken compat code in arch/arm/kernel/sys_oabi-compat.c. I wonder if anyone with a vested interest in arm would be willing to clean that mess up.