@@ -401,6 +401,7 @@ ifeq ($(do_tools),true)
if [ "$(arch)" = "amd64" ] || [ "$(arch)" = "i386" ]; then \
cd $(builddir)/tools/tools/power/x86/x86_energy_perf_policy && make CROSS_COMPILE=$(CROSS_COMPILE); \
cd $(builddir)/tools/tools/power/x86/turbostat && make CROSS_COMPILE=$(CROSS_COMPILE); \
+ cd $(builddir)/tools/tools/hv && make CROSS_COMPILE=$(CROSS_COMPILE) CFLAGS=-I../../include; \
fi
endif
@touch $@
@@ -417,6 +418,9 @@ ifeq ($(do_tools),true)
$(toolspkgdir)/usr/bin/x86_energy_perf_policy_$(abi_release); \
install -s -m755 $(builddir)/tools/tools/power/x86/turbostat/turbostat \
$(toolspkgdir)/usr/bin/turbostat_$(abi_release); \
+ install -d $(toolspkgdir)/usr/sbin; \
+ install -s -m755 $(builddir)/tools/tools/hv/hv_kvp_daemon \
+ $(toolspkgdir)/usr/sbin/hv_kvp_daemon_$(abi_release); \
fi
endif
@@ -81,6 +81,7 @@ endif
install-tools: toolspkg = $(tools_common_pkg_name)
install-tools: toolsbin = $(CURDIR)/debian/$(toolspkg)/usr/bin
+install-tools: toolssbin = $(CURDIR)/debian/$(toolspkg)/usr/sbin
install-tools: toolsman = $(CURDIR)/debian/$(toolspkg)/usr/share/man
install-tools: install-source
ifeq ($(do_tools),true)
@@ -95,6 +96,8 @@ ifeq ($(do_tools),true)
if [ "$(arch)" = "amd64" ] || [ "$(arch)" = "i386" ]; then \
install -m755 debian/tools/x86_energy_perf_policy $(toolsbin)/x86_energy_perf_policy; \
install -m755 debian/tools/turbostat $(toolsbin)/turbostat; \
+ install -d $(toolssbin) ; \
+ install -m755 debian/tools/generic $(toolssbin)/hv_kvp_daemon; \
fi
rm -rf $(builddir)/tools
@@ -110,6 +113,7 @@ ifeq ($(do_tools),true)
install -d $(toolsman)/man8; \
install -m644 $(CURDIR)/tools/power/x86/x86_energy_perf_policy/*.8 $(toolsman)/man8; \
install -m644 $(CURDIR)/tools/power/x86/turbostat/*.8 $(toolsman)/man8; \
+ install -m644 $(CURDIR)/tools/hv/*.8 $(toolsman)/man8; \
fi
endif
new file mode 100644
@@ -0,0 +1,16 @@
+#!/bin/bash
+full_version=`uname -r`
+
+# Removing flavour from version i.e. generic or server.
+flavour_abi=${full_version#*-}
+flavour=${flavour_abi#*-}
+version=${full_version%-$flavour}
+this="$0_$version"
+
+if [ ! -f "$this" ]; then
+ echo "$this not found" >&2
+ echo "You may need to install linux-tools-$version" >&2
+ exit 2
+fi
+
+exec "$this" "$@"
Add the Hyper-V KVP userspace daemon to the kernel tools package. Signed-off-by: Andy Whitcroft <apw@canonical.com> --- debian/rules.d/2-binary-arch.mk | 4 ++++ debian/rules.d/3-binary-indep.mk | 4 ++++ debian/tools/generic | 16 ++++++++++++++++ 3 files changed, 24 insertions(+), 0 deletions(-) create mode 100644 debian/tools/generic