void-packages/srcpkgs/OpenRC/patches/init.sh_mount_xenfs_very_early.patch
Juan RP bc80789cb0 OpenRC: added a patch to mount xenfs very early for dom0.
--HG--
extra : convert_revision : a174b429866504b1f6967ae4dc372703f35621c0
2010-02-26 10:05:42 +01:00

17 lines
579 B
Diff

--- sh/init.sh.Linux.in.orig 2010-02-26 09:13:26.682795699 +0100
+++ sh/init.sh.Linux.in 2010-02-26 09:20:18.411807297 +0100
@@ -70,4 +70,14 @@ if $mountproc; then
eend $?
fi
+# Try to mount xenfs as early as possible, otherwise rc_sys() will always
+# return RC_SYS_XENU and will think that we are in a domU while it's not.
+if grep -Eq "[[:space:]]+xenfs$" /proc/filesystems; then
+ ebegin "Mounting xenfs"
+ if ! fstabinfo --mount /proc/xen; then
+ mount -n -t xenfs xenfs /proc/xen -o nosuid,nodev,noexec
+ fi
+ eend $?
+fi
+
. "$RC_LIBEXECDIR"/sh/init-common-post.sh