The patch added to nominally fix this issue is incorrect; it is setting the wrong bit in the BOOTP flags field for broadcast:
+ bootp.flags = htons(0x800);
The correct value should be 0x8000. This is causing issues with switches that reject the packet as having bits set in a "must be zero" flag area.
RFC 1542 defines the flags field as 16 bits, and the broadcast bit is the most significant bit:
2.2 Definition of the 'flags' Field
The standard BOOTP message format defined in [1] includes a two-octet
field located between the 'secs' field and the 'ciaddr' field. This
field is merely designated as "unused" and its contents left
unspecified, although Section 7.1 of [1] does offer the following
suggestion:
"Before setting up the packet for the first time, it is a good
idea to clear the entire packet buffer to all zeros; this will
place all fields in their default state."
This memo hereby designates this two-octet field as the 'flags'
field.
This memo hereby defines the most significant bit of the 'flags'
field as the BROADCAST (B) flag. The semantics of this flag are
discussed in Sections 3.1.1 and 4.1.2 of this memo.
The remaining bits of the 'flags' field are reserved for future
use. They MUST be set to zero by clients and ignored by servers
[...]
and relay agents.
The patch added to nominally fix this issue is incorrect; it is setting the wrong bit in the BOOTP flags field for broadcast:
+ bootp.flags = htons(0x800);
The correct value should be 0x8000. This is causing issues with switches that reject the packet as having bits set in a "must be zero" flag area.
RFC 1542 defines the flags field as 16 bits, and the broadcast bit is the most significant bit:
2.2 Definition of the 'flags' Field
The standard BOOTP message format defined in [1] includes a two-octet
field located between the 'secs' field and the 'ciaddr' field. This
field is merely designated as "unused" and its contents left
unspecified, although Section 7.1 of [1] does offer the following
suggestion:
"Before setting up the packet for the first time, it is a good
idea to clear the entire packet buffer to all zeros; this will
place all fields in their default state."
This memo hereby designates this two-octet field as the 'flags'
field.
This memo hereby defines the most significant bit of the 'flags'
field as the BROADCAST (B) flag. The semantics of this flag are
discussed in Sections 3.1.1 and 4.1.2 of this memo.
The remaining bits of the 'flags' field are reserved for future
use. They MUST be set to zero by clients and ignored by servers
[...]
and relay agents.