Skip to content

Commit 5669726

Browse files
committed
smsc9220_eth_drv.c; fix warnings from "gcc -Wconversion"
smsc9220_eth_drv.c; fix warnings from "gcc -Wconversion" Signed-off-by: Florian La Roche <[email protected]>
1 parent 8e437be commit 5669726

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

source/portable/NetworkInterface/MPS2_AN385/ether_lan9118/smsc9220_eth_drv.c

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -958,7 +958,7 @@ enum smsc9220_error_t smsc9220_read_mac_address( const struct smsc9220_eth_dev_t
958958
mac[ 0 ] = mac_low & 0xFF;
959959
mac[ 1 ] = ( mac_low >> 8 ) & 0xFF;
960960
mac[ 2 ] = ( mac_low >> 16 ) & 0xFF;
961-
mac[ 3 ] = ( mac_low >> 24 ) & 0xFF;
961+
mac[ 3 ] = ( char ) ( ( mac_low >> 24 ) & 0xFF );
962962
mac[ 4 ] = mac_high & 0xFF;
963963
mac[ 5 ] = ( mac_high >> 8 ) & 0xFF;
964964

@@ -1223,7 +1223,7 @@ uint32_t smsc9220_peek_next_packet_size( const struct
12231223
}
12241224
else
12251225
{
1226-
rx_status_from_peek = -1;
1226+
rx_status_from_peek = ( uint32_t ) -1;
12271227
}
12281228

12291229
return packet_size;

0 commit comments

Comments
 (0)