Skip to content

Commit 0197e41

Browse files
Pavel Tatashindavem330
authored andcommitted
sparc64: delete old wrap code
The old method that is using xcall and softint to get new context id is deleted, as it is replaced by a method of using per_cpu_secondary_mm without xcall to perform the context wrap. Signed-off-by: Pavel Tatashin <pasha.tatashin@oracle.com> Reviewed-by: Bob Picco <bob.picco@oracle.com> Reviewed-by: Steven Sistare <steven.sistare@oracle.com> Signed-off-by: David S. Miller <davem@davemloft.net>
1 parent a0582f2 commit 0197e41

6 files changed

Lines changed: 1 addition & 45 deletions

File tree

‎arch/sparc/include/asm/mmu_context_64.h‎

Lines changed: 0 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -21,12 +21,6 @@ extern unsigned long mmu_context_bmap[];
2121

2222
DECLARE_PER_CPU(struct mm_struct *, per_cpu_secondary_mm);
2323
void get_new_mmu_context(struct mm_struct *mm);
24-
#ifdef CONFIG_SMP
25-
void smp_new_mmu_context_version(void);
26-
#else
27-
#define smp_new_mmu_context_version() do { } while (0)
28-
#endif
29-
3024
int init_new_context(struct task_struct *tsk, struct mm_struct *mm);
3125
void destroy_context(struct mm_struct *mm);
3226

‎arch/sparc/include/asm/pil.h‎

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,6 @@
2020
#define PIL_SMP_CALL_FUNC 1
2121
#define PIL_SMP_RECEIVE_SIGNAL 2
2222
#define PIL_SMP_CAPTURE 3
23-
#define PIL_SMP_CTX_NEW_VERSION 4
2423
#define PIL_DEVICE_IRQ 5
2524
#define PIL_SMP_CALL_FUNC_SNGL 6
2625
#define PIL_DEFERRED_PCR_WORK 7

‎arch/sparc/kernel/kernel.h‎

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -37,7 +37,6 @@ void handle_stdfmna(struct pt_regs *regs, unsigned long sfar, unsigned long sfsr
3737
/* smp_64.c */
3838
void __irq_entry smp_call_function_client(int irq, struct pt_regs *regs);
3939
void __irq_entry smp_call_function_single_client(int irq, struct pt_regs *regs);
40-
void __irq_entry smp_new_mmu_context_version_client(int irq, struct pt_regs *regs);
4140
void __irq_entry smp_penguin_jailcell(int irq, struct pt_regs *regs);
4241
void __irq_entry smp_receive_signal_client(int irq, struct pt_regs *regs);
4342

‎arch/sparc/kernel/smp_64.c‎

Lines changed: 0 additions & 31 deletions
Original file line numberDiff line numberDiff line change
@@ -964,37 +964,6 @@ void flush_dcache_page_all(struct mm_struct *mm, struct page *page)
964964
preempt_enable();
965965
}
966966

967-
void __irq_entry smp_new_mmu_context_version_client(int irq, struct pt_regs *regs)
968-
{
969-
struct mm_struct *mm;
970-
unsigned long flags;
971-
972-
clear_softint(1 << irq);
973-
974-
/* See if we need to allocate a new TLB context because
975-
* the version of the one we are using is now out of date.
976-
*/
977-
mm = current->active_mm;
978-
if (unlikely(!mm || (mm == &init_mm)))
979-
return;
980-
981-
spin_lock_irqsave(&mm->context.lock, flags);
982-
983-
if (unlikely(!CTX_VALID(mm->context)))
984-
get_new_mmu_context(mm);
985-
986-
spin_unlock_irqrestore(&mm->context.lock, flags);
987-
988-
load_secondary_context(mm);
989-
__flush_tlb_mm(CTX_HWBITS(mm->context),
990-
SECONDARY_CONTEXT);
991-
}
992-
993-
void smp_new_mmu_context_version(void)
994-
{
995-
smp_cross_call(&xcall_new_mmu_context_version, 0, 0, 0);
996-
}
997-
998967
#ifdef CONFIG_KGDB
999968
void kgdb_roundup_cpus(unsigned long flags)
1000969
{

‎arch/sparc/kernel/ttable_64.S‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -50,7 +50,7 @@ tl0_resv03e: BTRAP(0x3e) BTRAP(0x3f) BTRAP(0x40)
5050
tl0_irq1: TRAP_IRQ(smp_call_function_client, 1)
5151
tl0_irq2: TRAP_IRQ(smp_receive_signal_client, 2)
5252
tl0_irq3: TRAP_IRQ(smp_penguin_jailcell, 3)
53-
tl0_irq4: TRAP_IRQ(smp_new_mmu_context_version_client, 4)
53+
tl0_irq4: BTRAP(0x44)
5454
#else
5555
tl0_irq1: BTRAP(0x41)
5656
tl0_irq2: BTRAP(0x42)

‎arch/sparc/mm/ultra.S‎

Lines changed: 0 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -971,11 +971,6 @@ xcall_capture:
971971
wr %g0, (1 << PIL_SMP_CAPTURE), %set_softint
972972
retry
973973

974-
.globl xcall_new_mmu_context_version
975-
xcall_new_mmu_context_version:
976-
wr %g0, (1 << PIL_SMP_CTX_NEW_VERSION), %set_softint
977-
retry
978-
979974
#ifdef CONFIG_KGDB
980975
.globl xcall_kgdb_capture
981976
xcall_kgdb_capture:

0 commit comments

Comments
 (0)