提交 1a5a5b3d 编写于 作者: J Jonathon Jongsma 提交者: Ján Tomko

util: arch.h: use #pragma once in headers

Signed-off-by: NJonathon Jongsma <jjongsma@redhat.com>
Reviewed-by: NJán Tomko <jtomko@redhat.com>
Signed-off-by: NJán Tomko <jtomko@redhat.com>
上级 7987eeaf
......@@ -19,10 +19,9 @@
*
*/
#ifndef LIBVIRT_VIRARCH_H
# define LIBVIRT_VIRARCH_H
#pragma once
# include "internal.h"
#include "internal.h"
typedef enum {
VIR_ARCH_NONE,
......@@ -73,28 +72,28 @@ typedef enum {
VIR_ARCH_LAST,
} virArch;
# define ARCH_IS_X86(arch) ((arch) == VIR_ARCH_X86_64 ||\
(arch) == VIR_ARCH_I686)
#define ARCH_IS_X86(arch) ((arch) == VIR_ARCH_X86_64 ||\
(arch) == VIR_ARCH_I686)
# define ARCH_IS_PPC(arch) ((arch) == VIR_ARCH_PPC ||\
(arch) == VIR_ARCH_PPCLE ||\
(arch) == VIR_ARCH_PPC64 ||\
(arch) == VIR_ARCH_PPC64LE ||\
(arch) == VIR_ARCH_PPCEMB)
#define ARCH_IS_PPC(arch) ((arch) == VIR_ARCH_PPC ||\
(arch) == VIR_ARCH_PPCLE ||\
(arch) == VIR_ARCH_PPC64 ||\
(arch) == VIR_ARCH_PPC64LE ||\
(arch) == VIR_ARCH_PPCEMB)
# define ARCH_IS_PPC64(arch) ((arch) == VIR_ARCH_PPC64 ||\
(arch) == VIR_ARCH_PPC64LE)
#define ARCH_IS_PPC64(arch) ((arch) == VIR_ARCH_PPC64 ||\
(arch) == VIR_ARCH_PPC64LE)
# define ARCH_IS_ARM(arch) ((arch) == VIR_ARCH_ARMV6L ||\
(arch) == VIR_ARCH_ARMV7L ||\
(arch) == VIR_ARCH_ARMV7B ||\
(arch) == VIR_ARCH_AARCH64)
#define ARCH_IS_ARM(arch) ((arch) == VIR_ARCH_ARMV6L ||\
(arch) == VIR_ARCH_ARMV7L ||\
(arch) == VIR_ARCH_ARMV7B ||\
(arch) == VIR_ARCH_AARCH64)
# define ARCH_IS_RISCV(arch) ((arch) == VIR_ARCH_RISCV32 ||\
(arch) == VIR_ARCH_RISCV64)
#define ARCH_IS_RISCV(arch) ((arch) == VIR_ARCH_RISCV32 ||\
(arch) == VIR_ARCH_RISCV64)
# define ARCH_IS_S390(arch) ((arch) == VIR_ARCH_S390 ||\
(arch) == VIR_ARCH_S390X)
#define ARCH_IS_S390(arch) ((arch) == VIR_ARCH_S390 ||\
(arch) == VIR_ARCH_S390X)
typedef enum {
VIR_ARCH_LITTLE_ENDIAN,
......@@ -107,5 +106,3 @@ const char *virArchToString(virArch arch);
virArch virArchFromString(const char *name);
virArch virArchFromHost(void);
#endif /* LIBVIRT_VIRARCH_H */
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册