mirror of
https://github.com/ipxe/ipxe
synced 2025-12-30 22:08:48 +03:00
[compiler] Fix 64bit compile time errors
Apart from format specifier fixes there are two changes in proper code: - Change type of regs in skge_hw to unsigned long - Cast result of sizeof in myri10ge to uint32_t Both don't change anything for i386 and should be fine on x86_64. Signed-off-by: Piotr Jaroszyński <p.jaroszynski@gmail.com> Signed-off-by: Joshua Oreman <oremanj@rwcr.net> Signed-off-by: Michael Brown <mcb30@ipxe.org>
This commit is contained in:
committed by
Michael Brown
parent
905ea56753
commit
7c6d3752c9
@@ -383,7 +383,7 @@ static int wpa_maybe_install_gtk ( struct wpa_common_ctx *ctx,
|
||||
return -ENOENT;
|
||||
|
||||
if ( ie->len - 6u > sizeof ( ctx->gtk.tk ) ) {
|
||||
DBGC ( ctx, "WPA %p: GTK KDE is too long (%d bytes, max %d)\n",
|
||||
DBGC ( ctx, "WPA %p: GTK KDE is too long (%d bytes, max %zd)\n",
|
||||
ctx, ie->len - 4, sizeof ( ctx->gtk.tk ) );
|
||||
return -EINVAL;
|
||||
}
|
||||
@@ -737,7 +737,7 @@ static int wpa_handle_1_of_2 ( struct wpa_common_ctx *ctx,
|
||||
return rc; /* non-fatal */
|
||||
}
|
||||
if ( pkt->datalen > sizeof ( ctx->gtk.tk ) ) {
|
||||
DBGC ( ctx, "WPA %p: too much GTK data (%d > %d)\n",
|
||||
DBGC ( ctx, "WPA %p: too much GTK data (%d > %zd)\n",
|
||||
ctx, pkt->datalen, sizeof ( ctx->gtk.tk ) );
|
||||
return wpa_fail ( ctx, -EINVAL );
|
||||
}
|
||||
@@ -813,7 +813,7 @@ static int eapol_key_rx ( struct io_buffer *iob, struct net_device *netdev,
|
||||
}
|
||||
|
||||
if ( ( void * ) ( pkt + 1 ) + ntohs ( pkt->datalen ) > iob->tail ) {
|
||||
DBGC ( ctx, "WPA %p: packet truncated (has %d extra bytes, "
|
||||
DBGC ( ctx, "WPA %p: packet truncated (has %zd extra bytes, "
|
||||
"states %d)\n", ctx, iob->tail - ( void * ) ( pkt + 1 ),
|
||||
ntohs ( pkt->datalen ) );
|
||||
rc = -EINVAL;
|
||||
|
||||
Reference in New Issue
Block a user