From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S932445AbbCDBrf (ORCPT ); Tue, 3 Mar 2015 20:47:35 -0500 Received: from zeniv.linux.org.uk ([195.92.253.2]:58462 "EHLO ZenIV.linux.org.uk" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S932150AbbCDBre (ORCPT ); Tue, 3 Mar 2015 20:47:34 -0500 Date: Wed, 4 Mar 2015 01:47:32 +0000 From: Al Viro To: Gwendal Grignou Cc: Daniel Ehrenberg , linux-fsdevel@vger.kernel.org, Linux Kernel , Gwendal Grignou , Ezequiel Garcia Subject: Re: [RFC PATCH] vfs: Use 12:20 bit major:minor in stat everywhere Message-ID: <20150304014731.GW29656@ZenIV.linux.org.uk> References: <1425429420-13142-1-git-send-email-dehrenberg@chromium.org> <20150304005347.GU29656@ZenIV.linux.org.uk> <20150304012211.GV29656@ZenIV.linux.org.uk> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: User-Agent: Mutt/1.5.21 (2010-09-15) Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Tue, Mar 03, 2015 at 05:37:31PM -0800, Gwendal Grignou wrote: > At least, to base the device format on whether we are running on a 32 > bit or 64 bit architecture does not make sense. Yes, it does. Note that on 32bit ones stat64(2) *will* return an arbitrary value. On 64bit ones stat(2) will. > If a tool calling stat(2) can not handle 12 bit major/20 bits minor, > it would already break or about to break when running on a 64 bit > machine. > > Regarding SCSI, the 17th disk will use SCSI_DISK1_MAJOR (65). Only the > 257th disk will use the first scsi major (8) again and need a minor > greater than 256. (see sd_major() in drivers/scsi/sd.c for details). *nod* It's been years since I last looked at sd.c, TBH... Said that, with NFS it's definitely a minor per superblock, and it's not the only set_anon_super() user. Having a bunch of filesystems mounted over NFS will suffice...