Commit 7044c6bb authored by Joe Hershberger's avatar Joe Hershberger Committed by Simon Glass

net: cosmetic: Clean up DHCP variables and functions

Make a thorough pass through all variables and function names contained
within bootp.c and remove CamelCase and improve naming.
Signed-off-by: default avatarJoe Hershberger <joe.hershberger@ni.com>
Acked-by: default avatarSimon Glass <sjg@chromium.org>
parent 85d25e0e
This diff is collapsed.
......@@ -29,7 +29,7 @@ extern u8 *dhcp_vendorex_proc(u8 *e); /*rtn next e if mine,else NULL */
#define OPT_FIELD_SIZE 64
#endif
struct Bootp_t {
struct bootp_hdr {
uchar bp_op; /* Operation */
# define OP_BOOTREQUEST 1
# define OP_BOOTREPLY 2
......@@ -51,7 +51,7 @@ struct Bootp_t {
char bp_vend[OPT_FIELD_SIZE]; /* Vendor information */
};
#define BOOTP_HDR_SIZE sizeof(struct Bootp_t)
#define BOOTP_HDR_SIZE sizeof(struct bootp_hdr)
/**********************************************************************/
/*
......@@ -59,16 +59,16 @@ struct Bootp_t {
*/
/* bootp.c */
extern ulong BootpID; /* ID of cur BOOTP request */
extern int BootpTry;
extern ulong bootp_id; /* ID of cur BOOTP request */
extern int bootp_try;
/* Send a BOOTP request */
extern void BootpReset(void);
extern void BootpRequest(void);
void bootp_reset(void);
void bootp_request(void);
/****************** DHCP Support *********************/
extern void DhcpRequest(void);
void dhcp_request(void);
/* DHCP States */
typedef enum { INIT,
......
......@@ -381,16 +381,16 @@ restart:
#endif
#if defined(CONFIG_CMD_DHCP)
case DHCP:
BootpReset();
bootp_reset();
net_ip.s_addr = 0;
DhcpRequest(); /* Basically same as BOOTP */
dhcp_request(); /* Basically same as BOOTP */
break;
#endif
case BOOTP:
BootpReset();
bootp_reset();
net_ip.s_addr = 0;
BootpRequest();
bootp_request();
break;
#if defined(CONFIG_CMD_RARP)
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment