* [PATCH 1/8] ARM: add missing volatile in get_cr()
2011-08-08 6:46 ARM: use high vectors if possible Sascha Hauer
@ 2011-08-08 6:46 ` Sascha Hauer
2011-08-08 6:46 ` [PATCH 2/8] ARM mmu: fix arm_create_pte Sascha Hauer
` (7 subsequent siblings)
8 siblings, 0 replies; 12+ messages in thread
From: Sascha Hauer @ 2011-08-08 6:46 UTC (permalink / raw)
To: barebox
Without it, the compiler optimizes away subsequent reads of the
control register.
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
---
arch/arm/include/asm/system.h | 2 +-
1 files changed, 1 insertions(+), 1 deletions(-)
diff --git a/arch/arm/include/asm/system.h b/arch/arm/include/asm/system.h
index 77d6305..1d67492 100644
--- a/arch/arm/include/asm/system.h
+++ b/arch/arm/include/asm/system.h
@@ -59,7 +59,7 @@
static inline unsigned int get_cr(void)
{
unsigned int val;
- asm("mrc p15, 0, %0, c1, c0, 0 @ get CR" : "=r" (val) : : "cc");
+ asm volatile ("mrc p15, 0, %0, c1, c0, 0 @ get CR" : "=r" (val) : : "cc");
return val;
}
--
1.7.5.4
_______________________________________________
barebox mailing list
barebox@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/barebox
^ permalink raw reply [flat|nested] 12+ messages in thread
* [PATCH 2/8] ARM mmu: fix arm_create_pte
2011-08-08 6:46 ARM: use high vectors if possible Sascha Hauer
2011-08-08 6:46 ` [PATCH 1/8] ARM: add missing volatile in get_cr() Sascha Hauer
@ 2011-08-08 6:46 ` Sascha Hauer
2011-08-08 6:46 ` [PATCH 3/8] ARM mmu: use high vectors if possible Sascha Hauer
` (6 subsequent siblings)
8 siblings, 0 replies; 12+ messages in thread
From: Sascha Hauer @ 2011-08-08 6:46 UTC (permalink / raw)
To: barebox
Each section is 1MiB, so we have to shift by 20 to get the ttb
entry corresponding to a section.
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
---
arch/arm/cpu/mmu.c | 2 +-
1 files changed, 1 insertions(+), 1 deletions(-)
diff --git a/arch/arm/cpu/mmu.c b/arch/arm/cpu/mmu.c
index 1f62d61..2f754c8 100644
--- a/arch/arm/cpu/mmu.c
+++ b/arch/arm/cpu/mmu.c
@@ -65,7 +65,7 @@ static u32 *arm_create_pte(unsigned long virt)
table = memalign(0x400, 0x400);
- ttb[virt] = (unsigned long)table | PMD_TYPE_TABLE;
+ ttb[virt >> 20] = (unsigned long)table | PMD_TYPE_TABLE;
for (i = 0; i < 256; i++) {
table[i] = virt | PTE_TYPE_SMALL | PTE_FLAGS_UNCACHED;
--
1.7.5.4
_______________________________________________
barebox mailing list
barebox@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/barebox
^ permalink raw reply [flat|nested] 12+ messages in thread
* [PATCH 3/8] ARM mmu: use high vectors if possible
2011-08-08 6:46 ARM: use high vectors if possible Sascha Hauer
2011-08-08 6:46 ` [PATCH 1/8] ARM: add missing volatile in get_cr() Sascha Hauer
2011-08-08 6:46 ` [PATCH 2/8] ARM mmu: fix arm_create_pte Sascha Hauer
@ 2011-08-08 6:46 ` Sascha Hauer
2011-08-08 6:46 ` [PATCH 4/8] ARM: remove unused exception Sascha Hauer
` (5 subsequent siblings)
8 siblings, 0 replies; 12+ messages in thread
From: Sascha Hauer @ 2011-08-08 6:46 UTC (permalink / raw)
To: barebox
Using high vectors allows us to map a faulting zero page to
catch NULL pointer dereferences.
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
---
arch/arm/cpu/mmu.c | 37 +++++++++++++++++++++++++++++++------
1 files changed, 31 insertions(+), 6 deletions(-)
diff --git a/arch/arm/cpu/mmu.c b/arch/arm/cpu/mmu.c
index 2f754c8..b669349 100644
--- a/arch/arm/cpu/mmu.c
+++ b/arch/arm/cpu/mmu.c
@@ -4,6 +4,7 @@
#include <errno.h>
#include <sizes.h>
#include <asm/memory.h>
+#include <asm/system.h>
static unsigned long *ttb;
@@ -161,22 +162,46 @@ static int arm_mmu_remap_sdram(struct arm_memory *mem)
#define ARM_VECTORS_SIZE (sizeof(u32) * 8 * 2)
/*
- * Allocate a page, map it to the zero page and copy our exception
- * vectors there.
+ * Map vectors and zero page
*/
static void vectors_init(void)
{
- u32 *exc;
+ u32 *exc, *zero = NULL;
void *vectors;
extern unsigned long exception_vectors;
-
- exc = arm_create_pte(0x0);
+ u32 cr;
+
+ cr = get_cr();
+ cr |= CR_V;
+ set_cr(cr);
+ cr = get_cr();
+
+ if (cr & CR_V) {
+ /*
+ * If we can use high vectors, create the second level
+ * page table for the high vectors and zero page
+ */
+ exc = arm_create_pte(0xfff00000);
+ zero = arm_create_pte(0x0);
+
+ /* Set the zero page to faulting */
+ zero[0] = 0;
+ } else {
+ /*
+ * Otherwise map the vectors to the zero page. We have to
+ * live without being able to catch NULL pointer dereferences
+ */
+ exc = arm_create_pte(0x0);
+ }
vectors = xmemalign(PAGE_SIZE, PAGE_SIZE);
memset(vectors, 0, PAGE_SIZE);
memcpy(vectors, &exception_vectors, ARM_VECTORS_SIZE);
- exc[0] = (u32)vectors | PTE_TYPE_SMALL | PTE_FLAGS_CACHED;
+ if (cr & CR_V)
+ exc[256 - 16] = (u32)vectors | PTE_TYPE_SMALL | PTE_FLAGS_CACHED;
+ else
+ exc[0] = (u32)vectors | PTE_TYPE_SMALL | PTE_FLAGS_CACHED;
}
/*
--
1.7.5.4
_______________________________________________
barebox mailing list
barebox@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/barebox
^ permalink raw reply [flat|nested] 12+ messages in thread
* [PATCH 4/8] ARM: remove unused exception
2011-08-08 6:46 ARM: use high vectors if possible Sascha Hauer
` (2 preceding siblings ...)
2011-08-08 6:46 ` [PATCH 3/8] ARM mmu: use high vectors if possible Sascha Hauer
@ 2011-08-08 6:46 ` Sascha Hauer
2011-08-08 6:46 ` [PATCH 5/8] ARM: exceptions: remove unnecessary function declarations Sascha Hauer
` (4 subsequent siblings)
8 siblings, 0 replies; 12+ messages in thread
From: Sascha Hauer @ 2011-08-08 6:46 UTC (permalink / raw)
To: barebox
The exception vector at 0x14 is not used on arm, so no need
to bind this address to a exception handler. Remove the
corresponding code
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
---
arch/arm/cpu/exceptions.S | 5 -----
arch/arm/cpu/interrupts.c | 13 -------------
arch/arm/cpu/start.c | 2 +-
3 files changed, 1 insertions(+), 19 deletions(-)
diff --git a/arch/arm/cpu/exceptions.S b/arch/arm/cpu/exceptions.S
index 4741bb8..a879755 100644
--- a/arch/arm/cpu/exceptions.S
+++ b/arch/arm/cpu/exceptions.S
@@ -136,11 +136,6 @@ data_abort:
bl do_data_abort
.align 5
-.globl not_used
-not_used:
- get_bad_stack
- bad_save_user_regs
- bl do_not_used
.globl irq
.globl fiq
diff --git a/arch/arm/cpu/interrupts.c b/arch/arm/cpu/interrupts.c
index 5168921..68b2931 100644
--- a/arch/arm/cpu/interrupts.c
+++ b/arch/arm/cpu/interrupts.c
@@ -173,19 +173,6 @@ void do_data_abort (struct pt_regs *pt_regs)
}
/**
- * The CPU catches a not-used(?) abort.
- * @param[in] pt_regs Register set content when the accident happens
- *
- * FIXME: What does it mean, why is reset the only solution?
- */
-void do_not_used (struct pt_regs *pt_regs)
-{
- printf ("not used\n");
- show_regs (pt_regs);
- bad_mode ();
-}
-
-/**
* The CPU catches a fast interrupt request.
* @param[in] pt_regs Register set content when the interrupt happens
*
diff --git a/arch/arm/cpu/start.c b/arch/arm/cpu/start.c
index f20ce74..5e09300 100644
--- a/arch/arm/cpu/start.c
+++ b/arch/arm/cpu/start.c
@@ -36,7 +36,7 @@ void __naked __section(.text_entry) exception_vectors(void)
"ldr pc, =software_interrupt\n" /* software interrupt (SWI) */
"ldr pc, =prefetch_abort\n" /* prefetch abort */
"ldr pc, =data_abort\n" /* data abort */
- "ldr pc, =not_used\n" /* (reserved) */
+ "1: bne 1b\n" /* (reserved) */
"ldr pc, =irq\n" /* irq (interrupt) */
"ldr pc, =fiq\n" /* fiq (fast interrupt) */
#else
--
1.7.5.4
_______________________________________________
barebox mailing list
barebox@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/barebox
^ permalink raw reply [flat|nested] 12+ messages in thread
* [PATCH 5/8] ARM: exceptions: remove unnecessary function declarations
2011-08-08 6:46 ARM: use high vectors if possible Sascha Hauer
` (3 preceding siblings ...)
2011-08-08 6:46 ` [PATCH 4/8] ARM: remove unused exception Sascha Hauer
@ 2011-08-08 6:46 ` Sascha Hauer
2011-08-08 6:46 ` [PATCH 6/8] ARM: remove unused irq enable/disable functions Sascha Hauer
` (3 subsequent siblings)
8 siblings, 0 replies; 12+ messages in thread
From: Sascha Hauer @ 2011-08-08 6:46 UTC (permalink / raw)
To: barebox
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
---
arch/arm/cpu/interrupts.c | 8 --------
1 files changed, 0 insertions(+), 8 deletions(-)
diff --git a/arch/arm/cpu/interrupts.c b/arch/arm/cpu/interrupts.c
index 68b2931..a405fae 100644
--- a/arch/arm/cpu/interrupts.c
+++ b/arch/arm/cpu/interrupts.c
@@ -29,14 +29,6 @@
#include <asm/ptrace.h>
#include <asm/unwind.h>
-void do_undefined_instruction (struct pt_regs *pt_regs);
-void do_software_interrupt (struct pt_regs *pt_regs);
-void do_prefetch_abort (struct pt_regs *pt_regs);
-void do_data_abort (struct pt_regs *pt_regs);
-void do_not_used (struct pt_regs *pt_regs);
-void do_fiq (struct pt_regs *pt_regs);
-void do_irq (struct pt_regs *pt_regs);
-
#ifdef CONFIG_USE_IRQ
/* enable IRQ interrupts */
void enable_interrupts (void)
--
1.7.5.4
_______________________________________________
barebox mailing list
barebox@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/barebox
^ permalink raw reply [flat|nested] 12+ messages in thread
* [PATCH 6/8] ARM: remove unused irq enable/disable functions
2011-08-08 6:46 ARM: use high vectors if possible Sascha Hauer
` (4 preceding siblings ...)
2011-08-08 6:46 ` [PATCH 5/8] ARM: exceptions: remove unnecessary function declarations Sascha Hauer
@ 2011-08-08 6:46 ` Sascha Hauer
2011-08-08 6:46 ` [PATCH 7/8] ARM: fix comments in interrupts.c Sascha Hauer
` (2 subsequent siblings)
8 siblings, 0 replies; 12+ messages in thread
From: Sascha Hauer @ 2011-08-08 6:46 UTC (permalink / raw)
To: barebox
We do not have irq support in barebox, so remove the unused interrupt
functions.
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
---
arch/arm/cpu/interrupts.c | 31 -------------------------------
1 files changed, 0 insertions(+), 31 deletions(-)
diff --git a/arch/arm/cpu/interrupts.c b/arch/arm/cpu/interrupts.c
index a405fae..71744ac 100644
--- a/arch/arm/cpu/interrupts.c
+++ b/arch/arm/cpu/interrupts.c
@@ -29,37 +29,6 @@
#include <asm/ptrace.h>
#include <asm/unwind.h>
-#ifdef CONFIG_USE_IRQ
-/* enable IRQ interrupts */
-void enable_interrupts (void)
-{
- unsigned long temp;
- __asm__ __volatile__("mrs %0, cpsr\n"
- "bic %0, %0, #0x80\n"
- "msr cpsr_c, %0"
- : "=r" (temp)
- :
- : "memory");
-}
-
-
-/*
- * disable IRQ/FIQ interrupts
- * returns true if interrupts had been enabled before we disabled them
- */
-int disable_interrupts (void)
-{
- unsigned long old,temp;
- __asm__ __volatile__("mrs %0, cpsr\n"
- "orr %1, %0, #0xc0\n"
- "msr cpsr_c, %1"
- : "=r" (old), "=r" (temp)
- :
- : "memory");
- return(old & 0x80) == 0;
-}
-#endif
-
/**
* FIXME
*/
--
1.7.5.4
_______________________________________________
barebox mailing list
barebox@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/barebox
^ permalink raw reply [flat|nested] 12+ messages in thread
* [PATCH 7/8] ARM: fix comments in interrupts.c
2011-08-08 6:46 ARM: use high vectors if possible Sascha Hauer
` (5 preceding siblings ...)
2011-08-08 6:46 ` [PATCH 6/8] ARM: remove unused irq enable/disable functions Sascha Hauer
@ 2011-08-08 6:46 ` Sascha Hauer
2011-08-08 6:46 ` [PATCH 8/8] ARM: some cleanup " Sascha Hauer
2011-08-08 7:06 ` ARM: use high vectors if possible Jean-Christophe PLAGNIOL-VILLARD
8 siblings, 0 replies; 12+ messages in thread
From: Sascha Hauer @ 2011-08-08 6:46 UTC (permalink / raw)
To: barebox
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
---
arch/arm/cpu/interrupts.c | 12 ++++++------
1 files changed, 6 insertions(+), 6 deletions(-)
diff --git a/arch/arm/cpu/interrupts.c b/arch/arm/cpu/interrupts.c
index 71744ac..0c21bc1 100644
--- a/arch/arm/cpu/interrupts.c
+++ b/arch/arm/cpu/interrupts.c
@@ -97,8 +97,8 @@ void do_undefined_instruction (struct pt_regs *pt_regs)
* The CPU catches a software interrupt
* @param[in] pt_regs Register set content when the interrupt happens
*
- * There is not functione behind this feature. So what to do else than
- * a reset?
+ * There is no function behind this feature. So what to do else than
+ * a reset?
*/
void do_software_interrupt (struct pt_regs *pt_regs)
{
@@ -111,7 +111,7 @@ void do_software_interrupt (struct pt_regs *pt_regs)
* The CPU catches a prefetch abort. That really should not happen!
* @param[in] pt_regs Register set content when the accident happens
*
- * FIXME: What does it mean, why is reset the only solution?
+ * instruction fetch from an unmapped area
*/
void do_prefetch_abort (struct pt_regs *pt_regs)
{
@@ -124,7 +124,7 @@ void do_prefetch_abort (struct pt_regs *pt_regs)
* The CPU catches a data abort. That really should not happen!
* @param[in] pt_regs Register set content when the accident happens
*
- * FIXME: What does it mean, why is reset the only solution?
+ * data fetch from an unmapped area
*/
void do_data_abort (struct pt_regs *pt_regs)
{
@@ -137,7 +137,7 @@ void do_data_abort (struct pt_regs *pt_regs)
* The CPU catches a fast interrupt request.
* @param[in] pt_regs Register set content when the interrupt happens
*
- * FIXME: What does it mean, why is reset the only solution?
+ * We never enable FIQs, so this should not happen
*/
void do_fiq (struct pt_regs *pt_regs)
{
@@ -150,7 +150,7 @@ void do_fiq (struct pt_regs *pt_regs)
* The CPU catches a regular interrupt.
* @param[in] pt_regs Register set content when the interrupt happens
*
- * FIXME: What does it mean, why is reset the only solution?
+ * We never enable interrupts, so this should not happen
*/
void do_irq (struct pt_regs *pt_regs)
{
--
1.7.5.4
_______________________________________________
barebox mailing list
barebox@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/barebox
^ permalink raw reply [flat|nested] 12+ messages in thread
* [PATCH 8/8] ARM: some cleanup in interrupts.c
2011-08-08 6:46 ARM: use high vectors if possible Sascha Hauer
` (6 preceding siblings ...)
2011-08-08 6:46 ` [PATCH 7/8] ARM: fix comments in interrupts.c Sascha Hauer
@ 2011-08-08 6:46 ` Sascha Hauer
2011-08-08 7:06 ` ARM: use high vectors if possible Jean-Christophe PLAGNIOL-VILLARD
8 siblings, 0 replies; 12+ messages in thread
From: Sascha Hauer @ 2011-08-08 6:46 UTC (permalink / raw)
To: barebox
- Don't call panic with "resetting CPU...". Depending on the
configuration the system might also hang.
- panic does not return, so no need to call reset_cpu afterwards
- bundle show_regs and panic into a seperate functions to not have
to call both functions from each exception handler
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
---
arch/arm/cpu/interrupts.c | 43 +++++++++++++++++++++----------------------
1 files changed, 21 insertions(+), 22 deletions(-)
diff --git a/arch/arm/cpu/interrupts.c b/arch/arm/cpu/interrupts.c
index 0c21bc1..3d2077f 100644
--- a/arch/arm/cpu/interrupts.c
+++ b/arch/arm/cpu/interrupts.c
@@ -30,15 +30,6 @@
#include <asm/unwind.h>
/**
- * FIXME
- */
-static void bad_mode (void)
-{
- panic ("Resetting CPU ...\n");
- reset_cpu (0);
-}
-
-/**
* Display current register set content
* @param[in] regs Guess what
*/
@@ -82,6 +73,13 @@ void show_regs (struct pt_regs *regs)
#endif
}
+static void __noreturn do_exception(struct pt_regs *pt_regs)
+{
+ show_regs(pt_regs);
+
+ panic("");
+}
+
/**
* The CPU runs into an undefined instruction. That really should not happen!
* @param[in] pt_regs Register set content when the accident happens
@@ -89,8 +87,7 @@ void show_regs (struct pt_regs *regs)
void do_undefined_instruction (struct pt_regs *pt_regs)
{
printf ("undefined instruction\n");
- show_regs (pt_regs);
- bad_mode ();
+ do_exception(pt_regs);
}
/**
@@ -103,8 +100,7 @@ void do_undefined_instruction (struct pt_regs *pt_regs)
void do_software_interrupt (struct pt_regs *pt_regs)
{
printf ("software interrupt\n");
- show_regs (pt_regs);
- bad_mode ();
+ do_exception(pt_regs);
}
/**
@@ -116,8 +112,7 @@ void do_software_interrupt (struct pt_regs *pt_regs)
void do_prefetch_abort (struct pt_regs *pt_regs)
{
printf ("prefetch abort\n");
- show_regs (pt_regs);
- bad_mode ();
+ do_exception(pt_regs);
}
/**
@@ -128,9 +123,15 @@ void do_prefetch_abort (struct pt_regs *pt_regs)
*/
void do_data_abort (struct pt_regs *pt_regs)
{
- printf ("data abort\n");
- show_regs (pt_regs);
- bad_mode ();
+ u32 far;
+
+ asm volatile ("mrc p15, 0, %0, c6, c0, 0" : "=r" (far) : : "cc");
+
+ printf("unable to handle %s at address 0x%08x\n",
+ far < PAGE_SIZE ? "NULL pointer dereference" :
+ "paging request", far);
+
+ do_exception(pt_regs);
}
/**
@@ -142,8 +143,7 @@ void do_data_abort (struct pt_regs *pt_regs)
void do_fiq (struct pt_regs *pt_regs)
{
printf ("fast interrupt request\n");
- show_regs (pt_regs);
- bad_mode ();
+ do_exception(pt_regs);
}
/**
@@ -155,6 +155,5 @@ void do_fiq (struct pt_regs *pt_regs)
void do_irq (struct pt_regs *pt_regs)
{
printf ("interrupt request\n");
- show_regs (pt_regs);
- bad_mode ();
+ do_exception(pt_regs);
}
--
1.7.5.4
_______________________________________________
barebox mailing list
barebox@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/barebox
^ permalink raw reply [flat|nested] 12+ messages in thread
* Re: ARM: use high vectors if possible
2011-08-08 6:46 ARM: use high vectors if possible Sascha Hauer
` (7 preceding siblings ...)
2011-08-08 6:46 ` [PATCH 8/8] ARM: some cleanup " Sascha Hauer
@ 2011-08-08 7:06 ` Jean-Christophe PLAGNIOL-VILLARD
2011-08-08 7:32 ` Sascha Hauer
8 siblings, 1 reply; 12+ messages in thread
From: Jean-Christophe PLAGNIOL-VILLARD @ 2011-08-08 7:06 UTC (permalink / raw)
To: Sascha Hauer; +Cc: barebox
On 08:46 Mon 08 Aug , Sascha Hauer wrote:
> Created this series to get high vector support. Using high vectors
> at 0xffff0000 allow us to map in a faulting page at 0x0 with which
> we can catch NULL pointer dereferences. The other patches are only
> some cleanups around exceptions which I came along the way.
be careful on ixp4xx (which I work on 0x0 is the nor flash address)
Best Regards,
J.
_______________________________________________
barebox mailing list
barebox@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/barebox
^ permalink raw reply [flat|nested] 12+ messages in thread
* Re: ARM: use high vectors if possible
2011-08-08 7:06 ` ARM: use high vectors if possible Jean-Christophe PLAGNIOL-VILLARD
@ 2011-08-08 7:32 ` Sascha Hauer
2011-08-09 7:36 ` Jean-Christophe PLAGNIOL-VILLARD
0 siblings, 1 reply; 12+ messages in thread
From: Sascha Hauer @ 2011-08-08 7:32 UTC (permalink / raw)
To: Jean-Christophe PLAGNIOL-VILLARD; +Cc: barebox
Hi J,
On Mon, Aug 08, 2011 at 09:06:50AM +0200, Jean-Christophe PLAGNIOL-VILLARD wrote:
> On 08:46 Mon 08 Aug , Sascha Hauer wrote:
> > Created this series to get high vector support. Using high vectors
> > at 0xffff0000 allow us to map in a faulting page at 0x0 with which
> > we can catch NULL pointer dereferences. The other patches are only
> > some cleanups around exceptions which I came along the way.
> be careful on ixp4xx (which I work on 0x0 is the nor flash address)
Well, we already map the vectors to 0x0 without this series, so ixp4xx
is broken anyway.
So we either have to add a flag somewhere to disable mapping anything
to 0x0 or we have to use the mmu to map the nor flash somewhere else.
I see this is a problem which must be solved, but this series does not
change the current situation in this regard.
Sascha
--
Pengutronix e.K. | |
Industrial Linux Solutions | http://www.pengutronix.de/ |
Peiner Str. 6-8, 31137 Hildesheim, Germany | Phone: +49-5121-206917-0 |
Amtsgericht Hildesheim, HRA 2686 | Fax: +49-5121-206917-5555 |
_______________________________________________
barebox mailing list
barebox@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/barebox
^ permalink raw reply [flat|nested] 12+ messages in thread
* Re: ARM: use high vectors if possible
2011-08-08 7:32 ` Sascha Hauer
@ 2011-08-09 7:36 ` Jean-Christophe PLAGNIOL-VILLARD
0 siblings, 0 replies; 12+ messages in thread
From: Jean-Christophe PLAGNIOL-VILLARD @ 2011-08-09 7:36 UTC (permalink / raw)
To: Sascha Hauer; +Cc: barebox
On 09:32 Mon 08 Aug , Sascha Hauer wrote:
> Hi J,
>
> On Mon, Aug 08, 2011 at 09:06:50AM +0200, Jean-Christophe PLAGNIOL-VILLARD wrote:
> > On 08:46 Mon 08 Aug , Sascha Hauer wrote:
> > > Created this series to get high vector support. Using high vectors
> > > at 0xffff0000 allow us to map in a faulting page at 0x0 with which
> > > we can catch NULL pointer dereferences. The other patches are only
> > > some cleanups around exceptions which I came along the way.
> > be careful on ixp4xx (which I work on 0x0 is the nor flash address)
>
> Well, we already map the vectors to 0x0 without this series, so ixp4xx
> is broken anyway.
> So we either have to add a flag somewhere to disable mapping anything
> to 0x0 or we have to use the mmu to map the nor flash somewhere else.
>
> I see this is a problem which must be solved, but this series does not
> change the current situation in this regard.
I'll prefer to remap the flash and keep the same scheme everywhere
can you drop a line in the doc about this
Best Regards,
J.
_______________________________________________
barebox mailing list
barebox@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/barebox
^ permalink raw reply [flat|nested] 12+ messages in thread