[<prev] [next>] [day] [month] [year] [list]
Message-Id: <20180712051739.24709-1-const@MakeLinux.com>
Date: Thu, 12 Jul 2018 08:17:36 +0300
From: Constantine Shulyupin <const@...eLinux.com>
To: Sudeep Dutt <sudeep.dutt@...el.com>,
Ashutosh Dixit <ashutosh.dixit@...el.com>,
"Paul E. McKenney" <paulmck@...ux.vnet.ibm.com>,
Mark Rutland <mark.rutland@....com>,
Ingo Molnar <mingo@...nel.org>,
Constantine Shulyupin <const@...eLinux.com>,
linux-kernel@...r.kernel.org (open list)
Subject: [PATCH] samples: fix compilation of mpssd
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@...eLinux.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
Powered by blists - more mailing lists