Re: [PATCHSET 3/4] sysfs: divorce sysfs from kobject and driver model

Previous message: [thread] [date] [author]
Next message: [thread] [date] [author]
From: Eric W. Biederman
Date: Friday, October 5, 2007 - 5:12 am

Greg KH <greg@kroah.com> writes:

Hmm.  If that is in the LSB it must come from
Documentation/devices.txt  I'm not after changing the user
visible major/minor assignments.

Let me see if a concrete example will help.  Suppose I have
have a SAN with two disks:  disk-1 and disk-2.  I have
two machines A and B.  On machine A I get the mapping:
sda -> disk-1, sdb ->disk-2.  On machine B I wind up with
a different probe order so I get the mapping: sda -> disk-2
sdb ->disk-1.

To be very clear by sda I mean the block device with major 8 and
minor 0, and by sdb I mean the block device with major 8 and minor
16.

So I decide I want an environment on machine B that looks just
like the environment on machine A, so I can bring transfer over
a running program or whatever.  So I run around looking at UUID
labels and what not and I discover that the machine B knows disk-1 as
sdb and that machine A knows disk-1 as sda.  So I want to say:
/sys/devices/block/sdb show up in this other device namespace as
/sys/devices/block/sda.

In that instance a running program won't notice the difference.

Eric
-
Previous message: [thread] [date] [author]
Next message: [thread] [date] [author]

Messages in current thread:
[PATCH 05/22] sysfs: implement sysfs_find_child(), Tejun Heo, (Thu Sep 20, 1:05 am)
[PATCH 06/22] sysfs: restructure addrm helpers, Tejun Heo, (Thu Sep 20, 1:05 am)
[PATCH 01/22] sysfs: make sysfs_root a pointer, Tejun Heo, (Thu Sep 20, 1:05 am)
[PATCH 04/22] sysfs: make SYSFS_COPY_NAME a flag, Tejun Heo, (Thu Sep 20, 1:05 am)
[PATCH 14/22] sysfs: s/symlink/link/g, Tejun Heo, (Thu Sep 20, 1:05 am)
[PATCH 21/22] sysfs: kill sysfs_hash_and_remove(), Tejun Heo, (Thu Sep 20, 1:05 am)
Re: [PATCHSET 3/4] sysfs: divorce sysfs from kobject and d ..., Eric W. Biederman, (Thu Sep 27, 12:25 pm)
Re: [PATCHSET 3/4] sysfs: divorce sysfs from kobject and d ..., Eric W. Biederman, (Fri Oct 5, 5:12 am)
Re: [PATCHSET 3/4] sysfs: divorce sysfs from kobject and d ..., Eric W. Biederman, (Wed Oct 10, 6:16 am)
Re: [PATCHSET 3/4] sysfs: divorce sysfs from kobject and d ..., Eric W. Biederman, (Wed Oct 10, 2:16 pm)
Re: [PATCHSET 3/4] sysfs: divorce sysfs from kobject and d ..., Eric W. Biederman, (Tue Oct 16, 4:54 pm)