#include <oskit/net/bootp.h>int bootp(oskit_etherdev_t *dev, [in/out] struct bootp_net_info *info);
This function performs a BOOTP request with a timeout of 200 milliseconds (1/5 of a second) with five retries using bootp_gen.The only field of info that is used as input for the request is the ip field corresponding to BOOTP_NET_IP. See RFC 1048 for more explanation. Users should set this field if they know their IP address; BOOTP_NET_IP needs to be set in flags if this is the case.
Lists of IP addresses and strings are dynamically allocated as needed, users of boopt_gen should pass the info struct to bootp_free to deallocate them.
- dev
- A pointer to an oskit_etherdev device interface.
- info
- The BOOTP info to be used.
Returns zero on success, or an error code specified in <oskit/error.h> on error.
bootp_net_info