[arch-general] [PATCH] automatically mount debugfs
Here is a patch for rc.sysinit to automatically mount the kernel's debugfs, if available. (I switched from Gentoo to Arch two days ago and first sent this message to arch-dev-public which turned out to be read-only. Maybe a hint on the mailman page would be nice, to spare future newbies the same experience?) --- rc.sysinit_old 2009-10-14 20:08:56.776237753 +0200 +++ rc.sysinit 2009-10-14 20:40:28.227216838 +0200 @@ -19,6 +19,13 @@ /bin/mount -n -t proc none /proc /bin/mount -n -t sysfs none /sys +# mount debugfs, if available +if [ -d /sys/kernel/debug ]; then + if grep -qs debugfs /proc/filesystems; then + mount -n -t debugfs -o nodev,noexec,nosuid debugfs /sys/kernel/debug + fi +fi + # Copy static device nodes to /dev /bin/cp -a /lib/udev/devices/* /dev/ @@ -288,7 +295,7 @@ /bin/mount -o remount,rw / # Write /proc, /sys and /dev to /etc/mtab if [ -e /proc/mounts ]; then - /bin/grep -e "/proc " -e "/sys " -e "/dev " /proc/mounts >> /etc/mtab + /bin/grep -e "/proc " -e "/sys " -e "/dev " -e "debugfs" /proc/mounts >> /etc/mtab fi # now mount all the local filesystems /bin/mount -a -t $NETFS -O no_netdev -- Markus
On Thu, Oct 15, 2009 at 6:31 PM, Markus Trippelsdorf <markus@trippelsdorf.de> wrote:
Here is a patch for rc.sysinit to automatically mount the kernel's debugfs, if available.
That sounds cool, I like this feature. Is there any reason for not doing that ? And all the main distro do it too ? Btw the common procedure is to fill a feature request on bugs.archlinux.org
On Thu, Oct 15, 2009 at 12:33 PM, Xavier <shiningxc@gmail.com> wrote:
On Thu, Oct 15, 2009 at 6:31 PM, Markus Trippelsdorf <markus@trippelsdorf.de> wrote:
Here is a patch for rc.sysinit to automatically mount the kernel's debugfs, if available.
That sounds cool, I like this feature. Is there any reason for not doing that ? And all the main distro do it too ?
Btw the common procedure is to fill a feature request on bugs.archlinux.org
I like it too. I have it marked to apply at some point when I get around to doing a patch run :)
participants (3)
-
Aaron Griffin
-
Markus Trippelsdorf
-
Xavier