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: <AANLkTi=7z40CNBUmfVUEa68J+1R=7nbn9d8vM7ETpajA@mail.gmail.com>
Date:	Thu, 18 Nov 2010 14:53:35 -0800
From:	Yehuda Sadeh Weinraub <yehuda@...newdream.net>
To:	Greg KH <greg@...ah.com>
Cc:	sage@...dream.net, ceph-devel@...r.kernel.org,
	linux-kernel@...r.kernel.org
Subject: Re: [PATCH] rbd: replace the rbd sysfs interface

On Wed, Nov 17, 2010 at 5:30 PM, Greg KH <greg@...ah.com> wrote:
> On Wed, Nov 17, 2010 at 03:00:17PM -0800, Yehuda Sadeh Weinraub wrote:
>> On Wed, Nov 17, 2010 at 9:19 AM, Greg KH <greg@...ah.com> wrote:
>> > On Tue, Nov 16, 2010 at 04:32:09PM -0800, Yehuda Sadeh wrote:
>> >> Hi Greg,
>> >>
>> >> Following is the new rbd sysfs interface. It lists devices in their own
>> >> subdirectories, as well as their underlying snapshots. Please let us
>> >> know if there's any issue you think we missed or did wrong.
>> >>
>> >> Thanks,
>> >> Yehuda
>> >>
>> >> ---
>> >>
>> >> The new interface creates directories per mapped image
>> >> and under each it creates a subdir per available snapshot.
>> >> This allows keeping a cleaner interface within the sysfs
>> >> guidelines. The ABI documentation was updated too.
>> >>
>> >> Signed-off-by: Yehuda Sadeh <yehuda@...newdream.net>
>> >> ---
>> >> ?Documentation/ABI/testing/sysfs-class-rbd | ? 83 +++
>> >> ?drivers/block/rbd.c ? ? ? ? ? ? ? ? ? ? ? | ?775 +++++++++++++++++------------
>> >> ?2 files changed, 547 insertions(+), 311 deletions(-)
>> >>
>> >> diff --git a/Documentation/ABI/testing/sysfs-class-rbd b/Documentation/ABI/testing/sysfs-class-rbd
>> >> new file mode 100644
>> >> index 0000000..4d96618
>> >> --- /dev/null
>> >> +++ b/Documentation/ABI/testing/sysfs-class-rbd
>> >> @@ -0,0 +1,83 @@
>> >> +What: ? ? ? ? ? ? ? ?/sys/class/rbd/
>> >
>> > I thought I mentioned that you should not add new classes to the kernel.
>> > Please don't do that, make it a bus_type instead.
>>
>>
>> Ahmm.. apparently not in the rbd related threads. So moving things
>> around and having rbd under /sys/bus we'll have the following:
>>
>> /sys/bus/rbd/drivers/rbd/..
>>     add - add a device
>>     remove - remove a device
>
> These files could go in /sys/bus/rbd/ directly instead of burying under
> 2 more layers, right?
>
>>
>> /sys/bus/rbd/devices/<id>
>>    name
>>    pool
>>    ...
>>
>> /sys/bus/rbd/devices/<id>/snaps/<name>
>>     id
>>     size
>>     ...
>>
>>
>> Would this work?
>
> With the change mentioned above, I think that seems sane, do you?
>

Yes, pretty much. One problem that I do see is that if we define the
snaps/ as a device (and not just as a kobj) as you suggested before,
it'll automatically create a 'uevent' entry under it which can be a
real issue in the case we have a snapshot named like that. Shouldn't
we just create it as a kobj in that case?

Thanks,
Yehuda
--
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