summaryrefslogtreecommitdiff
path: root/net/bootp.h
diff options
context:
space:
mode:
authorSergey Temerkhanov <s.temerkhanov@gmail.com>2015-04-08 01:41:22 -0500
committerSimon Glass <sjg@chromium.org>2015-04-18 11:11:35 -0600
commit5917e7d165d4a66d724631c196cf307485769821 (patch)
tree27eb6e1b25fb97fe7f92342fd77b24d3d1e7d2ba /net/bootp.h
parentbc0571fc1067ff8a8fd16990ae65c1a2826ea90c (diff)
downloadu-boot-imx-5917e7d165d4a66d724631c196cf307485769821.zip
u-boot-imx-5917e7d165d4a66d724631c196cf307485769821.tar.gz
u-boot-imx-5917e7d165d4a66d724631c196cf307485769821.tar.bz2
net: Fix incorrect DHCP/BOOTP packets on 64-bit systems
This commit fixes incorrect DHCP/BOOTP packet layout caused by 'ulong' type size difference on 64 and 32-bit architectures. It also renames NetReadLong()/NetCopyLong() to net_read_u32/net_copy_u32() accordingly. Signed-off-by: Radha Mohan Chintakuntla <rchintakuntla@cavium.com> Signed-off-by: Sergey Temerkhanov <s.temerkhanov@gmail.com> Signed-off-by: Joe Hershberger <joe.hershberger@ni.com> Acked-by: Simon Glass <sjg@chromium.org>
Diffstat (limited to 'net/bootp.h')
-rw-r--r--net/bootp.h4
1 files changed, 2 insertions, 2 deletions
diff --git a/net/bootp.h b/net/bootp.h
index efc2100..1a59286 100644
--- a/net/bootp.h
+++ b/net/bootp.h
@@ -38,7 +38,7 @@ struct bootp_hdr {
uchar bp_hlen; /* Hardware address length */
# define HWL_ETHER 6
uchar bp_hops; /* Hop count (gateway thing) */
- ulong bp_id; /* Transaction ID */
+ u32 bp_id; /* Transaction ID */
ushort bp_secs; /* Seconds since boot */
ushort bp_spare1; /* Alignment */
struct in_addr bp_ciaddr; /* Client IP address */
@@ -59,7 +59,7 @@ struct bootp_hdr {
*/
/* bootp.c */
-extern ulong bootp_id; /* ID of cur BOOTP request */
+extern u32 bootp_id; /* ID of cur BOOTP request */
extern int bootp_try;