[oe-commits] org.oe.dev udev: Auto-add the rootfs partition to mount.blacklist via postinst to work around a bug in the auto-mounter * * Untested in .dev! * *

coredump commit openembedded-commits at lists.openembedded.org
Tue Nov 7 23:08:30 UTC 2006


udev: Auto-add the rootfs partition to mount.blacklist via postinst to work around a bug in the auto-mounter * * Untested in .dev! * *

Author: coredump at openembedded.org
Branch: org.openembedded.dev
Revision: 66190b5f9155cf291b0a7158138e14ab4d333823
ViewMTN: http://monotone.openembedded.org/revision.psp?id=66190b5f9155cf291b0a7158138e14ab4d333823
Files:
1
packages/udev/files/mount.sh
packages/udev/udev_092.bb
packages/udev/udev_097.bb
packages/udev/udev_100.bb
Diffs:

#
# mt diff -r689ffd30aa7266e43c29afff222cd98ebb49eaa9 -r66190b5f9155cf291b0a7158138e14ab4d333823
#
# 
# 
# patch "packages/udev/files/mount.sh"
#  from [025e4d2beeef84251c52f6d4c2214f3b711c4d70]
#    to [e9881d2c39ea15422aeb552e6916c546745f8421]
# 
# patch "packages/udev/udev_092.bb"
#  from [c3fda850f9168474496bc1d274d076eba4ec7a68]
#    to [5c5b0b3f7c06488dd122ebfccb893ea9abad3498]
# 
# patch "packages/udev/udev_097.bb"
#  from [75d77ac86c74e5dc48551b3de0f15de8788d33e9]
#    to [0751a8a82dc912a52067c8286ae14e403f6ec543]
# 
# patch "packages/udev/udev_100.bb"
#  from [c2daa9b59d8cef2f7b828722c1d9615530776ae1]
#    to [a16a463ded3e1780465d4cd1f35285b24d77179e]
# 
============================================================
--- packages/udev/files/mount.sh	025e4d2beeef84251c52f6d4c2214f3b711c4d70
+++ packages/udev/files/mount.sh	e9881d2c39ea15422aeb552e6916c546745f8421
@@ -50,6 +50,11 @@ if [ "$ACTION" = "add" ] && [ -n "$DEVNA
 	fi
 	
 	# If the device isn't mounted at this point, it isn't configured in fstab
+	# 20061107: Small correction: The rootfs partition may be called just "rootfs" and not by
+	# 	    its true device name so this would break. If the rootfs is mounted on two places
+	#	    during boot, it confuses the heck out of fsck. So Im auto-adding the root-partition
+	#	    to /etc/udev/mount.blacklist via postinst 
+
 	cat /proc/mounts | awk '{print $1}' | grep -q "^$DEVNAME$" || automount 
 	
 fi
============================================================
--- packages/udev/udev_092.bb	c3fda850f9168474496bc1d274d076eba4ec7a68
+++ packages/udev/udev_092.bb	5c5b0b3f7c06488dd122ebfccb893ea9abad3498
@@ -1,9 +1,9 @@ RPROVIDES = "hotplug"
 DESCRIPTION = "udev is a daemon which dynamically creates and removes device nodes from \
 /dev/, handles hotplug events and loads drivers at boot time. It replaces \
 the hotplug package and requires a kernel not older than 2.6.12."
 RPROVIDES = "hotplug"
 
-PR = "r12"
+PR = "r13"
 
 SRC_URI = "http://kernel.org/pub/linux/utils/kernel/hotplug/udev-${PV}.tar.gz \
 	   file://noasmlinkage.patch;patch=1 \
@@ -57,3 +57,20 @@ do_install_append_h2200() {
 do_install_append_h2200() {
 	install -m 0644 ${WORKDIR}/50-hostap_cs.rules         ${D}${sysconfdir}/udev/rules.d/50-hostap_cs.rules
 }
+
+pkg_postinst_append() {
+	
+	# Add the root partition to mount.blacklist to avoid a bug in the auto-mounter,
+	# causing confusion with fsck on boot
+	
+        while read dev mp fs junk
+        do
+                if test "$mp" = "/"
+                then
+                        root_partition="$dev"
+                        echo "$root_partition" >> /etc/udev/mount.blacklist
+                fi
+        done < /etc/fstab
+	
+}
+
============================================================
--- packages/udev/udev_097.bb	75d77ac86c74e5dc48551b3de0f15de8788d33e9
+++ packages/udev/udev_097.bb	0751a8a82dc912a52067c8286ae14e403f6ec543
@@ -8,7 +8,7 @@ needed to link programs with libvolume_i
 DESCRIPTION_libvolume-id-dev = "libvolume_id development headers, \
 needed to link programs with libvolume_id."
 
-PR = "r3"
+PR = "r4"
 
 SRC_URI = "http://kernel.org/pub/linux/utils/kernel/hotplug/udev-${PV}.tar.gz \
 	   file://noasmlinkage.patch;patch=1 \
@@ -61,3 +61,21 @@ do_install_append_h2200() {
 do_install_append_h2200() {
 	install -m 0644 ${WORKDIR}/50-hostap_cs.rules         ${D}${sysconfdir}/udev/rules.d/50-hostap_cs.rules
 }
+
+pkg_postinst_append() {
+	
+	# Add the root partition to mount.blacklist to avoid a bug in the auto-mounter,
+	# causing confusion with fsck on boot
+	
+        while read dev mp fs junk
+        do
+                if test "$mp" = "/"
+                then
+                        root_partition="$dev"
+                        echo "$root_partition" >> /etc/udev/mount.blacklist
+                fi
+        done < /etc/fstab
+	
+}
+
+
============================================================
--- packages/udev/udev_100.bb	c2daa9b59d8cef2f7b828722c1d9615530776ae1
+++ packages/udev/udev_100.bb	a16a463ded3e1780465d4cd1f35285b24d77179e
@@ -9,7 +9,7 @@ needed to link programs with libvolume_i
 DESCRIPTION_libvolume-id-dev = "libvolume_id development headers, \
 needed to link programs with libvolume_id."
 
-PR = "r2"
+PR = "r3"
 
 SRC_URI = "http://kernel.org/pub/linux/utils/kernel/hotplug/udev-${PV}.tar.gz \
 	   file://noasmlinkage.patch;patch=1 \
@@ -62,3 +62,20 @@ do_install_append_h2200() {
 do_install_append_h2200() {
 	install -m 0644 ${WORKDIR}/50-hostap_cs.rules         ${D}${sysconfdir}/udev/rules.d/50-hostap_cs.rules
 }
+
+pkg_postinst_append() {
+	
+	# Add the root partition to mount.blacklist to avoid a bug in the auto-mounter,
+	# causing confusion with fsck on boot
+	
+        while read dev mp fs junk
+        do
+                if test "$mp" = "/"
+                then
+                        root_partition="$dev"
+                        echo "$root_partition" >> /etc/udev/mount.blacklist
+                fi
+        done < /etc/fstab
+	
+}
+






More information about the Openembedded-commits mailing list