From: Jeremy Fitzhardinge <jeremy@goop.org>
To: Ian Jackson <Ian.Jackson@eu.citrix.com>
Cc: "xen-devel@lists.xensource.com" <xen-devel@lists.xensource.com>
Subject: [PATCH 2/2] Load gntdev and evtchn if they're modular.
Date: Fri, 19 Aug 2011 17:49:07 -0700 [thread overview]
Message-ID: <4E4F0483.8070007@goop.org> (raw)
Signed-off-by: Jeremy Fitzhardinge <jeremy.fitzhardinge@citrix.com>
diff -r cfb49fe940fd -r 81f75ed45ec2 tools/hotplug/Linux/init.d/xencommons
--- a/tools/hotplug/Linux/init.d/xencommons Tue Aug 16 16:56:16 2011 -0700
+++ b/tools/hotplug/Linux/init.d/xencommons Tue Aug 16 17:05:18 2011 -0700
@@ -29,12 +29,18 @@
XENCONSOLED_PIDFILE=/var/run/xenconsoled.pid
shopt -s extglob
-if [ "x$1" = xstart -a -d /proc/xen -a \
- ! -f /proc/xen/capabilities ] && \
- ! grep -qw '^xenfs' /proc/mounts; then
- mount -t xenfs xenfs /proc/xen
+[ -d /proc/xen ] || exit 0 # Xen not present; exit quietly
+
+if [ "x$1" = xstart ]; then
+ # Mount /proc/xen if needed
+ [ -f /proc/xen/capabilities ] || mount -t xenfs xenfs /proc/xen
+
+ # Make sure evtchn and gntdev are loaded if present
+ grep -q "xen/evtchn" /proc/misc || modprobe xen-evtchn
+ grep -q "xen/gntdev" /proc/misc || modprobe xen-gntdev
fi
+# Done here if this isn't a control domain
if ! grep -q "control_d" /proc/xen/capabilities ; then
exit 0
fi
next prev reply other threads:[~2011-08-20 0:49 UTC|newest]
Thread overview: 9+ messages / expand[flat|nested] mbox.gz Atom feed top
2011-08-12 7:11 [PATCH] hotplug: update xencommons script to run only when needed Olaf Hering
2011-08-25 15:15 ` Ian Jackson
2011-08-25 15:24 ` Olaf Hering
2011-08-25 15:34 ` Ian Jackson
2011-08-20 0:49 ` Jeremy Fitzhardinge [this message]
2011-08-26 9:10 ` [PATCH v2] " Olaf Hering
2011-08-30 16:46 ` [PATCH 2/2] Load gntdev and evtchn if they're modular. [and 1 more messages] Ian Jackson
2011-08-30 18:12 ` Olaf Hering
2011-08-31 16:02 ` Ian Jackson
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=4E4F0483.8070007@goop.org \
--to=jeremy@goop.org \
--cc=Ian.Jackson@eu.citrix.com \
--cc=xen-devel@lists.xensource.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.