mirror of
https://github.com/u-boot/u-boot.git
synced 2025-05-08 19:11:53 +00:00
convert print_IPaddr() to %pI4
Now that our printf functions support the %pI4 modifier like the kernel, let's drop the inflexible print_IPaddr() function and covert over to the %pI4 modifier. Signed-off-by: Mike Frysinger <vapier@gentoo.org> CC: Ben Warren <biggerbadderben@gmail.com>
This commit is contained in:
parent
6c6166f529
commit
b6446b6775
6 changed files with 33 additions and 69 deletions
18
net/bootp.c
18
net/bootp.c
|
@ -271,17 +271,11 @@ static void BootpVendorProcess (u8 * ext, int size)
|
|||
|
||||
#ifdef DEBUG_BOOTP_EXT
|
||||
puts ("[BOOTP] Received fields: \n");
|
||||
if (NetOurSubnetMask) {
|
||||
puts ("NetOurSubnetMask : ");
|
||||
print_IPaddr (NetOurSubnetMask);
|
||||
putc ('\n');
|
||||
}
|
||||
if (NetOurSubnetMask)
|
||||
printf ("NetOurSubnetMask : %pI4\n", &NetOurSubnetMask);
|
||||
|
||||
if (NetOurGatewayIP) {
|
||||
puts ("NetOurGatewayIP : ");
|
||||
print_IPaddr (NetOurGatewayIP);
|
||||
putc ('\n');
|
||||
}
|
||||
if (NetOurGatewayIP)
|
||||
printf ("NetOurGatewayIP : %pI4", &NetOurGatewayIP);
|
||||
|
||||
if (NetBootFileSize) {
|
||||
printf ("NetBootFileSize : %d\n", NetBootFileSize);
|
||||
|
@ -942,9 +936,7 @@ DhcpHandler(uchar * pkt, unsigned dest, unsigned src, unsigned len)
|
|||
DhcpOptionsProcess((u8 *)&bp->bp_vend[4], bp);
|
||||
BootpCopyNetParams(bp); /* Store net params from reply */
|
||||
dhcp_state = BOUND;
|
||||
puts ("DHCP client bound to address ");
|
||||
print_IPaddr(NetOurIP);
|
||||
putc ('\n');
|
||||
printf ("DHCP client bound to address %pI4\n", &NetOurIP);
|
||||
|
||||
/* Obey the 'autoload' setting */
|
||||
if ((s = getenv("autoload")) != NULL) {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue