test: error_hook: check for exact SoCs instead of entire ARC EM family

The quirky behavior when accessing of 0x0 address is related to
exact ARC SoCs/boards and not to entire ARC EM CPUs family. So
check for exact SoCs configs (CONFIG_SOC_ARC_IOT and CONFIG_SOC_NSIM)
instead of checking against CONFIG_CPU_ARCEM.

Signed-off-by: Eugeniy Paltsev <Eugeniy.Paltsev@synopsys.com>
This commit is contained in:
Eugeniy Paltsev 2021-03-17 22:17:57 +03:00 committed by Anas Nashif
commit 9db47e156d

View file

@ -51,7 +51,7 @@ static void trigger_fault_illegal_instruction(void)
static void trigger_fault_access(void) static void trigger_fault_access(void)
{ {
#if defined(CONFIG_CPU_ARCEM) || defined(CONFIG_CPU_CORTEX_M) #if defined(CONFIG_SOC_ARC_IOT) || defined(CONFIG_SOC_NSIM) || defined(CONFIG_CPU_CORTEX_M)
/* For iotdk and ARC/nSIM, nSIM simulates full address space of memory, /* For iotdk and ARC/nSIM, nSIM simulates full address space of memory,
* so all accesses outside of CCMs are valid and access to 0x0 address * so all accesses outside of CCMs are valid and access to 0x0 address
* doesn't generate any exception.So we access it 0XFFFFFFFF instead to * doesn't generate any exception.So we access it 0XFFFFFFFF instead to