Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id ; Fri, 4 Jan 2002 16:15:34 -0500 Received: (majordomo@vger.kernel.org) by vger.kernel.org id ; Fri, 4 Jan 2002 16:15:25 -0500 Received: from neon-gw-l3.transmeta.com ([63.209.4.196]:52498 "EHLO neon-gw.transmeta.com") by vger.kernel.org with ESMTP id ; Fri, 4 Jan 2002 16:15:21 -0500 Date: Fri, 4 Jan 2002 13:14:47 -0800 (PST) From: Linus Torvalds To: Alexander Viro cc: , , , , Subject: Re: 2.5.2-pre7 still missing bits of kdev_t In-Reply-To: Message-ID: MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII Sender: linux-kernel-owner@vger.kernel.org X-Mailing-List: linux-kernel@vger.kernel.org On Fri, 4 Jan 2002, Alexander Viro wrote: > > Reasons: > a) foo_mknod() - why the hell would we take dev_t, pass it into > ->mknod() only to split it into major:minor there and immediately > rebuild dev_t from them? And that - for _all_ instances of ->mknod() No, if you make init_special_inode() take minor/major, then you have to make mknod do the same. At that point it becomes a ABI issue how the mknod _system_call_ argument is split up into major/minor, and the rest of the kernel wouldn't really care. However, looking more at this, we clearly need to have the same ABI for stat() as for mknod(), so it probably makes sense to just continue to have "dev_t is a standard mix of minor/major" numbers approach, and just continue passing "dev_t" around exactly as such a combination (and then let people do the proper MKNOD/MAJOR/MINOR macros on it). So you may be right - there are no real advantage from splitting the two, as long as dev_t and kdev_t cannot be mixed up by mistake (which is largely true already now). Linus - To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/