kconfig: define architecture as a kconfig variable

Do not depend on environment variables and use a kconfig variable
for defining the architecture.

In addition, remove the X86_32 variable, it just duplicates X86 for
not good reason, at least until start supporting MCUs with 64bit.

Change-Id: Ia001db81ed007e6a43f34506fed9be1345b88a4b
Signed-off-by: Anas Nashif <anas.nashif@intel.com>
This commit is contained in:
Anas Nashif 2015-10-09 06:20:52 -04:00
commit 77ba3c3b8b
41 changed files with 112 additions and 107 deletions

View file

@ -15,24 +15,17 @@
# See the License for the specific language governing permissions and # See the License for the specific language governing permissions and
# limitations under the License. # limitations under the License.
# #
config SRCARCH
string
option env="SRCARCH"
source "arch/$SRCARCH/Kconfig"
config ARCH
string
option env="ARCH"
config KERNELVERSION config KERNELVERSION
string string
option env="KERNELVERSION" option env="KERNELVERSION"
config DEFCONFIG_LIST source "arch/Kconfig"
string
option defconfig_list source "kernel/Kconfig"
default "$ARCH_DEFCONFIG"
default "arch/$ARCH/defconfig" source "drivers/Kconfig"
source "net/Kconfig"
source "misc/Kconfig"

View file

@ -18,3 +18,29 @@
# #
choice
prompt "Architecture"
default X86
config ARC
bool "ARC architecture"
config ARM
bool "ARM architecture"
config X86
bool "x86 architecture"
endchoice
config ARCH
string
help
System architecture string.
config SOC
string
help
SOC being used.
source "arch/*/Kconfig"

View file

@ -15,17 +15,15 @@
# See the License for the specific language governing permissions and # See the License for the specific language governing permissions and
# limitations under the License. # limitations under the License.
# #
config ARC menu "ARC architecture"
def_bool y depends on ARC
config ARCH
default "arc"
config ARCH_DEFCONFIG config ARCH_DEFCONFIG
string string
default "arch/arc/defconfig" default "arch/arc/defconfig"
source "kernel/Kconfig"
source "misc/Kconfig"
choice choice
prompt "Platform Selection" prompt "Platform Selection"
@ -41,7 +39,7 @@ config CPU_ARCEM4
default y default y
select CPU_ARCV2 select CPU_ARCV2
help help
This option signifies the use of an ARC EM4 CPU This option signifies the use of an ARC EM4 CPU
endmenu endmenu
@ -50,7 +48,6 @@ menu "ARCv2 Family Options"
config CPU_ARCV2 config CPU_ARCV2
bool bool
default y default y
select ARC
help help
This option signifies the use of a CPU of the ARCv2 family. This option signifies the use of a CPU of the ARCv2 family.
@ -249,7 +246,4 @@ endmenu
source "arch/arc/platforms/*/Kconfig" source "arch/arc/platforms/*/Kconfig"
source "drivers/Kconfig" endmenu
source "net/Kconfig"

View file

@ -15,16 +15,17 @@
# See the License for the specific language governing permissions and # See the License for the specific language governing permissions and
# limitations under the License. # limitations under the License.
# #
config ARM
def_bool y
menu "ARM architecture"
depends on ARM
config ARCH
default "arm"
config ARCH_DEFCONFIG config ARCH_DEFCONFIG
string string
default "arch/arm/defconfig" default "arch/arm/defconfig"
source "kernel/Kconfig"
source "misc/Kconfig"
menu "General Platform Configuration" menu "General Platform Configuration"
@ -72,6 +73,4 @@ endmenu
source "arch/arm/platforms/*/Kconfig" source "arch/arm/platforms/*/Kconfig"
source "drivers/Kconfig" endmenu
source "net/Kconfig"

View file

@ -16,14 +16,11 @@
# limitations under the License. # limitations under the License.
# #
config X86_32 menu "x86 architecture"
def_bool y depends on X86
config ARCH_DEFCONFIG config ARCH
string default "x86"
default "arch/x86/defconfig"
source "kernel/Kconfig"
menu "X86 Platform Configuration options" menu "X86 Platform Configuration options"
@ -273,8 +270,4 @@ endmenu
source "arch/x86/platforms/*/Kconfig" source "arch/x86/platforms/*/Kconfig"
source "drivers/Kconfig" endmenu
source "net/Kconfig"
source "misc/Kconfig"

View file

@ -1,4 +1,4 @@
CONFIG_X86_32=y CONFIG_X86=y
CONFIG_PLATFORM_QUARK_SE_X86=y CONFIG_PLATFORM_QUARK_SE_X86=y
CONFIG_CPU_MINUTEIA=y CONFIG_CPU_MINUTEIA=y
CONFIG_CONSOLE=y CONFIG_CONSOLE=y

View file

@ -1,4 +1,4 @@
CONFIG_X86_32=y CONFIG_X86=y
CONFIG_PLATFORM_IA32=y CONFIG_PLATFORM_IA32=y
CONFIG_CPU_ATOM=y CONFIG_CPU_ATOM=y
CONFIG_IA32_LEGACY_IO_PORTS=y CONFIG_IA32_LEGACY_IO_PORTS=y

View file

@ -1,4 +1,4 @@
CONFIG_X86_32=y CONFIG_X86=y
CONFIG_PLATFORM_IA32=y CONFIG_PLATFORM_IA32=y
CONFIG_CPU_MINUTEIA=y CONFIG_CPU_MINUTEIA=y
CONFIG_IA32_LEGACY_IO_PORTS=y CONFIG_IA32_LEGACY_IO_PORTS=y

View file

@ -1,6 +1,6 @@
CONFIG_NANO_TIMERS=y CONFIG_NANO_TIMERS=y
CONFIG_NANO_TIMEOUTS=y CONFIG_NANO_TIMEOUTS=y
CONFIG_X86_32=y CONFIG_X86=y
CONFIG_PLATFORM_GALILEO=y CONFIG_PLATFORM_GALILEO=y
CONFIG_CPU_MINUTEIA=y CONFIG_CPU_MINUTEIA=y
CONFIG_PCI_LEGACY_BRIDGE=y CONFIG_PCI_LEGACY_BRIDGE=y

View file

@ -1,4 +1,4 @@
CONFIG_X86_32=y CONFIG_X86=y
CONFIG_PLATFORM_QUARK_D2000=y CONFIG_PLATFORM_QUARK_D2000=y
CONFIG_CPU_MINUTEIA=y CONFIG_CPU_MINUTEIA=y
CONFIG_IDT_NUM_VECTORS=64 CONFIG_IDT_NUM_VECTORS=64

View file

@ -1,4 +1,4 @@
CONFIG_X86_32=y CONFIG_X86=y
CONFIG_PLATFORM_QUARK_SE_X86=y CONFIG_PLATFORM_QUARK_SE_X86=y
CONFIG_CPU_MINUTEIA=y CONFIG_CPU_MINUTEIA=y
CONFIG_CONSOLE=y CONFIG_CONSOLE=y

View file

@ -1,4 +1,4 @@
CONFIG_X86_32=y CONFIG_X86=y
CONFIG_PLATFORM_IA32=y CONFIG_PLATFORM_IA32=y
CONFIG_CPU_MINUTEIA=y CONFIG_CPU_MINUTEIA=y
CONFIG_HPET_TIMER=y CONFIG_HPET_TIMER=y

View file

@ -19,7 +19,7 @@
#ifndef _ASM_INLINE_H #ifndef _ASM_INLINE_H
#define _ASM_INLINE_H #define _ASM_INLINE_H
#if !defined(CONFIG_X86_32) #if !defined(CONFIG_X86)
#error The arch/x86/include/asm_inline.h is only for x86 architecture #error The arch/x86/include/asm_inline.h is only for x86 architecture
#endif #endif

View file

@ -26,7 +26,7 @@ Interrupt stuff, abstracted across CPU architectures.
#define _IRQ_TEST_COMMON__H_ #define _IRQ_TEST_COMMON__H_
#if defined(CONFIG_X86_32) #if defined(CONFIG_X86)
#define IRQ_PRIORITY 3 #define IRQ_PRIORITY 3
#elif defined(CONFIG_ARM) #elif defined(CONFIG_ARM)
#if defined(CONFIG_CPU_CORTEX_M) #if defined(CONFIG_CPU_CORTEX_M)
@ -44,7 +44,7 @@ Interrupt stuff, abstracted across CPU architectures.
#error NUM_SW_IRQS only supports 1 or 2 IRQs #error NUM_SW_IRQS only supports 1 or 2 IRQs
#endif #endif
#if defined(CONFIG_X86_32) #if defined(CONFIG_X86)
static NANO_CPU_INT_STUB_DECL(nanoIntStub1); static NANO_CPU_INT_STUB_DECL(nanoIntStub1);
#if NUM_SW_IRQS >= 2 #if NUM_SW_IRQS >= 2
static NANO_CPU_INT_STUB_DECL(nanoIntStub2); static NANO_CPU_INT_STUB_DECL(nanoIntStub2);
@ -57,7 +57,7 @@ typedef void (*vvfn)(void);
/** Declares a void-void_pointer function pointer to test the ISR. */ /** Declares a void-void_pointer function pointer to test the ISR. */
typedef void (*vvpfn)(void *); typedef void (*vvpfn)(void *);
#if defined(CONFIG_X86_32) #if defined(CONFIG_X86)
/* /*
* Opcode for generating a software interrupt. The ISR associated with each * Opcode for generating a software interrupt. The ISR associated with each
* of these software interrupts will call either nano_isr_lifo_put() or * of these software interrupts will call either nano_isr_lifo_put() or
@ -120,7 +120,7 @@ static int initIRQ
struct isrInitInfo *i struct isrInitInfo *i
) )
{ {
#if defined(CONFIG_X86_32) #if defined(CONFIG_X86)
int vector; /* vector to which interrupt is connected */ int vector; /* vector to which interrupt is connected */
if (i->isr[0]) if (i->isr[0])
@ -159,7 +159,7 @@ static int initIRQ
irq_enable (1); irq_enable (1);
} }
#endif /* CONFIG_CPU_CORTEX_M */ #endif /* CONFIG_CPU_CORTEX_M */
#endif /* CONFIG_X86_32 */ #endif /* CONFIG_X86 */
return 0; return 0;
} }

View file

@ -22,7 +22,7 @@
#define _ASMLANGUAGE #define _ASMLANGUAGE
#ifdef CONFIG_X86_32 #ifdef CONFIG_X86
#include <arch/x86/asm.h> #include <arch/x86/asm.h>
#include <drivers/ioapic.h> #include <drivers/ioapic.h>
#endif #endif

View file

@ -22,7 +22,7 @@
#define _ASMLANGUAGE #define _ASMLANGUAGE
#ifdef CONFIG_X86_32 #ifdef CONFIG_X86
#include <arch/x86/asm.h> #include <arch/x86/asm.h>
#include <drivers/ioapic.h> #include <drivers/ioapic.h>
#endif #endif

View file

@ -22,7 +22,7 @@
#define _ASMLANGUAGE #define _ASMLANGUAGE
#ifdef CONFIG_X86_32 #ifdef CONFIG_X86
#include <arch/x86/asm.h> #include <arch/x86/asm.h>
#include <drivers/ioapic.h> #include <drivers/ioapic.h>
#endif #endif

View file

@ -22,7 +22,7 @@
#define _ASMLANGUAGE #define _ASMLANGUAGE
#ifdef CONFIG_X86_32 #ifdef CONFIG_X86
#include <arch/x86/asm.h> #include <arch/x86/asm.h>
#include <drivers/ioapic.h> #include <drivers/ioapic.h>
#endif #endif

View file

@ -23,7 +23,7 @@ config LOAPIC
bool "LOAPIC" bool "LOAPIC"
default n default n
select IOAPIC select IOAPIC
depends on X86_32 depends on X86
help help
This option selects local APIC as the interrupt controller. This option selects local APIC as the interrupt controller.
@ -77,7 +77,7 @@ config IOAPIC_NUM_RTES
config MVIC config MVIC
bool "Intel Quark D2000 Interrupt Controller (MVIC)" bool "Intel Quark D2000 Interrupt Controller (MVIC)"
default n default n
depends on X86_32 depends on X86
help help
The MVIC (Intel Quark microcontroller D2000 Interrupt Controller) is The MVIC (Intel Quark microcontroller D2000 Interrupt Controller) is
configured by default to support 32 external interrupt lines. Unlike the configured by default to support 32 external interrupt lines. Unlike the

View file

@ -16,7 +16,7 @@
#define _ASMLANGUAGE #define _ASMLANGUAGE
#ifdef CONFIG_X86_32 #ifdef CONFIG_X86
#include <arch/x86/asm.h> #include <arch/x86/asm.h>
#include <drivers/ioapic.h> #include <drivers/ioapic.h>
#endif #endif

View file

@ -18,11 +18,11 @@
menu "PCI Settings" menu "PCI Settings"
depends on X86_32 depends on X86
config PCI config PCI
bool "Enable PCI" bool "Enable PCI"
default n default n
depends on X86_32 depends on X86
help help
This options enables support of PCI bus for device drivers. This options enables support of PCI bus for device drivers.

View file

@ -40,7 +40,7 @@ config TEST_RANDOM_GENERATOR
config X86_TSC_RANDOM_GENERATOR config X86_TSC_RANDOM_GENERATOR
bool bool
prompt "x86 timestamp counter based number generator" prompt "x86 timestamp counter based number generator"
depends on TEST_RANDOM_GENERATOR && X86_32 depends on TEST_RANDOM_GENERATOR && X86
default y default y
help help
This options enables number generator based on timestamp counter This options enables number generator based on timestamp counter

View file

@ -15,7 +15,7 @@
*/ */
#define _ASMLANGUAGE #define _ASMLANGUAGE
#ifdef CONFIG_X86_32 #ifdef CONFIG_X86
#include <arch/x86/asm.h> #include <arch/x86/asm.h>
#include <drivers/ioapic.h> #include <drivers/ioapic.h>
#endif #endif

View file

@ -22,7 +22,7 @@ menu "Timer Drivers"
config HPET_TIMER config HPET_TIMER
bool "HPET timer" bool "HPET timer"
default n default n
depends on X86_32 depends on X86
select IOAPIC select IOAPIC
select LOAPIC select LOAPIC
help help
@ -95,7 +95,7 @@ endchoice
config LOAPIC_TIMER config LOAPIC_TIMER
bool "LOAPIC timer" bool "LOAPIC timer"
depends on (LOAPIC || MVIC) && X86_32 depends on (LOAPIC || MVIC) && X86
default n default n
help help
This option selects LOAPIC timer as a system timer. This option selects LOAPIC timer as a system timer.
@ -116,7 +116,7 @@ config LOAPIC_TIMER_IRQ_PRIORITY
config LOAPIC_TIMER_DIVIDER_UNSUPPORTED config LOAPIC_TIMER_DIVIDER_UNSUPPORTED
bool "LOAPIC timer divider unsupported" bool "LOAPIC timer divider unsupported"
depends on LOAPIC_TIMER && MVIC && X86_32 depends on LOAPIC_TIMER && MVIC && X86
default n default n
help help
This option selects if Local Apic Timer divider register is supported. This option selects if Local Apic Timer divider register is supported.

View file

@ -19,7 +19,7 @@
#ifndef __ARCHCPU_H__ #ifndef __ARCHCPU_H__
#define __ARCHCPU_H__ #define __ARCHCPU_H__
#if defined(CONFIG_X86_32) #if defined(CONFIG_X86)
#include <arch/x86/arch.h> #include <arch/x86/arch.h>
#elif defined(CONFIG_ARM) #elif defined(CONFIG_ARM)
#include <arch/arm/arch.h> #include <arch/arm/arch.h>

View file

@ -33,7 +33,7 @@
#include <sections.h> #include <sections.h>
/* include platform dependent linker-defs */ /* include platform dependent linker-defs */
#ifdef CONFIG_X86_32 #ifdef CONFIG_X86
#include <arch/x86/linker-defs-arch.h> #include <arch/x86/linker-defs-arch.h>
#elif defined(CONFIG_ARM) #elif defined(CONFIG_ARM)
/* Nothing yet to include */ /* Nothing yet to include */
@ -71,7 +71,7 @@
DEVICE_INIT_LEVEL(APPLICATION) \ DEVICE_INIT_LEVEL(APPLICATION) \
__device_init_end = .; \ __device_init_end = .; \
#ifdef CONFIG_X86_32 /* LINKER FILES: defines used by linker script */ #ifdef CONFIG_X86 /* LINKER FILES: defines used by linker script */
/* Should be moved to linker-common-defs.h */ /* Should be moved to linker-common-defs.h */
#if defined(CONFIG_XIP) #if defined(CONFIG_XIP)
#define ROMABLE_REGION ROM #define ROMABLE_REGION ROM

View file

@ -37,7 +37,7 @@
/* Various text section names */ /* Various text section names */
#define TEXT text #define TEXT text
#if defined(CONFIG_X86_32) #if defined(CONFIG_X86)
#define TEXT_START text_start /* beginning of TEXT section */ #define TEXT_START text_start /* beginning of TEXT section */
#else #else
#define TEXT_START text /* beginning of TEXT section */ #define TEXT_START text /* beginning of TEXT section */

View file

@ -69,7 +69,7 @@
#ifdef _ASMLANGUAGE #ifdef _ASMLANGUAGE
#ifdef CONFIG_X86_32 #ifdef CONFIG_X86
#ifdef PERF_OPT #ifdef PERF_OPT
#define PERFOPT_ALIGN .balign 16 #define PERFOPT_ALIGN .balign 16

View file

@ -253,7 +253,7 @@ A##a:
",%B0" \ ",%B0" \
"\n\t.type\t" #name ",%%object" : : "n"(~(value))) "\n\t.type\t" #name ",%%object" : : "n"(~(value)))
#elif defined(CONFIG_X86_32) || defined(CONFIG_ARC) #elif defined(CONFIG_X86) || defined(CONFIG_ARC)
#define GEN_ABSOLUTE_SYM(name, value) \ #define GEN_ABSOLUTE_SYM(name, value) \
__asm__(".globl\t" #name "\n\t.equ\t" #name \ __asm__(".globl\t" #name "\n\t.equ\t" #name \

View file

@ -73,7 +73,7 @@ static struct task_irq_info task_irq_object[MAX_TASK_IRQS] = {
/* architecture-specific */ /* architecture-specific */
#if defined(CONFIG_X86_32) #if defined(CONFIG_X86)
#define RELEASE_VECTOR(v) _IntVecMarkFree(v) #define RELEASE_VECTOR(v) _IntVecMarkFree(v)

View file

@ -199,13 +199,13 @@ static void nano_init(struct tcs *dummyOutContext)
extern void *__stack_chk_guard; extern void *__stack_chk_guard;
#if defined(CONFIG_X86_32) #if defined(CONFIG_X86)
#define _MOVE_INSTR "movl " #define _MOVE_INSTR "movl "
#elif defined(CONFIG_ARM) #elif defined(CONFIG_ARM)
#define _MOVE_INSTR "str " #define _MOVE_INSTR "str "
#else #else
#error "Unknown Architecture type" #error "Unknown Architecture type"
#endif /* CONFIG_X86_32 */ #endif /* CONFIG_X86 */
#define STACK_CANARY_INIT() \ #define STACK_CANARY_INIT() \
do { \ do { \

View file

@ -211,7 +211,7 @@ endmenu
config BOOTLOADER_KEXEC config BOOTLOADER_KEXEC
bool bool
prompt "Boot using Linux kexec() system call" prompt "Boot using Linux kexec() system call"
depends on X86_32 depends on X86
default n default n
help help
This option signifies that Linux boots the kernel using kexec system call This option signifies that Linux boots the kernel using kexec system call
@ -221,7 +221,7 @@ config BOOTLOADER_UNKNOWN
bool bool
prompt "Generic boot loader support" prompt "Generic boot loader support"
default n default n
depends on X86_32 depends on X86
help help
This option signifies that the target has a generic bootloader This option signifies that the target has a generic bootloader
or that it supports multiple ways of booting and it isn't clear or that it supports multiple ways of booting and it isn't clear

View file

@ -25,7 +25,7 @@ Interrupt stuff, abstracted across CPU architectures.
#ifndef _IRQ_TEST_COMMON__H_ #ifndef _IRQ_TEST_COMMON__H_
#define _IRQ_TEST_COMMON__H_ #define _IRQ_TEST_COMMON__H_
#if defined(CONFIG_X86_32) #if defined(CONFIG_X86)
#define IRQ_PRIORITY 3 #define IRQ_PRIORITY 3
#elif defined(CONFIG_ARM) #elif defined(CONFIG_ARM)
#if defined(CONFIG_CPU_CORTEX_M) #if defined(CONFIG_CPU_CORTEX_M)
@ -46,7 +46,7 @@ Interrupt stuff, abstracted across CPU architectures.
typedef void (*vvfn)(void); /* void-void function pointer */ typedef void (*vvfn)(void); /* void-void function pointer */
typedef void (*vvpfn)(void *); /* void-void_pointer function pointer */ typedef void (*vvpfn)(void *); /* void-void_pointer function pointer */
#if defined(CONFIG_X86_32) #if defined(CONFIG_X86)
/* /*
* Opcode for generating a software interrupt. The ISR associated with each * Opcode for generating a software interrupt. The ISR associated with each
* of these software interrupts will call either nano_isr_lifo_put() or * of these software interrupts will call either nano_isr_lifo_put() or
@ -98,7 +98,7 @@ struct isrInitInfo {
static int initIRQ(struct isrInitInfo *i) static int initIRQ(struct isrInitInfo *i)
{ {
#if defined(CONFIG_X86_32) #if defined(CONFIG_X86)
int vector; /* vector to which interrupt is connected */ int vector; /* vector to which interrupt is connected */
if (i->isr[0]) { if (i->isr[0]) {
@ -131,7 +131,7 @@ static int initIRQ(struct isrInitInfo *i)
irq_enable(1); irq_enable(1);
} }
#endif /* CONFIG_CPU_CORTEX_M */ #endif /* CONFIG_CPU_CORTEX_M */
#endif /* CONFIG_X86_32 */ #endif /* CONFIG_X86 */
return 0; return 0;
} }

View file

@ -19,7 +19,7 @@
#ifndef _TEST_ASM_INLINE_GCC_H #ifndef _TEST_ASM_INLINE_GCC_H
#define _TEST_ASM_INLINE_GCC_H #define _TEST_ASM_INLINE_GCC_H
#if !defined(__GNUC__) || !defined(CONFIG_X86_32) #if !defined(__GNUC__) || !defined(CONFIG_X86)
#error test_asm_inline_gcc.h goes only with x86 GCC #error test_asm_inline_gcc.h goes only with x86 GCC
#endif #endif

View file

@ -19,7 +19,7 @@
#ifndef _TEST_ASM_INLINE_GCC_H #ifndef _TEST_ASM_INLINE_GCC_H
#define _TEST_ASM_INLINE_GCC_H #define _TEST_ASM_INLINE_GCC_H
#if !defined(__GNUC__) || !defined(CONFIG_X86_32) #if !defined(__GNUC__) || !defined(CONFIG_X86)
#error test_asm_inline_gcc.h goes only with x86 GCC #error test_asm_inline_gcc.h goes only with x86 GCC
#endif #endif

View file

@ -19,7 +19,7 @@
#ifndef _TEST_ASM_INLINE_GCC_H #ifndef _TEST_ASM_INLINE_GCC_H
#define _TEST_ASM_INLINE_GCC_H #define _TEST_ASM_INLINE_GCC_H
#if !defined(__GNUC__) || !defined(CONFIG_X86_32) #if !defined(__GNUC__) || !defined(CONFIG_X86)
#error test_asm_inline_gcc.h goes only with x86 GCC #error test_asm_inline_gcc.h goes only with x86 GCC
#endif #endif

View file

@ -26,7 +26,7 @@
#include <stdint.h> #include <stdint.h>
#if defined(CONFIG_X86_32) #if defined(CONFIG_X86)
static void genInt0(void) static void genInt0(void)
{ {

View file

@ -37,7 +37,7 @@ exercises the task_irq_free() API.
#define DEV4_ID 3 #define DEV4_ID 3
#define DEV5_ID 4 #define DEV5_ID 4
#if defined(CONFIG_X86_32) #if defined(CONFIG_X86)
#define DEV1_IRQ 8 #define DEV1_IRQ 8
#define DEV2_IRQ 14 #define DEV2_IRQ 14
#define DEV3_IRQ 32 #define DEV3_IRQ 32

View file

@ -42,7 +42,7 @@ extern int32_t _sys_idle_threshold_ticks;
* timestamp routines. * timestamp routines.
*/ */
#if defined(CONFIG_X86_32) #if defined(CONFIG_X86)
typedef uint64_t _timer_res_t; typedef uint64_t _timer_res_t;
#define _TIMER_ZERO 0ULL #define _TIMER_ZERO 0ULL
@ -120,7 +120,7 @@ void ticklessTestTask(void)
} }
cal_tsc /= CAL_REPS; cal_tsc /= CAL_REPS;
#if defined(CONFIG_X86_32) #if defined(CONFIG_X86)
printk("Calibrated time stamp period = 0x%x%x\n", printk("Calibrated time stamp period = 0x%x%x\n",
(uint32_t)(cal_tsc >> 32), (uint32_t)(cal_tsc & 0xFFFFFFFFLL)); (uint32_t)(cal_tsc >> 32), (uint32_t)(cal_tsc & 0xFFFFFFFFLL));
#elif defined(CONFIG_ARM) #elif defined(CONFIG_ARM)
@ -157,7 +157,7 @@ void ticklessTestTask(void)
printk("end ticks : %d\n", end_ticks); printk("end ticks : %d\n", end_ticks);
printk("diff ticks : %d\n", diff_ticks); printk("diff ticks : %d\n", diff_ticks);
#if defined(CONFIG_X86_32) #if defined(CONFIG_X86)
printk("diff time stamp: 0x%x%x\n", printk("diff time stamp: 0x%x%x\n",
(uint32_t)(diff_tsc >> 32), (uint32_t)(diff_tsc & 0xFFFFFFFFULL)); (uint32_t)(diff_tsc >> 32), (uint32_t)(diff_tsc & 0xFFFFFFFFULL));
printk("Cal time stamp: 0x%x%x\n", printk("Cal time stamp: 0x%x%x\n",

View file

@ -19,7 +19,7 @@
#ifndef _TEST_ASM_INLINE_GCC_H #ifndef _TEST_ASM_INLINE_GCC_H
#define _TEST_ASM_INLINE_GCC_H #define _TEST_ASM_INLINE_GCC_H
#if !defined(__GNUC__) || !defined(CONFIG_X86_32) #if !defined(__GNUC__) || !defined(CONFIG_X86)
#error test_asm_inline_gcc.h goes only with x86 GCC #error test_asm_inline_gcc.h goes only with x86 GCC
#endif #endif

View file

@ -19,7 +19,7 @@
#ifndef _TEST_ASM_INLINE_GCC_H #ifndef _TEST_ASM_INLINE_GCC_H
#define _TEST_ASM_INLINE_GCC_H #define _TEST_ASM_INLINE_GCC_H
#if !defined(__GNUC__) || !defined(CONFIG_X86_32) #if !defined(__GNUC__) || !defined(CONFIG_X86)
#error test_asm_inline_gcc.h goes only with x86 GCC #error test_asm_inline_gcc.h goes only with x86 GCC
#endif #endif