mirror of
https://gitlab.isc.org/isc-projects/dhcp
synced 2025-09-01 06:45:27 +00:00
[master] Fixed unsupported vlan tag build issue
Merges in rt38677
This commit is contained in:
8
RELNOTES
8
RELNOTES
@@ -52,6 +52,14 @@ ISC DHCP is open source software maintained by Internet Systems
|
|||||||
Consortium. This product includes cryptographic software written
|
Consortium. This product includes cryptographic software written
|
||||||
by Eric Young (eay@cryptsoft.com).
|
by Eric Young (eay@cryptsoft.com).
|
||||||
|
|
||||||
|
Changes since 4.3.2c1
|
||||||
|
|
||||||
|
- Corrected a compilation error introduced by the fix for ISC-Bugs #37415.
|
||||||
|
The error occurs on Linux variants that do not support VLAN tag information
|
||||||
|
in packet auxiliary data. The configure script now only enables inclusion
|
||||||
|
of the VLAN tag-based logic if it is supported by the underlying OS.
|
||||||
|
[ISC-Bugs #38677]
|
||||||
|
|
||||||
Changes since 4.3.2b1
|
Changes since 4.3.2b1
|
||||||
|
|
||||||
- Specifying the option, --disable-debug, on the configure script command line
|
- Specifying the option, --disable-debug, on the configure script command line
|
||||||
|
@@ -398,7 +398,8 @@ ssize_t receive_packet (interface, buf, len, from, hfrom)
|
|||||||
* NICs perform VLAN encapsulation, while drivers for PCnet series
|
* NICs perform VLAN encapsulation, while drivers for PCnet series
|
||||||
* do not, for example. The linux kernel makes stripped vlan info
|
* do not, for example. The linux kernel makes stripped vlan info
|
||||||
* visible to user space via CMSG/auxdata, this appears to not be
|
* visible to user space via CMSG/auxdata, this appears to not be
|
||||||
* true for BSD OSs.)
|
* true for BSD OSs.). NOTE: this is only supported on linux flavors
|
||||||
|
* which define the tpacket_auxdata.tp_vlan_tci.
|
||||||
*
|
*
|
||||||
* b. Determine if checksum is valid for use. It may not be if
|
* b. Determine if checksum is valid for use. It may not be if
|
||||||
* checksum offloading is enabled on the interface. */
|
* checksum offloading is enabled on the interface. */
|
||||||
@@ -409,8 +410,11 @@ ssize_t receive_packet (interface, buf, len, from, hfrom)
|
|||||||
cmsg->cmsg_type == PACKET_AUXDATA) {
|
cmsg->cmsg_type == PACKET_AUXDATA) {
|
||||||
struct tpacket_auxdata *aux = (void *)CMSG_DATA(cmsg);
|
struct tpacket_auxdata *aux = (void *)CMSG_DATA(cmsg);
|
||||||
/* Discard packets with stripped vlan id */
|
/* Discard packets with stripped vlan id */
|
||||||
|
|
||||||
|
#ifdef VLAN_TCI_PRESENT
|
||||||
if (aux->tp_vlan_tci != 0)
|
if (aux->tp_vlan_tci != 0)
|
||||||
return 0;
|
return 0;
|
||||||
|
#endif
|
||||||
|
|
||||||
csum_ready = ((aux->tp_status & TP_STATUS_CSUMNOTREADY)
|
csum_ready = ((aux->tp_status & TP_STATUS_CSUMNOTREADY)
|
||||||
? 0 : 1);
|
? 0 : 1);
|
||||||
|
10
configure
vendored
10
configure
vendored
@@ -6570,6 +6570,16 @@ fi
|
|||||||
fi
|
fi
|
||||||
|
|
||||||
|
|
||||||
|
ac_fn_c_check_member "$LINENO" "struct tpacket_auxdata" "tp_vlan_tci" "ac_cv_member_struct_tpacket_auxdata_tp_vlan_tci" "#include <linux/if_packet.h>
|
||||||
|
"
|
||||||
|
if test "x$ac_cv_member_struct_tpacket_auxdata_tp_vlan_tci" = xyes; then :
|
||||||
|
|
||||||
|
$as_echo "#define VLAN_TCI_PRESENT 1" >>confdefs.h
|
||||||
|
|
||||||
|
|
||||||
|
fi
|
||||||
|
|
||||||
|
|
||||||
libbind=
|
libbind=
|
||||||
|
|
||||||
# Check whether --with-libbind was given.
|
# Check whether --with-libbind was given.
|
||||||
|
@@ -576,6 +576,10 @@ AC_CHECK_MEMBER(struct msghdr.msg_control,,
|
|||||||
#include <sys/socket.h>
|
#include <sys/socket.h>
|
||||||
])
|
])
|
||||||
|
|
||||||
|
AC_CHECK_MEMBER(struct tpacket_auxdata.tp_vlan_tci,
|
||||||
|
[AC_DEFINE([VLAN_TCI_PRESENT], [1], [tpacket_auxdata.tp_vlan_tci present])]
|
||||||
|
,, [#include <linux/if_packet.h>])
|
||||||
|
|
||||||
libbind=
|
libbind=
|
||||||
AC_ARG_WITH(libbind,
|
AC_ARG_WITH(libbind,
|
||||||
AS_HELP_STRING([--with-libbind=PATH],[bind includes and libraries are in PATH
|
AS_HELP_STRING([--with-libbind=PATH],[bind includes and libraries are in PATH
|
||||||
|
@@ -185,6 +185,9 @@
|
|||||||
/* Version number of package */
|
/* Version number of package */
|
||||||
#undef VERSION
|
#undef VERSION
|
||||||
|
|
||||||
|
/* tpacket_auxdata.tp_vlan_tci present */
|
||||||
|
#undef VLAN_TCI_PRESENT
|
||||||
|
|
||||||
/* Define WORDS_BIGENDIAN to 1 if your processor stores words with the most
|
/* Define WORDS_BIGENDIAN to 1 if your processor stores words with the most
|
||||||
significant byte first (like Motorola and SPARC, unlike Intel). */
|
significant byte first (like Motorola and SPARC, unlike Intel). */
|
||||||
#if defined AC_APPLE_UNIVERSAL_BUILD
|
#if defined AC_APPLE_UNIVERSAL_BUILD
|
||||||
|
Reference in New Issue
Block a user