diff options
author | Chris Metcalf <cmetcalf@tilera.com> | 2010-10-14 16:23:03 -0400 |
---|---|---|
committer | Chris Metcalf <cmetcalf@tilera.com> | 2010-10-15 15:38:09 -0400 |
commit | a78c942df64ef4cf495fd4d8715e48501bd7f8a4 (patch) | |
tree | fe44212d36e6ca23dbe9f2c633824389216a3d1d /arch/tile/mm | |
parent | bf65e440e8248f22b2eacf8d47961bb9d52260f7 (diff) |
arch/tile: parameterize system PLs to support KVM port
While not a port to KVM (yet), this change modifies the kernel
to be able to build either at PL1 or at PL2 with a suitable
config switch. Pushing up this change avoids handling branch
merge issues going forward with the KVM work.
Signed-off-by: Chris Metcalf <cmetcalf@tilera.com>
Diffstat (limited to 'arch/tile/mm')
-rw-r--r-- | arch/tile/mm/fault.c | 6 | ||||
-rw-r--r-- | arch/tile/mm/init.c | 2 |
2 files changed, 4 insertions, 4 deletions
diff --git a/arch/tile/mm/fault.c b/arch/tile/mm/fault.c index 94f579d0a494..f295b4ac941d 100644 --- a/arch/tile/mm/fault.c +++ b/arch/tile/mm/fault.c | |||
@@ -563,10 +563,10 @@ do_sigbus: | |||
563 | /* | 563 | /* |
564 | * When we take an ITLB or DTLB fault or access violation in the | 564 | * When we take an ITLB or DTLB fault or access violation in the |
565 | * supervisor while the critical section bit is set, the hypervisor is | 565 | * supervisor while the critical section bit is set, the hypervisor is |
566 | * reluctant to write new values into the EX_CONTEXT_1_x registers, | 566 | * reluctant to write new values into the EX_CONTEXT_K_x registers, |
567 | * since that might indicate we have not yet squirreled the SPR | 567 | * since that might indicate we have not yet squirreled the SPR |
568 | * contents away and can thus safely take a recursive interrupt. | 568 | * contents away and can thus safely take a recursive interrupt. |
569 | * Accordingly, the hypervisor passes us the PC via SYSTEM_SAVE_1_2. | 569 | * Accordingly, the hypervisor passes us the PC via SYSTEM_SAVE_K_2. |
570 | * | 570 | * |
571 | * Note that this routine is called before homecache_tlb_defer_enter(), | 571 | * Note that this routine is called before homecache_tlb_defer_enter(), |
572 | * which means that we can properly unlock any atomics that might | 572 | * which means that we can properly unlock any atomics that might |
@@ -610,7 +610,7 @@ struct intvec_state do_page_fault_ics(struct pt_regs *regs, int fault_num, | |||
610 | * fault. We didn't set up a kernel stack on initial entry to | 610 | * fault. We didn't set up a kernel stack on initial entry to |
611 | * sys_cmpxchg, but instead had one set up by the fault, which | 611 | * sys_cmpxchg, but instead had one set up by the fault, which |
612 | * (because sys_cmpxchg never releases ICS) came to us via the | 612 | * (because sys_cmpxchg never releases ICS) came to us via the |
613 | * SYSTEM_SAVE_1_2 mechanism, and thus EX_CONTEXT_1_[01] are | 613 | * SYSTEM_SAVE_K_2 mechanism, and thus EX_CONTEXT_K_[01] are |
614 | * still referencing the original user code. We release the | 614 | * still referencing the original user code. We release the |
615 | * atomic lock and rewrite pt_regs so that it appears that we | 615 | * atomic lock and rewrite pt_regs so that it appears that we |
616 | * came from user-space directly, and after we finish the | 616 | * came from user-space directly, and after we finish the |
diff --git a/arch/tile/mm/init.c b/arch/tile/mm/init.c index d89c9eacd162..78e1982cb6c9 100644 --- a/arch/tile/mm/init.c +++ b/arch/tile/mm/init.c | |||
@@ -1060,7 +1060,7 @@ void free_initmem(void) | |||
1060 | 1060 | ||
1061 | /* | 1061 | /* |
1062 | * Free the pages mapped from 0xc0000000 that correspond to code | 1062 | * Free the pages mapped from 0xc0000000 that correspond to code |
1063 | * pages from 0xfd000000 that we won't use again after init. | 1063 | * pages from MEM_SV_INTRPT that we won't use again after init. |
1064 | */ | 1064 | */ |
1065 | free_init_pages("unused kernel text", | 1065 | free_init_pages("unused kernel text", |
1066 | (unsigned long)_sinittext - text_delta, | 1066 | (unsigned long)_sinittext - text_delta, |