qemu-trivial
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Qemu-trivial] [PATCH] virtio: Move extern declaration to header file


From: Stefan Weil
Subject: [Qemu-trivial] [PATCH] virtio: Move extern declaration to header file
Date: Mon, 7 Jul 2014 21:13:27 +0200

This fixes a warning from smatch (static code analyser).

Signed-off-by: Stefan Weil <address@hidden>
---
 hw/virtio/vhost-backend.c         |    2 --
 include/hw/virtio/vhost-backend.h |    2 ++
 2 files changed, 2 insertions(+), 2 deletions(-)

diff --git a/hw/virtio/vhost-backend.c b/hw/virtio/vhost-backend.c
index 35316c4..ff4f200 100644
--- a/hw/virtio/vhost-backend.c
+++ b/hw/virtio/vhost-backend.c
@@ -14,8 +14,6 @@
 
 #include <sys/ioctl.h>
 
-extern const VhostOps user_ops;
-
 static int vhost_kernel_call(struct vhost_dev *dev, unsigned long int request,
                              void *arg)
 {
diff --git a/include/hw/virtio/vhost-backend.h 
b/include/hw/virtio/vhost-backend.h
index d31768a..e472f29 100644
--- a/include/hw/virtio/vhost-backend.h
+++ b/include/hw/virtio/vhost-backend.h
@@ -32,6 +32,8 @@ typedef struct VhostOps {
     vhost_backend_cleanup vhost_backend_cleanup;
 } VhostOps;
 
+extern const VhostOps user_ops;
+
 int vhost_set_backend_type(struct vhost_dev *dev,
                            VhostBackendType backend_type);
 
-- 
1.7.10.4




reply via email to

[Prev in Thread] Current Thread [Next in Thread]