From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mail-lf1-f47.google.com ([209.85.167.47]:35761 "EHLO mail-lf1-f47.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726125AbeLKUU0 (ORCPT ); Tue, 11 Dec 2018 15:20:26 -0500 Received: by mail-lf1-f47.google.com with SMTP id e26so11770378lfc.2 for ; Tue, 11 Dec 2018 12:20:25 -0800 (PST) MIME-Version: 1.0 In-Reply-To: References: <20181210042842.GA16286@draconx.ca> <20181210143345.GB8356@bfoster> <20181210161121.GC8356@bfoster> <20181210165020.GT24487@magnolia> <20181210174627.GD8356@bfoster> <20181210214115.GC6311@dastard> <20181211122701.GA2819@bfoster> From: Nick Bowler Date: Tue, 11 Dec 2018 15:20:23 -0500 Message-ID: Subject: Re: Enlarging w/ xfs_growfs: XFS_IOC_FSGROWFSDATA xfsctl failed: Inappropriate ioctl for device Content-Type: text/plain; charset="UTF-8" Sender: linux-xfs-owner@vger.kernel.org List-ID: List-Id: xfs To: Brian Foster Cc: Dave Chinner , "Darrick J. Wong" , linux-xfs@vger.kernel.org On 12/11/18, Nick Bowler wrote: > On 12/11/18, Brian Foster wrote: >> Given that the structure size essentially changes the command value, I'm >> kind of curious why we have this ifdeffery in the first place. That >> aside, the patch seems reasonable to me at a glance (though some brief >> comments around the ifdefs would be nice). [...] > Current code has the ifdeffery. Also since it's a syntax error to have > multiple case labels with the same value it'd be essential to validate > that all supported architectures architectures end up with different > values for each XFS_IOC_xyz and the corresponding XFS_IOC_xyz_32. Right after I write this, I realize that it's almost certainly the case that architectures which _don't_ define BROKEN_X86_ALIGNMENT will have matching ioctl numbers between e.g., XFS_IOC_ALLOCSP and XFS_IOC_ALLOCSP_32. Thus the ifdeffery is essential for the above syntactic reason. Cheers, Nick