summaryrefslogtreecommitdiff
path: root/tools/virtio
diff options
context:
space:
mode:
Diffstat (limited to 'tools/virtio')
-rw-r--r--tools/virtio/Makefile1
-rw-r--r--tools/virtio/asm/barrier.h1
-rw-r--r--tools/virtio/linux/bug.h1
-rw-r--r--tools/virtio/linux/compiler.h1
-rw-r--r--tools/virtio/linux/dma-mapping.h1
-rw-r--r--tools/virtio/linux/err.h1
-rw-r--r--tools/virtio/linux/kernel.h1
-rw-r--r--tools/virtio/linux/module.h1
-rw-r--r--tools/virtio/linux/scatterlist.h1
-rw-r--r--tools/virtio/linux/slab.h1
-rw-r--r--tools/virtio/linux/uaccess.h1
-rw-r--r--tools/virtio/linux/virtio.h1
-rw-r--r--tools/virtio/linux/virtio_byteorder.h1
-rw-r--r--tools/virtio/linux/virtio_config.h1
-rw-r--r--tools/virtio/ringtest/Makefile1
-rw-r--r--tools/virtio/ringtest/noring.c1
-rw-r--r--tools/virtio/ringtest/ptr_ring.c1
-rwxr-xr-xtools/virtio/ringtest/run-on-all.sh1
-rw-r--r--tools/virtio/uapi/linux/virtio_ring.h1
-rw-r--r--tools/virtio/virtio-trace/Makefile1
-rw-r--r--tools/virtio/virtio-trace/trace-agent.h1
-rw-r--r--tools/virtio/virtio_test.c1
-rw-r--r--tools/virtio/vringh_test.c1
23 files changed, 23 insertions, 0 deletions
diff --git a/tools/virtio/Makefile b/tools/virtio/Makefile
index 39c89a5ea990..8e2a908115c2 100644
--- a/tools/virtio/Makefile
+++ b/tools/virtio/Makefile
@@ -1,3 +1,4 @@
+# SPDX-License-Identifier: GPL-2.0
all: test mod
test: virtio_test vringh_test
virtio_test: virtio_ring.o virtio_test.o
diff --git a/tools/virtio/asm/barrier.h b/tools/virtio/asm/barrier.h
index ba34f9e96efd..0ac3caf90877 100644
--- a/tools/virtio/asm/barrier.h
+++ b/tools/virtio/asm/barrier.h
@@ -1,3 +1,4 @@
+/* SPDX-License-Identifier: GPL-2.0 */
#if defined(__i386__) || defined(__x86_64__)
#define barrier() asm volatile("" ::: "memory")
#define virt_mb() __sync_synchronize()
diff --git a/tools/virtio/linux/bug.h b/tools/virtio/linux/bug.h
index fb94f0787c47..b14c2c3b6b85 100644
--- a/tools/virtio/linux/bug.h
+++ b/tools/virtio/linux/bug.h
@@ -1,3 +1,4 @@
+/* SPDX-License-Identifier: GPL-2.0 */
#ifndef BUG_H
#define BUG_H
diff --git a/tools/virtio/linux/compiler.h b/tools/virtio/linux/compiler.h
index c9ccfd42ec13..903dc9c4bd11 100644
--- a/tools/virtio/linux/compiler.h
+++ b/tools/virtio/linux/compiler.h
@@ -1,3 +1,4 @@
+/* SPDX-License-Identifier: GPL-2.0 */
#ifndef LINUX_COMPILER_H
#define LINUX_COMPILER_H
diff --git a/tools/virtio/linux/dma-mapping.h b/tools/virtio/linux/dma-mapping.h
index 18601f6689b9..1571e24e9494 100644
--- a/tools/virtio/linux/dma-mapping.h
+++ b/tools/virtio/linux/dma-mapping.h
@@ -1,3 +1,4 @@
+/* SPDX-License-Identifier: GPL-2.0 */
#ifndef _LINUX_DMA_MAPPING_H
#define _LINUX_DMA_MAPPING_H
diff --git a/tools/virtio/linux/err.h b/tools/virtio/linux/err.h
index e32eff8b2a14..0943c644a701 100644
--- a/tools/virtio/linux/err.h
+++ b/tools/virtio/linux/err.h
@@ -1,3 +1,4 @@
+/* SPDX-License-Identifier: GPL-2.0 */
#ifndef ERR_H
#define ERR_H
#define MAX_ERRNO 4095
diff --git a/tools/virtio/linux/kernel.h b/tools/virtio/linux/kernel.h
index d9554fc3f340..395521a7a8d8 100644
--- a/tools/virtio/linux/kernel.h
+++ b/tools/virtio/linux/kernel.h
@@ -1,3 +1,4 @@
+/* SPDX-License-Identifier: GPL-2.0 */
#ifndef KERNEL_H
#define KERNEL_H
#include <stdbool.h>
diff --git a/tools/virtio/linux/module.h b/tools/virtio/linux/module.h
index 28ce95a05997..9dfa96fea2b2 100644
--- a/tools/virtio/linux/module.h
+++ b/tools/virtio/linux/module.h
@@ -1,3 +1,4 @@
+/* SPDX-License-Identifier: GPL-2.0 */
#include <linux/export.h>
#define MODULE_LICENSE(__MODULE_LICENSE_value) \
diff --git a/tools/virtio/linux/scatterlist.h b/tools/virtio/linux/scatterlist.h
index 68c9e2adc996..9a45f90e2d08 100644
--- a/tools/virtio/linux/scatterlist.h
+++ b/tools/virtio/linux/scatterlist.h
@@ -1,3 +1,4 @@
+/* SPDX-License-Identifier: GPL-2.0 */
#ifndef SCATTERLIST_H
#define SCATTERLIST_H
#include <linux/kernel.h>
diff --git a/tools/virtio/linux/slab.h b/tools/virtio/linux/slab.h
index 7e1c1197d439..319dcaa07755 100644
--- a/tools/virtio/linux/slab.h
+++ b/tools/virtio/linux/slab.h
@@ -1,3 +1,4 @@
+/* SPDX-License-Identifier: GPL-2.0 */
#ifndef LINUX_SLAB_H
#define GFP_KERNEL 0
#define GFP_ATOMIC 0
diff --git a/tools/virtio/linux/uaccess.h b/tools/virtio/linux/uaccess.h
index fa05d01b2c90..991dfb263998 100644
--- a/tools/virtio/linux/uaccess.h
+++ b/tools/virtio/linux/uaccess.h
@@ -1,3 +1,4 @@
+/* SPDX-License-Identifier: GPL-2.0 */
#ifndef UACCESS_H
#define UACCESS_H
diff --git a/tools/virtio/linux/virtio.h b/tools/virtio/linux/virtio.h
index d8f534025b7f..b751350d4ce8 100644
--- a/tools/virtio/linux/virtio.h
+++ b/tools/virtio/linux/virtio.h
@@ -1,3 +1,4 @@
+/* SPDX-License-Identifier: GPL-2.0 */
#ifndef LINUX_VIRTIO_H
#define LINUX_VIRTIO_H
#include <linux/scatterlist.h>
diff --git a/tools/virtio/linux/virtio_byteorder.h b/tools/virtio/linux/virtio_byteorder.h
index 9de9e6ac1d10..5b50f7eebd9c 100644
--- a/tools/virtio/linux/virtio_byteorder.h
+++ b/tools/virtio/linux/virtio_byteorder.h
@@ -1,3 +1,4 @@
+/* SPDX-License-Identifier: GPL-2.0 */
#ifndef _LINUX_VIRTIO_BYTEORDER_STUB_H
#define _LINUX_VIRTIO_BYTEORDER_STUB_H
diff --git a/tools/virtio/linux/virtio_config.h b/tools/virtio/linux/virtio_config.h
index 9ba11815e0a1..dbf14c1e2188 100644
--- a/tools/virtio/linux/virtio_config.h
+++ b/tools/virtio/linux/virtio_config.h
@@ -1,3 +1,4 @@
+/* SPDX-License-Identifier: GPL-2.0 */
#include <linux/virtio_byteorder.h>
#include <linux/virtio.h>
#include <uapi/linux/virtio_config.h>
diff --git a/tools/virtio/ringtest/Makefile b/tools/virtio/ringtest/Makefile
index c012edbdb13b..85c98c2810fb 100644
--- a/tools/virtio/ringtest/Makefile
+++ b/tools/virtio/ringtest/Makefile
@@ -1,3 +1,4 @@
+# SPDX-License-Identifier: GPL-2.0
all:
all: ring virtio_ring_0_9 virtio_ring_poll virtio_ring_inorder ptr_ring noring
diff --git a/tools/virtio/ringtest/noring.c b/tools/virtio/ringtest/noring.c
index b8d1c1daac7c..ce2440d5ca93 100644
--- a/tools/virtio/ringtest/noring.c
+++ b/tools/virtio/ringtest/noring.c
@@ -1,3 +1,4 @@
+// SPDX-License-Identifier: GPL-2.0
#define _GNU_SOURCE
#include "main.h"
#include <assert.h>
diff --git a/tools/virtio/ringtest/ptr_ring.c b/tools/virtio/ringtest/ptr_ring.c
index 7b22f1b20652..38bb171aceba 100644
--- a/tools/virtio/ringtest/ptr_ring.c
+++ b/tools/virtio/ringtest/ptr_ring.c
@@ -1,3 +1,4 @@
+// SPDX-License-Identifier: GPL-2.0
#define _GNU_SOURCE
#include "main.h"
#include <stdlib.h>
diff --git a/tools/virtio/ringtest/run-on-all.sh b/tools/virtio/ringtest/run-on-all.sh
index 29b0d3920bfc..dcc3ea758f48 100755
--- a/tools/virtio/ringtest/run-on-all.sh
+++ b/tools/virtio/ringtest/run-on-all.sh
@@ -1,4 +1,5 @@
#!/bin/sh
+# SPDX-License-Identifier: GPL-2.0
CPUS_ONLINE=$(lscpu --online -p=cpu|grep -v -e '#')
#use last CPU for host. Why not the first?
diff --git a/tools/virtio/uapi/linux/virtio_ring.h b/tools/virtio/uapi/linux/virtio_ring.h
index 4d99c78234d3..cf50b2e5ff02 100644
--- a/tools/virtio/uapi/linux/virtio_ring.h
+++ b/tools/virtio/uapi/linux/virtio_ring.h
@@ -1,3 +1,4 @@
+/* SPDX-License-Identifier: GPL-2.0 */
#ifndef VIRTIO_RING_H
#define VIRTIO_RING_H
#include "../../../../include/uapi/linux/virtio_ring.h"
diff --git a/tools/virtio/virtio-trace/Makefile b/tools/virtio/virtio-trace/Makefile
index 0d2381633475..7843ebcda71d 100644
--- a/tools/virtio/virtio-trace/Makefile
+++ b/tools/virtio/virtio-trace/Makefile
@@ -1,3 +1,4 @@
+# SPDX-License-Identifier: GPL-2.0
CC = gcc
CFLAGS = -O2 -Wall -pthread
diff --git a/tools/virtio/virtio-trace/trace-agent.h b/tools/virtio/virtio-trace/trace-agent.h
index 8de79bfeaa73..e67885969f0e 100644
--- a/tools/virtio/virtio-trace/trace-agent.h
+++ b/tools/virtio/virtio-trace/trace-agent.h
@@ -1,3 +1,4 @@
+/* SPDX-License-Identifier: GPL-2.0 */
#ifndef __TRACE_AGENT_H__
#define __TRACE_AGENT_H__
#include <pthread.h>
diff --git a/tools/virtio/virtio_test.c b/tools/virtio/virtio_test.c
index 0fecaec90d0d..b427def67e7e 100644
--- a/tools/virtio/virtio_test.c
+++ b/tools/virtio/virtio_test.c
@@ -1,3 +1,4 @@
+// SPDX-License-Identifier: GPL-2.0
#define _GNU_SOURCE
#include <getopt.h>
#include <string.h>
diff --git a/tools/virtio/vringh_test.c b/tools/virtio/vringh_test.c
index 9476c616d064..293653463303 100644
--- a/tools/virtio/vringh_test.c
+++ b/tools/virtio/vringh_test.c
@@ -1,3 +1,4 @@
+// SPDX-License-Identifier: GPL-2.0
/* Simple test of virtio code, entirely in userpsace. */
#define _GNU_SOURCE
#include <sched.h>