From: Lubomir Rintel Date: Tue, 1 Feb 2022 14:33:53 +0000 (+0100) Subject: util: add ARCH_IS_MIPS helper macro X-Git-Tag: v8.1.0-rc1~220 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=395bbd61eaad7ea67ea212ebf9aeca1ea7e08ec9;p=thirdparty%2Flibvirt.git util: add ARCH_IS_MIPS helper macro Identifies all of various MIPS sub-architectures: 32-bit or 64-bit, little-endian or big-endian. Signed-off-by: Lubomir Rintel Reviewed-by: Michal Privoznik --- diff --git a/src/util/virarch.h b/src/util/virarch.h index 528f84f8a5..81b1b27a57 100644 --- a/src/util/virarch.h +++ b/src/util/virarch.h @@ -95,6 +95,11 @@ typedef enum { #define ARCH_IS_S390(arch) ((arch) == VIR_ARCH_S390 ||\ (arch) == VIR_ARCH_S390X) +#define ARCH_IS_MIPS(arch) ((arch) == VIR_ARCH_MIPS ||\ + (arch) == VIR_ARCH_MIPSEL ||\ + (arch) == VIR_ARCH_MIPS64 ||\ + (arch) == VIR_ARCH_MIPS64EL) + #define ARCH_IS_MIPS64(arch) ((arch) == VIR_ARCH_MIPS64 ||\ (arch) == VIR_ARCH_MIPS64EL)