]> asedeno.scripts.mit.edu Git - linux.git/commitdiff
vhost: make msg padding explicit
authorMichael S. Tsirkin <mst@redhat.com>
Fri, 27 Apr 2018 16:02:05 +0000 (19:02 +0300)
committerDavid S. Miller <davem@davemloft.net>
Tue, 1 May 2018 18:05:13 +0000 (14:05 -0400)
There's a 32 bit hole just after type. It's best to
give it a name, this way compiler is forced to initialize
it with rest of the structure.

Reported-by: Kevin Easton <kevin@guarana.org>
Signed-off-by: Michael S. Tsirkin <mst@redhat.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
include/uapi/linux/vhost.h

index c51f8e5cc6080c03028727cdb81343fc4cabb6e1..5a8ad064445b91731eb70c0a6419acc84cad16b9 100644 (file)
@@ -68,6 +68,7 @@ struct vhost_iotlb_msg {
 
 struct vhost_msg {
        int type;
+       int padding0;
        union {
                struct vhost_iotlb_msg iotlb;
                __u8 padding[64];