[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Qemu-devel] [PATCH 18/27] slirp: replace net/eth.h inclusion with own d
From: |
Marc-André Lureau |
Subject: |
[Qemu-devel] [PATCH 18/27] slirp: replace net/eth.h inclusion with own defines |
Date: |
Thu, 17 Jan 2019 15:43:50 +0400 |
Signed-off-by: Marc-André Lureau <address@hidden>
---
slirp/ip6.h | 1 -
slirp/slirp.h | 1 -
slirp/util.h | 10 ++++++++++
3 files changed, 10 insertions(+), 2 deletions(-)
diff --git a/slirp/ip6.h b/slirp/ip6.h
index b6ba0a63927..e0a13dec1cc 100644
--- a/slirp/ip6.h
+++ b/slirp/ip6.h
@@ -7,7 +7,6 @@
#define SLIRP_IP6_H
#include <glib.h>
-#include "net/eth.h"
#define ALLNODES_MULTICAST { .s6_addr = \
{ 0xff, 0x02, 0x00, 0x00,\
diff --git a/slirp/slirp.h b/slirp/slirp.h
index 5707805be22..c9f91438016 100644
--- a/slirp/slirp.h
+++ b/slirp/slirp.h
@@ -48,7 +48,6 @@ typedef char *caddr_t;
#include "util.h"
#include "qemu/queue.h"
-#include "net/eth.h"
#include "libslirp.h"
#include "ip.h"
diff --git a/slirp/util.h b/slirp/util.h
index 4664e8159ba..ef758045602 100644
--- a/slirp/util.h
+++ b/slirp/util.h
@@ -50,6 +50,16 @@
#define SCALE_MS 1000000
+#define ETH_ALEN 6
+#define ETH_HLEN 14
+#define ETH_P_IP (0x0800) /* Internet Protocol packet */
+#define ETH_P_ARP (0x0806) /* Address Resolution packet */
+#define ETH_P_IPV6 (0x86dd)
+#define ETH_P_VLAN (0x8100)
+#define ETH_P_DVLAN (0x88a8)
+#define ETH_P_NCSI (0x88f8)
+#define ETH_P_UNKNOWN (0xffff)
+
#ifdef _WIN32
int slirp_closesocket(int fd);
int slirp_ioctlsocket(int fd, int req, void *val);
--
2.20.1.98.gecbdaf0899
- [Qemu-devel] [PATCH 12/27] slirp: move QEMU state saving to a separate unit, (continued)
- [Qemu-devel] [PATCH 12/27] slirp: move QEMU state saving to a separate unit, Marc-André Lureau, 2019/01/17
- [Qemu-devel] [PATCH 14/27] slirp: improve windows headers inclusion, Marc-André Lureau, 2019/01/17
- [Qemu-devel] [PATCH 16/27] slirp: remove qemu timer.h dependency, Marc-André Lureau, 2019/01/17
- [Qemu-devel] [PATCH 17/27] slirp: remove now useless QEMU headers inclusions, Marc-André Lureau, 2019/01/17
- [Qemu-devel] [PATCH 15/27] slirp: add slirp own version of pstrcpy, Marc-André Lureau, 2019/01/17
- [Qemu-devel] [PATCH 18/27] slirp: replace net/eth.h inclusion with own defines,
Marc-André Lureau <=
- [Qemu-devel] [PATCH 19/27] slirp: replace qemu qtailq with slirp own copy, Marc-André Lureau, 2019/01/17
- [Qemu-devel] [PATCH 20/27] slirp: replace remaining qemu headers dependency, Marc-André Lureau, 2019/01/17
- [Qemu-devel] [PATCH 22/27] slirp: improve send_packet() callback, Marc-André Lureau, 2019/01/17
- [Qemu-devel] [PATCH 21/27] slirp: prefer c99 types over BSD kind, Marc-André Lureau, 2019/01/17