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]
Message-ID: <AANLkTin2WjO4aRbB+x01YxDjKSHF1oc2sJi==f+C7c_s@mail.gmail.com>
Date:	Fri, 14 Jan 2011 16:23:56 +0100
From:	Kay Sievers <kay.sievers@...y.org>
To:	Karel Zak <kzak@...hat.com>
Cc:	Tejun Heo <tj@...nel.org>, Milan Broz <mbroz@...hat.com>,
	device-mapper development <dm-devel@...hat.com>,
	"Jun'ichi Nomura" <j-nomura@...jp.nec.com>,
	Valdis.Kletnieks@...edu, linux-kernel@...r.kernel.org,
	linux-raid@...r.kernel.org,
	Alexander Viro <viro@...iv.linux.org.uk>,
	linux-fsdevel@...r.kernel.org
Subject: Re: [dm-devel] linux-next - WARNING: at fs/block_dev.c:824 bd_link_disk_holder+0x92/0x1ac()

On Fri, Jan 14, 2011 at 16:07, Karel Zak <kzak@...hat.com> wrote:
> On Thu, Jan 13, 2011 at 05:10:02PM +0100, Kay Sievers wrote:
>> On Thu, Jan 13, 2011 at 16:59, Karel Zak <kzak@...hat.com> wrote:
>> > On Thu, Jan 13, 2011 at 03:43:38PM +0100, Kay Sievers wrote:
>> >> On Thu, Jan 13, 2011 at 15:30, Tejun Heo <tj@...nel.org> wrote:
>> >> > On Thu, Jan 13, 2011 at 3:25 PM, Milan Broz <mbroz@...hat.com> wrote:
>> >> >> Maybe, but this was not invented in DM/MD camp:-)
>> >> >> Probably Kay or Greg can answer why it was done this way?
>> >>
>> >> It's not from Greg or Kay. It just appeared some day in the context of dm. :)
>> >>
>> >> And yes, symlinks *look* nice and simple for the outside, but they are
>> >> not, and have all sorts of problems like non-atomic updates, make it
>> >
>> >  Sounds like sysfs implementation problem, right?
>>
>> It's a normal multi-file problem. It can by-definition not be atomic
>> without doing really weird locking things.
>
>  BTW, lsblk(8) and libblkid don't depend on the fact that slaves/holders
>  files are symlinks.
>
>  The important thing is the filename (/sys/block/.../slaves/<name>)
>  only. We don't follow the symlinks and we don't use readlink() there.
>
>  It means that you can replace the symlinks with regular files where
>  in the file contents is for example maj:min, etc.

I don't think we really can change anything here, there are more users of it.

If we would go changing things here, the file names should never be
the device name but the format "b8:32" for blockdevs, "n22" for the
network ifindex, ... which is the unchangeable unique kernel id -- not
depending on any possible device rename, or fast destroy/re-create or
anything like that.

Kay
--
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