Skip to content
Snippets Groups Projects
Commit e709b43f authored by Gregory Nutt's avatar Gregory Nutt
Browse files

Addition cleanup after last switch from BASEPRI to PRIMASK for Cortex-M0

parent 5ec812ff
Branches
Tags
No related merge requests found
......@@ -90,18 +90,14 @@
int up_hardfault(int irq, FAR void *context)
{
#if defined(CONFIG_DEBUG_HARDFAULT) || !defined(CONFIG_ARMV7M_USEBASEPRI)
uint32_t *regs = (uint32_t*)context;
#endif
/* Get the value of the program counter where the fault occurred */
#ifndef CONFIG_ARMV7M_USEBASEPRI
uint16_t *pc = (uint16_t*)regs[REG_PC] - 1;
/* Check if the pc lies in known FLASH memory.
* REVISIT: What if the PC lies in "unknown" external memory? Best
* use the BASEPRI register if you have external memory.
* REVISIT: What if the PC lies in "unknown" external memory?
*/
#ifdef CONFIG_NUTTX_KERNEL
......@@ -135,7 +131,6 @@ int up_hardfault(int irq, FAR void *context)
return up_svcall(irq, context);
}
}
#endif
#if defined(CONFIG_DEBUG_HARDFAULT)
/* Dump some hard fault info */
......
......@@ -230,12 +230,6 @@ void up_irqinitialize(void)
irq_attach(KL_IRQ_SVCALL, up_svcall);
irq_attach(KL_IRQ_HARDFAULT, up_hardfault);
/* Set the priority of the SVCall interrupt */
#ifdef CONFIG_ARCH_IRQPRIO
/* up_prioritize_irq(KL_IRQ_PENDSV, NVIC_SYSH_PRIORITY_MIN); */
#endif
/* Attach all other processor exceptions (except reset and sys tick) */
#ifdef CONFIG_DEBUG
......
......@@ -230,12 +230,6 @@ void up_irqinitialize(void)
irq_attach(NUC_IRQ_SVCALL, up_svcall);
irq_attach(NUC_IRQ_HARDFAULT, up_hardfault);
/* Set the priority of the SVCall interrupt */
#ifdef CONFIG_ARCH_IRQPRIO
/* up_prioritize_irq(NUC_IRQ_PENDSV, NVIC_SYSH_PRIORITY_MIN); */
#endif
/* Attach all other processor exceptions (except reset and sys tick) */
#ifdef CONFIG_DEBUG
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment