Ignore:
File:
1 edited

Legend:

Unmodified
Added
Removed
  • uspace/lib/net/include/net_checksum.h

    r00d7e1b r8d601db  
    3030 * @{
    3131 */
     32
    3233/** @file
    3334 * General CRC and checksum computation.
     
    4142
    4243/** IP checksum value for computed zero checksum.
    43  *
    4444 * Zero is returned as 0xFFFF (not flipped)
    45  *
    4645 */
    47 #define IP_CHECKSUM_ZERO  0xffffU
     46#define IP_CHECKSUM_ZERO        0xffffU
    4847
    49 #ifdef __BE__
    50 
     48#ifdef ARCH_IS_BIG_ENDIAN
    5149#define compute_crc32(seed, data, length) \
    5250        compute_crc32_be(seed, (uint8_t *) data, length)
    53 
    54 #endif
    55 
    56 #ifdef __LE__
    57 
     51#else
    5852#define compute_crc32(seed, data, length) \
    5953        compute_crc32_le(seed, (uint8_t *) data, length)
    60 
    6154#endif
    6255
     
    6760extern uint16_t flip_checksum(uint16_t);
    6861extern uint16_t ip_checksum(uint8_t *, size_t);
    69 extern uint64_t multicast_hash(const uint8_t addr[6]);
    7062
    7163#endif
Note: See TracChangeset for help on using the changeset viewer.