lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Date:	Wed, 03 Sep 2008 11:11:29 -0700
From:	"H. Peter Anvin" <hpa@...or.com>
To:	Tejun Heo <tj@...nel.org>
CC:	device@...ana.org,
	Linux Kernel Mailing List <linux-kernel@...r.kernel.org>,
	Jens Axboe <jens.axboe@...cle.com>
Subject: Re: regarding major number of block extended devt

Tejun Heo wrote:
> H. Peter Anvin wrote:
>> Tejun Heo wrote:
>>> To use ext devt, the system has to use udev for device numbers.  As long
>>> as udev is used, the major number doesn't matter.
>> I'm sorry, but that's simply false.  There is a *lot* of code out there
>> that assumes you can determine what the device is by correlating the
>> major number with /proc/devices.
> 
> Then, we're between the rock and hard place then as there also is a
> lot of code which assumes certain layout of sd or hd minor numbers.
> Keeping only the major numbers doesn't really resolve any problem.  It
> may be able to mask a few but that can be more harmful than helpful.
> 

Thinking about it some more, one invariant this is *guaranteed* to 
violate is:

	partition_number = partition_device - master_device

Code that needs a partition number (which is common enough) are using 
this invariant, because (a) it has held for 17 years and (b) because 
there is still no alternative other that relying on fragile naming 
scheme hacks.

(a) we can't do anything about, but (b) we can, by introducing a 
partition number attribute in sysfs.

I would consider this a precondition for this.

	-hpa
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ