mirror of
https://github.com/ipxe/ipxe
synced 2025-12-30 13:11:11 +03:00
[tcpip] Do not fall back to using unoptimised TCP/IP checksumming
Require architecture-specific code to make a deliberate choice to use the unoptimised generic_tcpip_continue_chksum() function, if there is no optimised version available. Signed-off-by: Michael Brown <mcb30@ipxe.org>
This commit is contained in:
@@ -42,8 +42,8 @@ extern char x86_tcpip_loop_end[];
|
||||
* @v len Length of data buffer
|
||||
* @ret cksum Updated checksum, in network byte order
|
||||
*/
|
||||
uint16_t x86_tcpip_continue_chksum ( uint16_t partial,
|
||||
const void *data, size_t len ) {
|
||||
uint16_t tcpip_continue_chksum ( uint16_t partial, const void *data,
|
||||
size_t len ) {
|
||||
unsigned long sum = ( ( ~partial ) & 0xffff );
|
||||
unsigned long initial_word_count;
|
||||
unsigned long loop_count;
|
||||
|
||||
@@ -9,9 +9,7 @@
|
||||
|
||||
FILE_LICENCE ( GPL2_OR_LATER_OR_UBDL );
|
||||
|
||||
extern uint16_t x86_tcpip_continue_chksum ( uint16_t partial,
|
||||
const void *data, size_t len );
|
||||
|
||||
#define tcpip_continue_chksum x86_tcpip_continue_chksum
|
||||
extern uint16_t tcpip_continue_chksum ( uint16_t partial, const void *data,
|
||||
size_t len );
|
||||
|
||||
#endif /* _BITS_TCPIP_H */
|
||||
|
||||
Reference in New Issue
Block a user