aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorAndre Przywara <andre.przywara@arm.com>2022-05-24 16:06:09 +0100
committerWill Deacon <will@kernel.org>2022-05-26 10:02:43 +0100
commit393e2187cf68a14e107f9fa75b1da4f5632b379b (patch)
tree17e972b0bd46fa6b300842bbc18093590184cb8f
parent7e2209945bb59e62c116cca6c371e9c3a4b99460 (diff)
downloadkvmtool-393e2187cf68a14e107f9fa75b1da4f5632b379b.tar.gz
util: include virtio UAPI headers in sync
We already have an update_headers.sh sync script, where we occasionally update the KVM interface UAPI kernel headers into our tree. So far this covered only the generic kvm.h, plus each architecture's version of that file. Commit bc77bf49df6e ("stat: Add descriptions for new virtio_balloon stat types") used newer virtio symbols, which some older distros do not include in their kernel headers package. To help fixing this and to avoid similar problems in the future, add the virtio headers to our sync script, so that we can get the same, up-to-date versions of the headers easily. Signed-off-by: Andre Przywara <andre.przywara@arm.com> Link: https://lore.kernel.org/r/20220524150611.523910-3-andre.przywara@arm.com Signed-off-by: Will Deacon <will@kernel.org>
-rwxr-xr-xutil/update_headers.sh10
1 files changed, 10 insertions, 0 deletions
diff --git a/util/update_headers.sh b/util/update_headers.sh
index 5f9cd32d..789e2a42 100755
--- a/util/update_headers.sh
+++ b/util/update_headers.sh
@@ -9,6 +9,11 @@
set -ue
+VIRTIO_LIST="virtio_9p.h virtio_balloon.h virtio_blk.h virtio_config.h \
+ virtio_console.h virtio_ids.h virtio_mmio.h virtio_net.h \
+ virtio_pci.h virtio_ring.h virtio_rng.h virtio_scsi.h \
+ virtio_vsock.h"
+
if [ "$#" -ge 1 ]
then
LINUX_ROOT="$1"
@@ -25,6 +30,11 @@ fi
cp -- "$LINUX_ROOT/include/uapi/linux/kvm.h" include/linux
+for header in $VIRTIO_LIST
+do
+ cp -- "$LINUX_ROOT/include/uapi/linux/$header" include/linux
+done
+
unset KVMTOOL_PATH
copy_optional_arch () {