creating link /dev/root to device / is mounted from
PATCH 1/1 creating link /dev/root to device / is mounted from
Hi there!
Some software (like hal) needs the /dev/root link (as /proc/mounts can contain it).
The attached patch contains one program which compares the major/minor number supplied to it on the command-line with the numbers of the device / is located on.
It is used with this rule (see 60-root_link.rules):
SUBSYSTEM=="block", PROGRAM=="blockdev_is_root $major $minor", SYMLINK+="root"
The patch also adds the rule to the gentoo rules file.
Matthias
Signature · 1 line
Matthias Schwarzott (zzam)
etc/udev/gentoo/50-udev.rules +3 -0
@@ -36,6 +36,9 @@ KERNEL=="ircomm*", NAME="%k", GROUP="uucp", MODE="0660" # all block devices SUBSYSTEM=="block", GROUP="disk" +# create link /dev/root to the blockdevice / is mounted from +SUBSYSTEM=="block", PROGRAM=="blockdev_is_root $major $minor", SYMLINK+="root" + # cdrom symlinks and other good cdrom naming KERNEL=="sr[0-9]*|hd[a-z]|pcd[0-9]*", ACTION=="add", IMPORT{program}="cdrom_id --export $tempnode" ENV{ID_CDROM}=="?*", GROUP="cdrom"
extras/root_link/60-root_link.rules new file +3 -0
@@ -0,0 +1,3 @@ +# create link /dev/root to the blockdevice / is mounted from + +SUBSYSTEM=="block", PROGRAM=="blockdev_is_root $major $minor", SYMLINK+="root"
extras/root_link/Makefile new file +69 -0
69 lines not on this page · raw message
extras/root_link/blockdev_is_root.c new file +73 -0
73 lines not on this page · raw message
-------------------------------------------------------------------------
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/
_______________________________________________
Linux-hotplug-devel mailing list http://linux-hotplug.sourceforge.net
[email protected]
https://lists.sourceforge.net/lists/listinfo/linux-hotplug-devel
Quoted 2 lines · Matthias Schwarzott
Some software (like hal) needs the
/dev/rootlink (as/proc/mountscan contain it).
Right, but HAL doesn't need it, it just assumes that device-file entries in /proc/mounts are also available in /dev.
The "/dev/root missing but in /proc/mounts" only happens for people who run their own compiled kernels without an initramfs.
Quoted 5 lines
The attached patch contains one program which compares the major/minor number supplied to it on the command-line with the numbers of the device / is located on.
It is used with this rule (see 60-root_link.rules):
SUBSYSTEM="block", PROGRAM="blockdev_is_root $major $minor", SYMLINK+="root"
Why do we want to run a program for _every_ block device, just to create /dev/root? It's an operation you only need to do once at bootup, and the root-device is obviously already there, before you start udev out of the rootfs. :)
The udev init-script checks if /dev is already mounted with tmpfs from initramfs, if not, it will need to do it, and at that point, we can just mknod /dev/root, can't we?
Kay
-------------------------------------------------------------------------
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/
_______________________________________________
Linux-hotplug-devel mailing list http://linux-hotplug.sourceforge.net
[email protected]
https://lists.sourceforge.net/lists/listinfo/linux-hotplug-devel
Quoted 17 lines · Kay Sievers
Quoted 2 lines · Matthias Schwarzott
Some software (like hal) needs the
/dev/rootlink (as/proc/mountscan contain it).Right, but HAL doesn't need it, it just assumes that device-file entries in
/proc/mountsare also available in /dev.The "
/dev/rootmissing but in/proc/mounts" only happens for people who run their own compiled kernels without an initramfs.Quoted 6 lines
The attached patch contains one program which compares the major/minor number supplied to it on the command-line with the numbers of the device / is located on.
It is used with this rule (see 60-root_link.rules):
SUBSYSTEM="block", PROGRAM="blockdev_is_root $major $minor", SYMLINK+="root"
Quoted 5 lines
Why do we want to run a program for _every_ block device, just to create
/dev/root? It's an operation you only need to do once at bootup, and the root-device is obviously already there, before you start udev out of the rootfs. :)
I think this is not too bad, as the program itself is only around 3k size.
Quoted 3 lines
The udev init-script checks if /dev is already mounted with tmpfs from initramfs, if not, it will need to do it, and at that point, we can just mknod
/dev/root, can't we?
Well, our initramfs does not move its /dev to new mounted root filesystem, but we get a completely fresh tmpfs.
We also can just have a program to write out major/minor of "/" and then mknod it (outside of udev)
But I really like a link better.
Here I also can search udev-database (or whatever)
For example when /usr is already mounted (for udevinfo):
dev_nr=$(root_get_dev_nr)
dev_path=$(udevtrigger --verbose --attr-match�v=${dev_nr}) dev_name=$(udevinfo -q name --path ${dev_path}) ln -s /dev/${dev_name} /dev/root
Or inject some rule into udev like
ATTR{dev}="${dev_nr}", SYMLINK+="root"
But how to inject? /etc is read-only at udevd starting. Or can rule-files include other rule files? Like in /dev/.udev/
Matthias
Signature · 11 lines
Matthias Schwarzott (zzam) ------------------------------------------------------------------------- This SF.net email is sponsored by DB2 Express Download DB2 Express C - the FREE version of DB2 express and take control of your XML. No limits. Just data. Click to get it now. http://sourceforge.net/powerbar/db2/ _______________________________________________ Linux-hotplug-devel mailing list http://linux-hotplug.sourceforge.net [email protected] https://lists.sourceforge.net/lists/listinfo/linux-hotplug-devel
Quoted 23 lines · Matthias Schwarzott
Quoted 17 lines · Kay Sievers
Quoted 2 lines · Matthias Schwarzott
Some software (like hal) needs the
/dev/rootlink (as/proc/mountscan contain it).Right, but HAL doesn't need it, it just assumes that device-file entries in
/proc/mountsare also available in /dev.The "
/dev/rootmissing but in/proc/mounts" only happens for people who run their own compiled kernels without an initramfs.Quoted 6 lines
The attached patch contains one program which compares the major/minor number supplied to it on the command-line with the numbers of the device / is located on.
It is used with this rule (see 60-root_link.rules):
SUBSYSTEM=="block", PROGRAM=="blockdev_is_root $major $minor", SYMLINK+="root"Quoted 4 lines
Why do we want to run a program for _every_ block device, just to create
/dev/root? It's an operation you only need to do once at bootup, and the root-device is obviously already there, before you start udev out of the rootfs. :)
Quoted 9 lines
I think this is not too bad, as the program itself is only around 3k size.
Quoted 3 lines
The udev init-script checks if /dev is already mounted with tmpfs from initramfs, if not, it will need to do it, and at that point, we can just mknod
/dev/root, can't we?Well, our initramfs does not move its /dev to new mounted root filesystem, but we get a completely fresh tmpfs.
I believe, most iplementations do. Actually how you solve the issue with /dev/null & Co. without it?
Quoted 5 lines
We also can just have a program to write out major/minor of "/" and then mknod it (outside of udev)
But I really like a link better.
Here I also can search udev-database (or whatever)
Yes that is nice. What about a simple program that can manupulate udev database? I am not sure if the format allows it though.
-andrey
Quoted 7 lines
For example when /usr is already mounted (for udevinfo):
dev_nr=$(root_get_dev_nr)
dev_path=$(udevtrigger --verbose --attr-match=dev=${dev_nr}) dev_name=$(udevinfo -q name --path ${dev_path})
ln -s/dev/${dev_name}/dev/root
Quoted 6 lines
Or inject some rule into udev like
ATTR{dev}=="${dev_nr}", SYMLINK+="root"
But how to inject? /etc is read-only at udevd starting. Or can rule-files include other rule files? Like in/dev/.udev/Matthias
-------------------------------------------------------------------------
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/
_______________________________________________
Linux-hotplug-devel mailing list http://linux-hotplug.sourceforge.net
[email protected]
https://lists.sourceforge.net/lists/listinfo/linux-hotplug-devel
Quoted 18 lines · Matthias Schwarzott
Quoted 17 lines · Kay Sievers
Quoted 2 lines · Matthias Schwarzott
Some software (like hal) needs the
/dev/rootlink (as/proc/mountscan contain it).Right, but HAL doesn't need it, it just assumes that device-file entries in
/proc/mountsare also available in /dev.The "
/dev/rootmissing but in/proc/mounts" only happens for people who run their own compiled kernels without an initramfs.Quoted 6 lines
The attached patch contains one program which compares the major/minor number supplied to it on the command-line with the numbers of the device / is located on.
It is used with this rule (see 60-root_link.rules):
SUBSYSTEM="block", PROGRAM="blockdev_is_root $major $minor", SYMLINK+="root"
Quoted 6 lines
Quoted 5 lines
Why do we want to run a program for _every_ block device, just to create
/dev/root? It's an operation you only need to do once at bootup, and the root-device is obviously already there, before you start udev out of the rootfs. :)I think this is not too bad, as the program itself is only around 3k size.
Sure, but it's just not really needed, when all you need to do is to run something like this _once_ at bootup:
if [ ! -e /dev/root ]; then
rootcpio=`echo / | /bin/cpio --quiet -o -H newc`
major=0x${rootcpio:62:8}
minor=0x${rootcpio:70:8}
if [ $((major)) -ne 0 ] ; then
/bin/mknod -m640 /dev/root b $major $minor
fi
fiQuoted 5 lines
Quoted 3 lines
The udev init-script checks if /dev is already mounted with tmpfs from initramfs, if not, it will need to do it, and at that point, we can just mknod
/dev/root, can't we?Well, our initramfs
Hmm, the issue should only occur _without_ an initramfs-image, right? It's a different code path in the kernel, that should not happen when initramfs code mounts /, then /proc/mounts has matching entries.
Quoted 2 lines
does not move its /dev to new mounted root filesystem,but we get a completely fresh tmpfs.
Sure, we all just mount an empty tmpfs without any moving of nodes. The thing is, the kernel does not create /dev/root in /dev of the root on disk, it's in the kernel's initramfs, which every kernel has, even when you don't use an cpio-image to pupulate it during bootup.
Quoted 10 lines
We also can just have a program to write out major/minor of "/" and then mknod it (outside of udev)
But I really like a link better.
Here I also can search udev-database (or whatever)For example when /usr is already mounted (for udevinfo):
dev_nr=$(root_get_dev_nr)
dev_path=$(udevtrigger --verbose --attr-matchÞv=${dev_nr}) dev_name=$(udevinfo -q name --path ${dev_path}) ln -s/dev/${dev_name}/dev/root
Yeah, sure, a link looks a bit nicer, but I'm not sure that it's worth all this effort.
Btw, how is your system doing an fsck on the rootfs? What device node is it using?
Kay
-------------------------------------------------------------------------
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/
_______________________________________________
Linux-hotplug-devel mailing list http://linux-hotplug.sourceforge.net
[email protected]
https://lists.sourceforge.net/lists/listinfo/linux-hotplug-devel
Quoted 9 lines · Kay Sievers
Quoted 3 lines · Matthias Schwarzott
On Freitag, 20. April 2007, Kay Sievers wrote:
Well, our initramfs
Hmm, the issue should only occur _without_ an initramfs-image, right? It's a different code path in the kernel, that should not happen when initramfs code mounts /, then
/proc/mountshas matching entries.
Quoted 7 lines
Quoted 2 lines
does not move its /dev to new mounted root filesystem,but we get a completely fresh tmpfs.
Sure, we all just mount an empty tmpfs without any moving of nodes. The thing is, the kernel does not create
/dev/rootin /dev of the root on disk, it's in the kernel's initramfs, which every kernel has, even when you don't use an cpio-image to pupulate it during bootup.
Yeah - but I meant some initramfs images do mount a tmpfs - and /dev/root on it, and later move that mounted fs onto the its final position.
Quoted 6 lines
Quoted 6 lines
We also can just have a program to write out major/minor of "/" and then mknod it (outside of udev)
But I really like a link better.
Here I also can search udev-database (or whatever)
Quoted 9 lines
Quoted 5 lines
For example when /usr is already mounted (for udevinfo):
dev_nr=$(root_get_dev_nr)
dev_path=$(udevtrigger --verbose --attr-matchÞv=${dev_nr}) dev_name=$(udevinfo -q name --path ${dev_path}) ln -s/dev/${dev_name}/dev/rootYeah, sure, a link looks a bit nicer, but I'm not sure that it's worth all this effort.
Depends :)
Only thing that I dislike on this solution is that it needs udevinfo that is in /usr/bin, make it impossible to do it right after udev has been started, but in another init-script.
Quoted 2 lines
Btw, how is your system doing an fsck on the rootfs? What device node is it using?
It just uses the device node listed in fstab :)
Yeah, that is the other possibility - if fstab has a entry for "/" just create a symlink there. (But here it can differ from the real used device.)
Matthias
Signature · 11 lines
Matthias Schwarzott (zzam) ------------------------------------------------------------------------- This SF.net email is sponsored by DB2 Express Download DB2 Express C - the FREE version of DB2 express and take control of your XML. No limits. Just data. Click to get it now. http://sourceforge.net/powerbar/db2/ _______________________________________________ Linux-hotplug-devel mailing list http://linux-hotplug.sourceforge.net [email protected] https://lists.sourceforge.net/lists/listinfo/linux-hotplug-devel
I honestly feel that this is a kernel issue. Since according to the mount man page, /proc/mounts and /etc/mtab should be relatively in sync and /etc/mtab can technically be a symlink of /proc/mounts. It states that /proc/mounts should update quicker and as such should technically be more reliable. Which I feel contradicts some people's opinions that the kernel and /proc/mounts can not be trusted. I think this is bogus because with an initramfs, the kernel does the right thing. Without one, it hardcodes itself to /dev/root when the kernel knows via the root= option what the proper dev node should be.
As a result, here's a kernel patch to correct this issue.
Signature · 2 lines
Doug Goldstein <[email protected]> http://dev.gentoo.org/~cardoe/
init/do_mounts.c +11 -3
@@ -354,7 +354,10 @@va_start (args, fmt);vsprintf (buf, fmt, args);va_end (args); - fd =sys_open ("/dev/root" ,O_RDWR |O_NDELAY ,0 ); +if (saved_root_name[0 ]) + fd =sys_open (saved_root_name,O_RDWR |O_NDELAY ,0 ); +else + fd =sys_open ("/dev/root" ,O_RDWR |O_NDELAY ,0 );if (fd >=0 ) {sys_ioctl (fd,FDEJECT ,0 );sys_close (fd);
@@ -397,8 +400,13 @@ }#endif #ifdef CONFIG_BLOCK -create_dev ("/dev/root" ,ROOT_DEV ); -mount_block_root ("/dev/root" , root_mountflags); +if (saved_root_name[0 ]) { +create_dev (saved_root_name,ROOT_DEV ); +mount_block_root (saved_root_name, root_mountflags); + }else { +create_dev ("/dev/root" ,ROOT_DEV ); +mount_block_root ("/dev/root" , root_mountflags); + }#endif }
-------------------------------------------------------------------------
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/
_______________________________________________
Linux-hotplug-devel mailing list http://linux-hotplug.sourceforge.net
[email protected]
https://lists.sourceforge.net/lists/listinfo/linux-hotplug-devel
Quoted 10 lines · Doug Goldstein
I honestly feel that this is a kernel issue. Since according to the
mount man page,/proc/mountsand/etc/mtabshould be relatively in sync
and/etc/mtabcan technically be a symlink of/proc/mounts. It states
that/proc/mountsshould update quicker and as such should technically
be more reliable. Which I feel contradicts some people's opinions that
the kernel and/proc/mountscan not be trusted. I think this is bogus
because with an initramfs, the kernel does the right thing. Without one,
it hardcodes itself to/dev/rootwhen the kernel knows via the root> option what the proper dev node should be.As a result, here's a kernel patch to correct this issue.
Right, that solves the most common case, but you can also pass:
root=8:5
as the major/minor which will not exist in the real root, just like /dev/root doesn't exist. It's very likely, but there is still no guarantee, that the device node will exist in the real root.
We are running in circles here. It's kind of ugly, sure, that the kernel uses a name, that doesn't exist in /dev, but it's still only a name, and in the past nothing required it to be an existing device-name.
HAL makes the assumption that the names are existing devices-names, which is kind of optimistic. Earlier versions of HAL just ignored the name and used to stat() the mount-point which is theoretically the better approach, but that broke the stupid autofs-like setups, so it got changed to use the name again.
But we may just want to change HAL to handle mnt_dir = "/" as a special case, instead of assuming the name to be a device-node. That should solve the real problem we are seeing here.
We could also just check once at bootup, that the name for the root-mount in /proc/mounts exists in /dev, and if not, just mknod an entry with that name.
That would work with _all_ possible names that have been used to mount the rootfs and don't exist later (simple example pasted at the end of this mail).
I prefer changing HAL, or just create the node as a workaround - as the kernel change will not be able to catch all use cases.
Thanks,
Kay
while read fsname dir type opts; do
case "$dir" in
/)
case "$fsname" in
/dev/*)
if [ ! -e "$fsname" ]; then
rootcpio=$(echo / | cpio --quiet -o -H newc)
major=0x${rootcpio:62:8}
minor=0x${rootcpio:70:8}
if [ $((major)) -ne 0 ] ; then
mknod -m640 $fsname b $major $minor
fi
fi
break;
;;
esac
break
;; esac
done < /proc/mounts
-------------------------------------------------------------------------
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/
_______________________________________________
Linux-hotplug-devel mailing list http://linux-hotplug.sourceforge.net
[email protected]
https://lists.sourceforge.net/lists/listinfo/linux-hotplug-devel
Quoted 3 lines · Kay Sievers
But we may just want to change HAL to handle
mnt_dir= "/" as a special case, instead of assuming the name to be a device-node. That should solve the real problem we are seeing here.
I'm fine taking a patch to do that. Thanks!
David
-------------------------------------------------------------------------
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/
_______________________________________________
Linux-hotplug-devel mailing list http://linux-hotplug.sourceforge.net
[email protected]
https://lists.sourceforge.net/lists/listinfo/linux-hotplug-devel
Quoted 6 lines · David Zeuthen
Quoted 3 lines · Kay Sievers
But we may just want to change HAL to handle
mnt_dir== "/" as a special case, instead of assuming the name to be a device-node. That should solve the real problem we are seeing here.I'm fine taking a patch to do that. Thanks!
Does this work for you Doug?
Thanks,
Kay
hald/linux/blockdev.c +49 -40
@@ -165,9 +165,6 @@ blockdev_refresh_mount_state (HalDevicestruct mntent mnt;struct mntent *mnte;char buf[1024 ]; -unsigned int major; -unsigned int minor; -dev_t devt =makedev (0 ,0 );GSList *volumes =NULL ;GSList *volume;
@@ -189,43 +186,53 @@ blockdev_refresh_mount_state (HalDevice/* loop over /proc/mounts */ while ((mnte =getmntent_r (f, &mnt, buf,sizeof (buf))) !=NULL ) {struct stat statbuf; -gboolean use_device_name_for_match; +dev_t devt; -/*HAL_INFO ((" * /proc/mounts contain dev %s - type %s", mnt.mnt_fsname, mnt.mnt_type));*/ +/* HAL_INFO ((" * /proc/mounts contain dev %s - type %s", mnt.mnt_fsname, mnt.mnt_type)); */ -/* If this is a nfs mount (fstype == 'nfs') ignore the mount. Reason: -* 1. we don't list nfs devices in HAL -* 2. more problematic: stat on mountpoints with 'stale nfs handle' never come -* back and block complete HAL and all applications using HAL fail. +/* We don't handle nfs mounts in HAL and stat() on mountpoints, +* and we would block on 'stale nfs handle'. */ if (strcmp (mnt.mnt_type,"nfs" ) ==0 )continue ; - use_device_name_for_match = FALSE; -/* get major:minor of special device file */ -if (stat (mnt.mnt_fsname, &statbuf) !=0 ) { -/* DING DING DING... device node may have been deleted by udev -* but device is still mounted and we haven't processed the uevent -* for that deletion from udev.. -* -* So in this case... fall back to comparing on device names -* rather than pretending the device is not mounted as that's -* what will happen if we just skip this /proc/mounts entry. -* -* The reason it's nicer to compare on major:minor is that -* /proc/mounts is broken - it contains the *device name* -* passed to mount(2) which in some cases may be a symlink -* (on many distros it's common to see /proc/mounts contain -* /dev/root as the device for /). Sigh... -*/ - use_device_name_for_match = TRUE; - }else { +/* skip plain names, we look for device nodes */ +if (mnt.mnt_fsname[0 ] !='/' ) +continue ; + +/* +* We can't just stat() the mountpoint, because it breaks all sorts +* non-disk filesystems. So assume, that the names in /proc/mounts +* are existing device-files used to mount the filesystem. +*/ + devt =makedev (0 ,0 ); +if (stat (mnt.mnt_fsname, &statbuf) ==0 ) { +/* not a device node */ if (major (statbuf.st_rdev) ==0 )continue ; + +/* found major/minor */ + devt = statbuf.st_rdev; + }else { +/* The root filesystem may be mounted by a device name that doesn't +* exist in the real root, like /dev/root, which the kernel uses +* internally, when no initramfs image is used. For "/", it is safe +* to get the major/minor by stat()'ing the mount-point. +*/ +if (strcmp (mnt.mnt_dir,"/" ) ==0 &&stat ("/" , &statbuf) ==0 ) + devt = statbuf.st_dev; + +/* DING DING DING... the device-node may not exist, or is +* already deleted, but the device may be still mounted. +* +* We will fall back to looking up the device-name, instead +* of using major/minor. +*/ } -/*HAL_INFO (("* found mounts dev %s (%i:%i)", mnt.mnt_fsname, major (statbuf.st_rdev), minor (statbuf.st_rdev)));*/ -/* match against all hal volumes */ +/* HAL_INFO (("* found mounts dev %s (%i:%i)", mnt.mnt_fsname, +major (devt), minor (devt))); */ +for (volume = volumes; volume !=NULL ; volume =g_slist_next (volume)) {HalDevice *dev;gboolean is_match;
@@ -233,7 +240,8 @@ blockdev_refresh_mount_state (HalDevice is_match = FALSE; dev =HAL_DEVICE (volume->data); -if (use_device_name_for_match) { +/* lookup dev_t or devname of known hal devices */ +if (major (devt) ==0 ) {const char *device_name; device_name =hal_device_property_get_string (dev,"block.device" );
@@ -243,14 +251,16 @@ blockdev_refresh_mount_state (HalDeviceif (strcmp (device_name, mnt.mnt_fsname) ==0 ) is_match = TRUE; }else { - major =hal_device_property_get_int (dev,"block.major" ); -if (major ==0 ) +unsigned int majornum; +unsigned int minornum; + + majornum =hal_device_property_get_int (dev,"block.major" ); +if (majornum ==0 )continue ; - minor =hal_device_property_get_int (dev,"block.minor" ); - devt =makedev (major, minor); -/*HAL_INFO ((" match %s (%i:%i)", hal_device_get_udi (dev), major, minor));*/ + minornum =hal_device_property_get_int (dev,"block.minor" ); +/* HAL_INFO ((" match %s (%i:%i)", hal_device_get_udi (dev), majornum, minornum)); */ -if (statbuf.st_rdev == devt) +if (majornum ==major (devt) && minornum ==minor (devt)) is_match = TRUE; }
@@ -262,9 +272,8 @@ blockdev_refresh_mount_state (HalDevice hasmntopt (&mnt, MNTOPT_RO) ? TRUE : FALSE);hal_device_property_set_string (dev,"volume.mount_point" , mnt.mnt_dir);device_property_atomic_update_end (); -/*HAL_INFO ((" set %s to be mounted at %s (%s)", -hal_device_get_udi (dev), mnt.mnt_dir, -hasmntopt (&mnt, MNTOPT_RO) ? "ro" : "rw"));*/ +/* HAL_INFO ((" set %s to be mounted at %s (%s)", hal_device_get_udi (dev), +mnt.mnt_dir, hasmntopt (&mnt, MNTOPT_RO) ? "ro" : "rw")); */ volumes =g_slist_delete_link (volumes, volume);break ; }
-------------------------------------------------------------------------
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/
_______________________________________________
Linux-hotplug-devel mailing list http://linux-hotplug.sourceforge.net
[email protected]
https://lists.sourceforge.net/lists/listinfo/linux-hotplug-devel
Quoted 9 lines · Kay Sievers
Quoted 6 lines · David Zeuthen
Quoted 3 lines · Kay Sievers
But we may just want to change HAL to handle
mnt_dir= "/" as a special case, instead of assuming the name to be a device-node. That should solve the real problem we are seeing here.I'm fine taking a patch to do that. Thanks!
Does this work for you Doug?
Doug told me on IRC this worked and it looks good to me. Committed, thanks Kay!
David
-------------------------------------------------------------------------
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/
_______________________________________________
Linux-hotplug-devel mailing list http://linux-hotplug.sourceforge.net
[email protected]
https://lists.sourceforge.net/lists/listinfo/linux-hotplug-devel