KallistiOS git master
Independent SDK for the Sega Dreamcast
|
Byte-order related macros. More...
Go to the source code of this file.
Macros | |
#define | BYTE_ORDER LITTLE_ENDIAN |
Define the byte-order of the platform in use. | |
#define | arch_swap16(x) |
Swap the byte order of a 16-bit integer. | |
#define | arch_swap32(x) |
Swap the byte order of a 32-bit integer. | |
#define | arch_ntohs(x) arch_swap16(x) |
Convert network-to-host short. | |
#define | arch_ntohl(x) arch_swap32(x) |
Convert network-to-host long. | |
#define | arch_htons(x) arch_swap16(x) |
Convert host-to-network short. | |
#define | arch_htonl(x) arch_swap32(x) |
Convert host-to-network long. | |
Byte-order related macros.
This file contains architecture-specific byte-order related macros and/or functions. Each platform should define six macros/functions in this file: arch_swap16, arch_swap32, arch_ntohs, arch_ntohl, arch_htons, and arch_htonl. The first two of these swap the byte order of 16-bit and 32-bit integers, respectively. The other four macros will be used by the kernel to implement the network-related byte order functions.