lkml.org 
[lkml]   [2018]   [Jul]   [12]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
Patch in this message
/
From
Subject[PATCH] samples: fix compilation of mpssd
Date
Errors:

In file included from /usr/include/x86_64-linux-gnu/sys/types.h:194:0,
from /usr/include/stdlib.h:394,
from mpssd.c:23:
mpssd.c:93:10: error: initializer element is not constant
.num = htole16(MIC_VRING_ENTRIES),

mpssd.c:610:10: warning: implicit declaration of function ‘readv’;

Signed-off-by: Constantine Shulyupin <const@MakeLinux.com>
---
samples/mic/mpssd/mpssd.c | 5 +++++
1 file changed, 5 insertions(+)

diff --git a/samples/mic/mpssd/mpssd.c b/samples/mic/mpssd/mpssd.c
index f42ce551bb48..9cddb9cfdc79 100644
--- a/samples/mic/mpssd/mpssd.c
+++ b/samples/mic/mpssd/mpssd.c
@@ -33,6 +33,7 @@
#include <sys/stat.h>
#include <sys/mman.h>
#include <sys/socket.h>
+#include <sys/uio.h>
#include <linux/virtio_ring.h>
#include <linux/virtio_net.h>
#include <linux/virtio_console.h>
@@ -77,6 +78,10 @@ static struct mic_info mic_list;
#define VIRTIO_NET_HDR_F_DATA_VALID 2 /* Csum is valid */
#endif

+#define __uint16_identity(x) (x)
+#define __uint64_identity(x) (x)
+#define __uint32_identity(x) (x)
+
static struct {
struct mic_device_desc dd;
struct mic_vqconfig vqconfig[2];
--
2.17.1
\
 
 \ /
  Last update: 2018-07-15 22:05    [W:0.037 / U:0.224 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site