aboutsummaryrefslogtreecommitdiffstats
path: root/tools/hotplug/Linux/xen-hotplug-common.sh
diff options
context:
space:
mode:
Diffstat (limited to 'tools/hotplug/Linux/xen-hotplug-common.sh')
-rw-r--r--tools/hotplug/Linux/xen-hotplug-common.sh6
1 files changed, 6 insertions, 0 deletions
diff --git a/tools/hotplug/Linux/xen-hotplug-common.sh b/tools/hotplug/Linux/xen-hotplug-common.sh
index 8f6557df73..4a7bc7349f 100644
--- a/tools/hotplug/Linux/xen-hotplug-common.sh
+++ b/tools/hotplug/Linux/xen-hotplug-common.sh
@@ -15,6 +15,12 @@
# Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
#
+# Hack to prevent the execution of hotplug scripts from udev if the domain
+# has been launched from libxl
+if [ -n "${UDEV_CALL}" ] && \
+ xenstore-read "libxl/disable_udev" >/dev/null 2>&1; then
+ exit 0
+fi
dir=$(dirname "$0")
. "$dir/hotplugpath.sh"