1From f72227aadcc1d0d8c46a8b4fe62ba3d03ffa42c3 Mon Sep 17 00:00:00 2001 2From: Simon Goldschmidt <goldsimon@gmx.de> 3Date: Wed, 7 Nov 2018 10:49:06 +0100 4Subject: [PATCH] fix compiling ETHARP_SUPPORT_VLAN without LWIP_HOOK_VLAN_SET 5 and LWIP_VLAN_PCP 6 7--- 8 src/netif/ethernet.c | 4 ++-- 9 1 file changed, 2 insertions(+), 2 deletions(-) 10 11diff --git a/src/netif/ethernet.c b/src/netif/ethernet.c 12index 9e367f8cc..6db434b46 100644 13--- a/src/netif/ethernet.c 14+++ b/src/netif/ethernet.c 15@@ -273,7 +273,7 @@ ethernet_output(struct netif * netif, struct pbuf * p, 16 struct eth_hdr *ethhdr; 17 u16_t eth_type_be = lwip_htons(eth_type); 18 19-#if ETHARP_SUPPORT_VLAN 20+#if ETHARP_SUPPORT_VLAN && (defined(LWIP_HOOK_VLAN_SET) || LWIP_VLAN_PCP) 21 s32_t vlan_prio_vid; 22 #ifdef LWIP_HOOK_VLAN_SET 23 vlan_prio_vid = LWIP_HOOK_VLAN_SET(netif, p, src, dst, eth_type); 24@@ -297,7 +297,7 @@ ethernet_output(struct netif * netif, struct pbuf * p, 25 26 eth_type_be = PP_HTONS(ETHTYPE_VLAN); 27 } else 28-#endif /* ETHARP_SUPPORT_VLAN && defined(LWIP_HOOK_VLAN_SET) */ 29+#endif /* ETHARP_SUPPORT_VLAN && (defined(LWIP_HOOK_VLAN_SET) || LWIP_VLAN_PCP) */ 30 { 31 if (pbuf_add_header(p, SIZEOF_ETH_HDR) != 0) { 32 goto pbuf_header_failed; 33 34