OSDN Git Service

virtio: Move extern declaration to header file
authorStefan Weil <sw@weilnetz.de>
Mon, 7 Jul 2014 19:13:27 +0000 (21:13 +0200)
committerMichael Tokarev <mjt@tls.msk.ru>
Fri, 8 Aug 2014 20:06:32 +0000 (00:06 +0400)
This fixes a warning from smatch (static code analyser).

Signed-off-by: Stefan Weil <sw@weilnetz.de>
Signed-off-by: Michael Tokarev <mjt@tls.msk.ru>
hw/virtio/vhost-backend.c
include/hw/virtio/vhost-backend.h

index 35316c4..ff4f200 100644 (file)
@@ -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)
 {
index d31768a..e472f29 100644 (file)
@@ -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);