[netdevice] Allow MTU to be changed at runtime

Provide a settings applicator to modify netdev->max_pkt_len in
response to changes to the "mtu" setting (DHCP option 26).

Note that as with MAC address changes, drivers are permitted to
completely ignore any changes in the MTU value.  The net result will
be that iPXE effectively uses the smaller of either the hardware
default MTU or the software configured MTU.

Signed-off-by: Michael Brown <mcb30@ipxe.org>
This commit is contained in:
Michael Brown
2017-01-23 17:47:28 +00:00
parent 4e85b2708f
commit 16aed6e5ce
3 changed files with 67 additions and 3 deletions

View File

@@ -83,6 +83,9 @@ struct dhcp_packet;
/** Root path */
#define DHCP_ROOT_PATH 17
/** Maximum transmission unit */
#define DHCP_MTU 26
/** Vendor encapsulated options */
#define DHCP_VENDOR_ENCAP 43