Skip to contentSkip to conversation

Check for presence of hotplug

PATCH New Michael Vrable 1 participant 1 message Sep 23, 2005

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 Check for presence of hotplug

Here's a minor patch to check for the presence of hotplug, which is needed in domain-0 now for block devices to work.

(Hotplug is included with most distributions, but I've been using a fairly minimal domain-0, which didn't include hotplug.)

This script should be made executable, but I'm not sure this is reflected in the patch itself...

--Michael Vrable

# HG changeset patch
# User Michael Vrable <[email protected]> # Node ID 99c5c58064bf6c71372b00c4ce73cdbed9bbad40 # Parent 9f50bd7a478fc138578ac95b41f3d306d0f0af4a Add an install-time check for hotplug.

The hotplug subsystem is currently needed for block devices to work, as of changeset 6742:e9d01c5dc7b4d6b7cda9ade0d137ddb89bb204cc. Add a script to check for the presence of hotplug and warn if it isn't found.

tools/check/check_hotplug new file +10 -0
diff -r 9f50bd7a478f -r 99c5c58064bf tools/check/check_hotplug
@@ -0,0 +1,10 @@
+#!/bin/bash
+# CHECK-INSTALL
+
+function error {
+   echo
+   echo '  *** Check for the hotplug scripts (hotplug) FAILED'
+   exit 1
+}
+
+which hotplug 1>/dev/null 2>&1 || error