diff --git a/arch/x86/core/reboot_rst_cnt.c b/arch/x86/core/reboot_rst_cnt.c index bcb77ce562c..b8100ea26f1 100644 --- a/arch/x86/core/reboot_rst_cnt.c +++ b/arch/x86/core/reboot_rst_cnt.c @@ -13,11 +13,18 @@ #include #include +/* reboot through Reset Control Register (I/O port 0xcf9) */ + +#define X86_RST_CNT_REG 0xcf9 +#define X86_RST_CNT_SYS_RST 0x02 +#define X86_RST_CNT_CPU_RST 0x4 +#define X86_RST_CNT_FULL_RST 0x08 + static inline void cold_reboot(void) { - u8_t reset_value = SYS_X86_RST_CNT_CPU_RST | SYS_X86_RST_CNT_SYS_RST | - SYS_X86_RST_CNT_FULL_RST; - sys_out8(reset_value, SYS_X86_RST_CNT_REG); + u8_t reset_value = X86_RST_CNT_CPU_RST | X86_RST_CNT_SYS_RST | + X86_RST_CNT_FULL_RST; + sys_out8(reset_value, X86_RST_CNT_REG); } void sys_arch_reboot(int type) diff --git a/include/arch/x86/arch.h b/include/arch/x86/arch.h index 54342bd172d..011e0ffeb6d 100644 --- a/include/arch/x86/arch.h +++ b/include/arch/x86/arch.h @@ -678,13 +678,6 @@ void z_x86_reset_pages(void *start, size_t size); #endif /* !_ASMLANGUAGE */ -/* reboot through Reset Control Register (I/O port 0xcf9) */ - -#define SYS_X86_RST_CNT_REG 0xcf9 -#define SYS_X86_RST_CNT_SYS_RST 0x02 -#define SYS_X86_RST_CNT_CPU_RST 0x4 -#define SYS_X86_RST_CNT_FULL_RST 0x08 - #ifdef __cplusplus } #endif