All of lore.kernel.org
 help / color / mirror / Atom feed
From: "H. Peter Anvin" <hpa@zytor.com>
To: linux-kernel@vger.kernel.org
Subject: Re: 32bit dev_t
Date: 3 Feb 2003 10:21:19 -0800	[thread overview]
Message-ID: <b1mbuv$fkf$1@cesium.transmeta.com> (raw)
In-Reply-To: UTC200301242204.h0OM4jU09451.aeb@smtp.cwi.nl

Followup to:  <UTC200301242204.h0OM4jU09451.aeb@smtp.cwi.nl>
By author:    Andries.Brouwer@cwi.nl
In newsgroup: linux.dev.kernel
> 
> The main point to decide would be the external dev_t format.
> Of course the format must be compatible with existing filesystems
> and binaries. For example,
> 
> #define MAJOR(dev)      ((unsigned int)(((dev) & 0xffff0000) \
> 	? ((dev) >> 16) & 0xffff : ((dev) >> 8) & 0xff))
> #define MINOR(dev)      ((unsigned int)(((dev) & 0xffff0000) \
> 	? ((dev) & 0xffff) : ((dev) & 0xff)))
> #define MKDEV(ma,mi)    ((dev_t)((((ma) & ~0xff) == 0 && ((mi) & ~0xff) == 0) \
> 	? (((ma) << 8) | (mi)) : (((ma) << 16) | (mi))))
> 
> This is 1-1 on nonzero majors (and zero major, 8-bit minor).
> 

I thought we had already decided:

	12 bits major : 20 bits minor

The zero major is used for dev_t compatibility, of course.

I personally still prefer 32:32, but I got voted down.

	-hpa
-- 
<hpa@transmeta.com> at work, <hpa@zytor.com> in private!
"Unix gives you enough rope to shoot yourself in the foot."
Architectures needed: cris ia64 m68k mips64 ppc ppc64 s390 s390x sh v850 x86-64

  parent reply	other threads:[~2003-02-03 18:12 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2003-01-24 22:04 32bit dev_t Andries.Brouwer
2003-01-25  1:51 ` Joel Becker
2003-02-03 18:21 ` H. Peter Anvin [this message]
  -- strict thread matches above, loose matches on Subject: below --
2003-01-21 19:50 Joel Becker
2003-01-21 21:29 ` Steven Dake
2003-01-21 21:56   ` Joel Becker
2003-01-21 22:21     ` Jeff Garzik
2003-01-21 22:33   ` Alan

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to='b1mbuv$fkf$1@cesium.transmeta.com' \
    --to=hpa@zytor.com \
    --cc=linux-kernel@vger.kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.