From: anonymix007 <48598263+anonymix007@users.noreply.github.com> Date: Mon, 31 Mar 2025 17:37:13 +0000 (+0300) Subject: boot: Add be16toh, le16toh and le32toh X-Git-Tag: v258-rc1~668^2~6 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=edda8d51f1cfb282d91ceebd61a8e4fc9e126dce;p=thirdparty%2Fsystemd.git boot: Add be16toh, le16toh and le32toh --- diff --git a/src/boot/util.h b/src/boot/util.h index 115258d5ee7..2145b6e2589 100644 --- a/src/boot/util.h +++ b/src/boot/util.h @@ -233,7 +233,10 @@ void *find_configuration_table(const EFI_GUID *guid); char16_t *get_extra_dir(const EFI_DEVICE_PATH *file_path); #if __BYTE_ORDER__ == __ORDER_LITTLE_ENDIAN__ +# define be16toh(x) __builtin_bswap16(x) # define be32toh(x) __builtin_bswap32(x) +# define le16toh(x) (x) +# define le32toh(x) (x) #else # error "Unexpected byte order in EFI mode?" #endif