You've already forked linux-apfs
mirror of
https://github.com/linux-apfs/linux-apfs.git
synced 2026-05-01 15:00:59 -07:00
Merge git://git.kernel.org/pub/scm/linux/kernel/git/rusty/linux-2.6-for-linus
* git://git.kernel.org/pub/scm/linux/kernel/git/rusty/linux-2.6-for-linus: (39 commits) cpumask: Move deprecated functions to end of header. cpumask: remove unused deprecated functions, avoid accusations of insanity cpumask: use new-style cpumask ops in mm/quicklist. cpumask: use mm_cpumask() wrapper: x86 cpumask: use mm_cpumask() wrapper: um cpumask: use mm_cpumask() wrapper: mips cpumask: use mm_cpumask() wrapper: mn10300 cpumask: use mm_cpumask() wrapper: m32r cpumask: use mm_cpumask() wrapper: arm cpumask: Use accessors for cpu_*_mask: um cpumask: Use accessors for cpu_*_mask: powerpc cpumask: Use accessors for cpu_*_mask: mips cpumask: Use accessors for cpu_*_mask: m32r cpumask: remove arch_send_call_function_ipi cpumask: arch_send_call_function_ipi_mask: s390 cpumask: arch_send_call_function_ipi_mask: powerpc cpumask: arch_send_call_function_ipi_mask: mips cpumask: arch_send_call_function_ipi_mask: m32r cpumask: arch_send_call_function_ipi_mask: alpha cpumask: remove obsolete topology_core_siblings and topology_thread_siblings: ia64 ...
This commit is contained in:
@@ -47,7 +47,7 @@ extern struct cpuinfo_alpha cpu_data[NR_CPUS];
|
||||
extern int smp_num_cpus;
|
||||
|
||||
extern void arch_send_call_function_single_ipi(int cpu);
|
||||
extern void arch_send_call_function_ipi(cpumask_t mask);
|
||||
extern void arch_send_call_function_ipi_mask(const struct cpumask *mask);
|
||||
|
||||
#else /* CONFIG_SMP */
|
||||
|
||||
|
||||
@@ -22,23 +22,6 @@ static inline int cpu_to_node(int cpu)
|
||||
return node;
|
||||
}
|
||||
|
||||
static inline cpumask_t node_to_cpumask(int node)
|
||||
{
|
||||
cpumask_t node_cpu_mask = CPU_MASK_NONE;
|
||||
int cpu;
|
||||
|
||||
for_each_online_cpu(cpu) {
|
||||
if (cpu_to_node(cpu) == node)
|
||||
cpu_set(cpu, node_cpu_mask);
|
||||
}
|
||||
|
||||
#ifdef DEBUG_NUMA
|
||||
printk("node %d: cpu_mask: %016lx\n", node, node_cpu_mask);
|
||||
#endif
|
||||
|
||||
return node_cpu_mask;
|
||||
}
|
||||
|
||||
extern struct cpumask node_to_cpumask_map[];
|
||||
/* FIXME: This is dumb, recalculating every time. But simple. */
|
||||
static const struct cpumask *cpumask_of_node(int node)
|
||||
@@ -55,7 +38,6 @@ static const struct cpumask *cpumask_of_node(int node)
|
||||
return &node_to_cpumask_map[node];
|
||||
}
|
||||
|
||||
#define pcibus_to_cpumask(bus) (cpu_online_map)
|
||||
#define cpumask_of_pcibus(bus) (cpu_online_mask)
|
||||
|
||||
#endif /* !CONFIG_NUMA */
|
||||
|
||||
@@ -548,16 +548,16 @@ setup_profiling_timer(unsigned int multiplier)
|
||||
|
||||
|
||||
static void
|
||||
send_ipi_message(cpumask_t to_whom, enum ipi_message_type operation)
|
||||
send_ipi_message(const struct cpumask *to_whom, enum ipi_message_type operation)
|
||||
{
|
||||
int i;
|
||||
|
||||
mb();
|
||||
for_each_cpu_mask(i, to_whom)
|
||||
for_each_cpu(i, to_whom)
|
||||
set_bit(operation, &ipi_data[i].bits);
|
||||
|
||||
mb();
|
||||
for_each_cpu_mask(i, to_whom)
|
||||
for_each_cpu(i, to_whom)
|
||||
wripir(i);
|
||||
}
|
||||
|
||||
@@ -624,7 +624,7 @@ smp_send_reschedule(int cpu)
|
||||
printk(KERN_WARNING
|
||||
"smp_send_reschedule: Sending IPI to self.\n");
|
||||
#endif
|
||||
send_ipi_message(cpumask_of_cpu(cpu), IPI_RESCHEDULE);
|
||||
send_ipi_message(cpumask_of(cpu), IPI_RESCHEDULE);
|
||||
}
|
||||
|
||||
void
|
||||
@@ -636,17 +636,17 @@ smp_send_stop(void)
|
||||
if (hard_smp_processor_id() != boot_cpu_id)
|
||||
printk(KERN_WARNING "smp_send_stop: Not on boot cpu.\n");
|
||||
#endif
|
||||
send_ipi_message(to_whom, IPI_CPU_STOP);
|
||||
send_ipi_message(&to_whom, IPI_CPU_STOP);
|
||||
}
|
||||
|
||||
void arch_send_call_function_ipi(cpumask_t mask)
|
||||
void arch_send_call_function_ipi_mask(const struct cpumask *mask)
|
||||
{
|
||||
send_ipi_message(mask, IPI_CALL_FUNC);
|
||||
}
|
||||
|
||||
void arch_send_call_function_single_ipi(int cpu)
|
||||
{
|
||||
send_ipi_message(cpumask_of_cpu(cpu), IPI_CALL_FUNC_SINGLE);
|
||||
send_ipi_message(cpumask_of(cpu), IPI_CALL_FUNC_SINGLE);
|
||||
}
|
||||
|
||||
static void
|
||||
|
||||
@@ -334,14 +334,14 @@ static inline void outer_flush_range(unsigned long start, unsigned long end)
|
||||
#ifndef CONFIG_CPU_CACHE_VIPT
|
||||
static inline void flush_cache_mm(struct mm_struct *mm)
|
||||
{
|
||||
if (cpu_isset(smp_processor_id(), mm->cpu_vm_mask))
|
||||
if (cpumask_test_cpu(smp_processor_id(), mm_cpumask(mm)))
|
||||
__cpuc_flush_user_all();
|
||||
}
|
||||
|
||||
static inline void
|
||||
flush_cache_range(struct vm_area_struct *vma, unsigned long start, unsigned long end)
|
||||
{
|
||||
if (cpu_isset(smp_processor_id(), vma->vm_mm->cpu_vm_mask))
|
||||
if (cpumask_test_cpu(smp_processor_id(), mm_cpumask(vma->vm_mm)))
|
||||
__cpuc_flush_user_range(start & PAGE_MASK, PAGE_ALIGN(end),
|
||||
vma->vm_flags);
|
||||
}
|
||||
@@ -349,7 +349,7 @@ flush_cache_range(struct vm_area_struct *vma, unsigned long start, unsigned long
|
||||
static inline void
|
||||
flush_cache_page(struct vm_area_struct *vma, unsigned long user_addr, unsigned long pfn)
|
||||
{
|
||||
if (cpu_isset(smp_processor_id(), vma->vm_mm->cpu_vm_mask)) {
|
||||
if (cpumask_test_cpu(smp_processor_id(), mm_cpumask(vma->vm_mm))) {
|
||||
unsigned long addr = user_addr & PAGE_MASK;
|
||||
__cpuc_flush_user_range(addr, addr + PAGE_SIZE, vma->vm_flags);
|
||||
}
|
||||
@@ -360,7 +360,7 @@ flush_ptrace_access(struct vm_area_struct *vma, struct page *page,
|
||||
unsigned long uaddr, void *kaddr,
|
||||
unsigned long len, int write)
|
||||
{
|
||||
if (cpu_isset(smp_processor_id(), vma->vm_mm->cpu_vm_mask)) {
|
||||
if (cpumask_test_cpu(smp_processor_id(), mm_cpumask(vma->vm_mm))) {
|
||||
unsigned long addr = (unsigned long)kaddr;
|
||||
__cpuc_coherent_kern_range(addr, addr + len);
|
||||
}
|
||||
|
||||
@@ -103,14 +103,15 @@ switch_mm(struct mm_struct *prev, struct mm_struct *next,
|
||||
|
||||
#ifdef CONFIG_SMP
|
||||
/* check for possible thread migration */
|
||||
if (!cpus_empty(next->cpu_vm_mask) && !cpu_isset(cpu, next->cpu_vm_mask))
|
||||
if (!cpumask_empty(mm_cpumask(next)) &&
|
||||
!cpumask_test_cpu(cpu, mm_cpumask(next)))
|
||||
__flush_icache_all();
|
||||
#endif
|
||||
if (!cpu_test_and_set(cpu, next->cpu_vm_mask) || prev != next) {
|
||||
if (!cpumask_test_and_set_cpu(cpu, mm_cpumask(next)) || prev != next) {
|
||||
check_context(next);
|
||||
cpu_switch_mm(next->pgd, next);
|
||||
if (cache_is_vivt())
|
||||
cpu_clear(cpu, prev->cpu_vm_mask);
|
||||
cpumask_clear_cpu(cpu, mm_cpumask(prev));
|
||||
}
|
||||
#endif
|
||||
}
|
||||
|
||||
@@ -93,7 +93,6 @@ extern void platform_cpu_enable(unsigned int cpu);
|
||||
|
||||
extern void arch_send_call_function_single_ipi(int cpu);
|
||||
extern void arch_send_call_function_ipi_mask(const struct cpumask *mask);
|
||||
#define arch_send_call_function_ipi_mask arch_send_call_function_ipi_mask
|
||||
|
||||
/*
|
||||
* show local interrupt info
|
||||
|
||||
@@ -350,7 +350,7 @@ static inline void local_flush_tlb_mm(struct mm_struct *mm)
|
||||
if (tlb_flag(TLB_WB))
|
||||
dsb();
|
||||
|
||||
if (cpu_isset(smp_processor_id(), mm->cpu_vm_mask)) {
|
||||
if (cpumask_test_cpu(smp_processor_id(), mm_cpumask(mm))) {
|
||||
if (tlb_flag(TLB_V3_FULL))
|
||||
asm("mcr p15, 0, %0, c6, c0, 0" : : "r" (zero) : "cc");
|
||||
if (tlb_flag(TLB_V4_U_FULL))
|
||||
@@ -388,7 +388,7 @@ local_flush_tlb_page(struct vm_area_struct *vma, unsigned long uaddr)
|
||||
if (tlb_flag(TLB_WB))
|
||||
dsb();
|
||||
|
||||
if (cpu_isset(smp_processor_id(), vma->vm_mm->cpu_vm_mask)) {
|
||||
if (cpumask_test_cpu(smp_processor_id(), mm_cpumask(vma->vm_mm))) {
|
||||
if (tlb_flag(TLB_V3_PAGE))
|
||||
asm("mcr p15, 0, %0, c6, c0, 0" : : "r" (uaddr) : "cc");
|
||||
if (tlb_flag(TLB_V4_U_PAGE))
|
||||
|
||||
@@ -189,7 +189,7 @@ int __cpuexit __cpu_disable(void)
|
||||
read_lock(&tasklist_lock);
|
||||
for_each_process(p) {
|
||||
if (p->mm)
|
||||
cpu_clear(cpu, p->mm->cpu_vm_mask);
|
||||
cpumask_clear_cpu(cpu, mm_cpumask(p->mm));
|
||||
}
|
||||
read_unlock(&tasklist_lock);
|
||||
|
||||
@@ -257,7 +257,7 @@ asmlinkage void __cpuinit secondary_start_kernel(void)
|
||||
atomic_inc(&mm->mm_users);
|
||||
atomic_inc(&mm->mm_count);
|
||||
current->active_mm = mm;
|
||||
cpu_set(cpu, mm->cpu_vm_mask);
|
||||
cpumask_set_cpu(cpu, mm_cpumask(mm));
|
||||
cpu_switch_mm(mm->pgd, mm);
|
||||
enter_lazy_tlb(mm, current);
|
||||
local_flush_tlb_all();
|
||||
@@ -643,7 +643,7 @@ void flush_tlb_all(void)
|
||||
void flush_tlb_mm(struct mm_struct *mm)
|
||||
{
|
||||
if (tlb_ops_need_broadcast())
|
||||
on_each_cpu_mask(ipi_flush_tlb_mm, mm, 1, &mm->cpu_vm_mask);
|
||||
on_each_cpu_mask(ipi_flush_tlb_mm, mm, 1, mm_cpumask(mm));
|
||||
else
|
||||
local_flush_tlb_mm(mm);
|
||||
}
|
||||
@@ -654,7 +654,7 @@ void flush_tlb_page(struct vm_area_struct *vma, unsigned long uaddr)
|
||||
struct tlb_args ta;
|
||||
ta.ta_vma = vma;
|
||||
ta.ta_start = uaddr;
|
||||
on_each_cpu_mask(ipi_flush_tlb_page, &ta, 1, &vma->vm_mm->cpu_vm_mask);
|
||||
on_each_cpu_mask(ipi_flush_tlb_page, &ta, 1, mm_cpumask(vma->vm_mm));
|
||||
} else
|
||||
local_flush_tlb_page(vma, uaddr);
|
||||
}
|
||||
@@ -677,7 +677,7 @@ void flush_tlb_range(struct vm_area_struct *vma,
|
||||
ta.ta_vma = vma;
|
||||
ta.ta_start = start;
|
||||
ta.ta_end = end;
|
||||
on_each_cpu_mask(ipi_flush_tlb_range, &ta, 1, &vma->vm_mm->cpu_vm_mask);
|
||||
on_each_cpu_mask(ipi_flush_tlb_range, &ta, 1, mm_cpumask(vma->vm_mm));
|
||||
} else
|
||||
local_flush_tlb_range(vma, start, end);
|
||||
}
|
||||
|
||||
@@ -59,6 +59,6 @@ void __new_context(struct mm_struct *mm)
|
||||
}
|
||||
spin_unlock(&cpu_asid_lock);
|
||||
|
||||
mm->cpu_vm_mask = cpumask_of_cpu(smp_processor_id());
|
||||
cpumask_copy(mm_cpumask(mm), cpumask_of(smp_processor_id()));
|
||||
mm->context.id = asid;
|
||||
}
|
||||
|
||||
+5
-5
@@ -50,7 +50,7 @@ static void flush_pfn_alias(unsigned long pfn, unsigned long vaddr)
|
||||
void flush_cache_mm(struct mm_struct *mm)
|
||||
{
|
||||
if (cache_is_vivt()) {
|
||||
if (cpu_isset(smp_processor_id(), mm->cpu_vm_mask))
|
||||
if (cpumask_test_cpu(smp_processor_id(), mm_cpumask(mm)))
|
||||
__cpuc_flush_user_all();
|
||||
return;
|
||||
}
|
||||
@@ -73,7 +73,7 @@ void flush_cache_mm(struct mm_struct *mm)
|
||||
void flush_cache_range(struct vm_area_struct *vma, unsigned long start, unsigned long end)
|
||||
{
|
||||
if (cache_is_vivt()) {
|
||||
if (cpu_isset(smp_processor_id(), vma->vm_mm->cpu_vm_mask))
|
||||
if (cpumask_test_cpu(smp_processor_id(), mm_cpumask(vma->vm_mm)))
|
||||
__cpuc_flush_user_range(start & PAGE_MASK, PAGE_ALIGN(end),
|
||||
vma->vm_flags);
|
||||
return;
|
||||
@@ -97,7 +97,7 @@ void flush_cache_range(struct vm_area_struct *vma, unsigned long start, unsigned
|
||||
void flush_cache_page(struct vm_area_struct *vma, unsigned long user_addr, unsigned long pfn)
|
||||
{
|
||||
if (cache_is_vivt()) {
|
||||
if (cpu_isset(smp_processor_id(), vma->vm_mm->cpu_vm_mask)) {
|
||||
if (cpumask_test_cpu(smp_processor_id(), mm_cpumask(vma->vm_mm))) {
|
||||
unsigned long addr = user_addr & PAGE_MASK;
|
||||
__cpuc_flush_user_range(addr, addr + PAGE_SIZE, vma->vm_flags);
|
||||
}
|
||||
@@ -113,7 +113,7 @@ void flush_ptrace_access(struct vm_area_struct *vma, struct page *page,
|
||||
unsigned long len, int write)
|
||||
{
|
||||
if (cache_is_vivt()) {
|
||||
if (cpu_isset(smp_processor_id(), vma->vm_mm->cpu_vm_mask)) {
|
||||
if (cpumask_test_cpu(smp_processor_id(), mm_cpumask(vma->vm_mm))) {
|
||||
unsigned long addr = (unsigned long)kaddr;
|
||||
__cpuc_coherent_kern_range(addr, addr + len);
|
||||
}
|
||||
@@ -126,7 +126,7 @@ void flush_ptrace_access(struct vm_area_struct *vma, struct page *page,
|
||||
}
|
||||
|
||||
/* VIPT non-aliasing cache */
|
||||
if (cpu_isset(smp_processor_id(), vma->vm_mm->cpu_vm_mask) &&
|
||||
if (cpumask_test_cpu(smp_processor_id(), mm_cpumask(vma->vm_mm)) &&
|
||||
vma->vm_flags & VM_EXEC) {
|
||||
unsigned long addr = (unsigned long)kaddr;
|
||||
/* only flushing the kernel mapping on non-aliasing VIPT */
|
||||
|
||||
@@ -127,7 +127,6 @@ extern int is_multithreading_enabled(void);
|
||||
|
||||
extern void arch_send_call_function_single_ipi(int cpu);
|
||||
extern void arch_send_call_function_ipi_mask(const struct cpumask *mask);
|
||||
#define arch_send_call_function_ipi_mask arch_send_call_function_ipi_mask
|
||||
|
||||
#else /* CONFIG_SMP */
|
||||
|
||||
|
||||
@@ -33,7 +33,6 @@
|
||||
/*
|
||||
* Returns a bitmask of CPUs on Node 'node'.
|
||||
*/
|
||||
#define node_to_cpumask(node) (node_to_cpu_mask[node])
|
||||
#define cpumask_of_node(node) (&node_to_cpu_mask[node])
|
||||
|
||||
/*
|
||||
@@ -104,8 +103,6 @@ void build_cpu_to_node_map(void);
|
||||
#ifdef CONFIG_SMP
|
||||
#define topology_physical_package_id(cpu) (cpu_data(cpu)->socket_id)
|
||||
#define topology_core_id(cpu) (cpu_data(cpu)->core_id)
|
||||
#define topology_core_siblings(cpu) (cpu_core_map[cpu])
|
||||
#define topology_thread_siblings(cpu) (per_cpu(cpu_sibling_map, cpu))
|
||||
#define topology_core_cpumask(cpu) (&cpu_core_map[cpu])
|
||||
#define topology_thread_cpumask(cpu) (&per_cpu(cpu_sibling_map, cpu))
|
||||
#define smt_capable() (smp_num_siblings > 1)
|
||||
|
||||
@@ -302,7 +302,7 @@ smp_flush_tlb_mm (struct mm_struct *mm)
|
||||
return;
|
||||
}
|
||||
|
||||
smp_call_function_mask(mm->cpu_vm_mask,
|
||||
smp_call_function_many(mm_cpumask(mm),
|
||||
(void (*)(void *))local_finish_flush_tlb_mm, mm, 1);
|
||||
local_irq_disable();
|
||||
local_finish_flush_tlb_mm(mm);
|
||||
|
||||
@@ -127,7 +127,7 @@ static inline void switch_mm(struct mm_struct *prev,
|
||||
|
||||
if (prev != next) {
|
||||
#ifdef CONFIG_SMP
|
||||
cpu_set(cpu, next->cpu_vm_mask);
|
||||
cpumask_set_cpu(cpu, mm_cpumask(next));
|
||||
#endif /* CONFIG_SMP */
|
||||
/* Set MPTB = next->pgd */
|
||||
*(volatile unsigned long *)MPTB = (unsigned long)next->pgd;
|
||||
@@ -135,7 +135,7 @@ static inline void switch_mm(struct mm_struct *prev,
|
||||
}
|
||||
#ifdef CONFIG_SMP
|
||||
else
|
||||
if (!cpu_test_and_set(cpu, next->cpu_vm_mask))
|
||||
if (!cpumask_test_and_set_cpu(cpu, mm_cpumask(next)))
|
||||
activate_context(next);
|
||||
#endif /* CONFIG_SMP */
|
||||
}
|
||||
|
||||
@@ -88,7 +88,7 @@ extern void smp_send_timer(void);
|
||||
extern unsigned long send_IPI_mask_phys(cpumask_t, int, int);
|
||||
|
||||
extern void arch_send_call_function_single_ipi(int cpu);
|
||||
extern void arch_send_call_function_ipi(cpumask_t mask);
|
||||
extern void arch_send_call_function_ipi_mask(const struct cpumask *mask);
|
||||
|
||||
#endif /* not __ASSEMBLY__ */
|
||||
|
||||
|
||||
+15
-15
@@ -85,7 +85,7 @@ void smp_ipi_timer_interrupt(struct pt_regs *);
|
||||
void smp_local_timer_interrupt(void);
|
||||
|
||||
static void send_IPI_allbutself(int, int);
|
||||
static void send_IPI_mask(cpumask_t, int, int);
|
||||
static void send_IPI_mask(const struct cpumask *, int, int);
|
||||
unsigned long send_IPI_mask_phys(cpumask_t, int, int);
|
||||
|
||||
/*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*/
|
||||
@@ -113,7 +113,7 @@ unsigned long send_IPI_mask_phys(cpumask_t, int, int);
|
||||
void smp_send_reschedule(int cpu_id)
|
||||
{
|
||||
WARN_ON(cpu_is_offline(cpu_id));
|
||||
send_IPI_mask(cpumask_of_cpu(cpu_id), RESCHEDULE_IPI, 1);
|
||||
send_IPI_mask(cpumask_of(cpu_id), RESCHEDULE_IPI, 1);
|
||||
}
|
||||
|
||||
/*==========================================================================*
|
||||
@@ -168,7 +168,7 @@ void smp_flush_cache_all(void)
|
||||
spin_lock(&flushcache_lock);
|
||||
mask=cpus_addr(cpumask);
|
||||
atomic_set_mask(*mask, (atomic_t *)&flushcache_cpumask);
|
||||
send_IPI_mask(cpumask, INVALIDATE_CACHE_IPI, 0);
|
||||
send_IPI_mask(&cpumask, INVALIDATE_CACHE_IPI, 0);
|
||||
_flush_cache_copyback_all();
|
||||
while (flushcache_cpumask)
|
||||
mb();
|
||||
@@ -264,7 +264,7 @@ void smp_flush_tlb_mm(struct mm_struct *mm)
|
||||
preempt_disable();
|
||||
cpu_id = smp_processor_id();
|
||||
mmc = &mm->context[cpu_id];
|
||||
cpu_mask = mm->cpu_vm_mask;
|
||||
cpu_mask = *mm_cpumask(mm);
|
||||
cpu_clear(cpu_id, cpu_mask);
|
||||
|
||||
if (*mmc != NO_CONTEXT) {
|
||||
@@ -273,7 +273,7 @@ void smp_flush_tlb_mm(struct mm_struct *mm)
|
||||
if (mm == current->mm)
|
||||
activate_context(mm);
|
||||
else
|
||||
cpu_clear(cpu_id, mm->cpu_vm_mask);
|
||||
cpumask_clear_cpu(cpu_id, mm_cpumask(mm));
|
||||
local_irq_restore(flags);
|
||||
}
|
||||
if (!cpus_empty(cpu_mask))
|
||||
@@ -334,7 +334,7 @@ void smp_flush_tlb_page(struct vm_area_struct *vma, unsigned long va)
|
||||
preempt_disable();
|
||||
cpu_id = smp_processor_id();
|
||||
mmc = &mm->context[cpu_id];
|
||||
cpu_mask = mm->cpu_vm_mask;
|
||||
cpu_mask = *mm_cpumask(mm);
|
||||
cpu_clear(cpu_id, cpu_mask);
|
||||
|
||||
#ifdef DEBUG_SMP
|
||||
@@ -424,7 +424,7 @@ static void flush_tlb_others(cpumask_t cpumask, struct mm_struct *mm,
|
||||
* We have to send the IPI only to
|
||||
* CPUs affected.
|
||||
*/
|
||||
send_IPI_mask(cpumask, INVALIDATE_TLB_IPI, 0);
|
||||
send_IPI_mask(&cpumask, INVALIDATE_TLB_IPI, 0);
|
||||
|
||||
while (!cpus_empty(flush_cpumask)) {
|
||||
/* nothing. lockup detection does not belong here */
|
||||
@@ -469,7 +469,7 @@ void smp_invalidate_interrupt(void)
|
||||
if (flush_mm == current->active_mm)
|
||||
activate_context(flush_mm);
|
||||
else
|
||||
cpu_clear(cpu_id, flush_mm->cpu_vm_mask);
|
||||
cpumask_clear_cpu(cpu_id, mm_cpumask(flush_mm));
|
||||
} else {
|
||||
unsigned long va = flush_va;
|
||||
|
||||
@@ -546,14 +546,14 @@ static void stop_this_cpu(void *dummy)
|
||||
for ( ; ; );
|
||||
}
|
||||
|
||||
void arch_send_call_function_ipi(cpumask_t mask)
|
||||
void arch_send_call_function_ipi_mask(const struct cpumask *mask)
|
||||
{
|
||||
send_IPI_mask(mask, CALL_FUNCTION_IPI, 0);
|
||||
}
|
||||
|
||||
void arch_send_call_function_single_ipi(int cpu)
|
||||
{
|
||||
send_IPI_mask(cpumask_of_cpu(cpu), CALL_FUNC_SINGLE_IPI, 0);
|
||||
send_IPI_mask(cpumask_of(cpu), CALL_FUNC_SINGLE_IPI, 0);
|
||||
}
|
||||
|
||||
/*==========================================================================*
|
||||
@@ -729,7 +729,7 @@ static void send_IPI_allbutself(int ipi_num, int try)
|
||||
cpumask = cpu_online_map;
|
||||
cpu_clear(smp_processor_id(), cpumask);
|
||||
|
||||
send_IPI_mask(cpumask, ipi_num, try);
|
||||
send_IPI_mask(&cpumask, ipi_num, try);
|
||||
}
|
||||
|
||||
/*==========================================================================*
|
||||
@@ -752,7 +752,7 @@ static void send_IPI_allbutself(int ipi_num, int try)
|
||||
* ---------- --- --------------------------------------------------------
|
||||
*
|
||||
*==========================================================================*/
|
||||
static void send_IPI_mask(cpumask_t cpumask, int ipi_num, int try)
|
||||
static void send_IPI_mask(const struct cpumask *cpumask, int ipi_num, int try)
|
||||
{
|
||||
cpumask_t physid_mask, tmp;
|
||||
int cpu_id, phys_id;
|
||||
@@ -761,11 +761,11 @@ static void send_IPI_mask(cpumask_t cpumask, int ipi_num, int try)
|
||||
if (num_cpus <= 1) /* NO MP */
|
||||
return;
|
||||
|
||||
cpus_and(tmp, cpumask, cpu_online_map);
|
||||
BUG_ON(!cpus_equal(cpumask, tmp));
|
||||
cpumask_and(&tmp, cpumask, cpu_online_mask);
|
||||
BUG_ON(!cpumask_equal(cpumask, &tmp));
|
||||
|
||||
physid_mask = CPU_MASK_NONE;
|
||||
for_each_cpu_mask(cpu_id, cpumask){
|
||||
for_each_cpu(cpu_id, cpumask) {
|
||||
if ((phys_id = cpu_to_physid(cpu_id)) != -1)
|
||||
cpu_set(phys_id, physid_mask);
|
||||
}
|
||||
|
||||
@@ -178,7 +178,7 @@ void __init smp_prepare_cpus(unsigned int max_cpus)
|
||||
for (phys_id = 0 ; phys_id < nr_cpu ; phys_id++)
|
||||
physid_set(phys_id, phys_cpu_present_map);
|
||||
#ifndef CONFIG_HOTPLUG_CPU
|
||||
cpu_present_map = cpu_possible_map;
|
||||
init_cpu_present(&cpu_possible_map);
|
||||
#endif
|
||||
|
||||
show_mp_info(nr_cpu);
|
||||
|
||||
@@ -88,7 +88,7 @@ static struct clock_event_device au1x_rtcmatch2_clockdev = {
|
||||
.irq = AU1000_RTC_MATCH2_INT,
|
||||
.set_next_event = au1x_rtcmatch2_set_next_event,
|
||||
.set_mode = au1x_rtcmatch2_set_mode,
|
||||
.cpumask = CPU_MASK_ALL_PTR,
|
||||
.cpumask = cpu_all_mask,
|
||||
};
|
||||
|
||||
static struct irqaction au1x_rtcmatch2_irqaction = {
|
||||
|
||||
@@ -24,12 +24,10 @@ extern struct cpuinfo_ip27 sn_cpu_info[NR_CPUS];
|
||||
|
||||
#define cpu_to_node(cpu) (sn_cpu_info[(cpu)].p_nodeid)
|
||||
#define parent_node(node) (node)
|
||||
#define node_to_cpumask(node) (hub_data(node)->h_cpus)
|
||||
#define cpumask_of_node(node) (&hub_data(node)->h_cpus)
|
||||
struct pci_bus;
|
||||
extern int pcibus_to_node(struct pci_bus *);
|
||||
|
||||
#define pcibus_to_cpumask(bus) (cpu_online_map)
|
||||
#define cpumask_of_pcibus(bus) (cpu_online_mask)
|
||||
|
||||
extern unsigned char __node_distances[MAX_COMPACT_NODES][MAX_COMPACT_NODES];
|
||||
|
||||
@@ -178,8 +178,8 @@ static inline void switch_mm(struct mm_struct *prev, struct mm_struct *next,
|
||||
* Mark current->active_mm as not "active" anymore.
|
||||
* We don't want to mislead possible IPI tlb flush routines.
|
||||
*/
|
||||
cpu_clear(cpu, prev->cpu_vm_mask);
|
||||
cpu_set(cpu, next->cpu_vm_mask);
|
||||
cpumask_clear_cpu(cpu, mm_cpumask(prev));
|
||||
cpumask_set_cpu(cpu, mm_cpumask(next));
|
||||
|
||||
local_irq_restore(flags);
|
||||
}
|
||||
@@ -235,8 +235,8 @@ activate_mm(struct mm_struct *prev, struct mm_struct *next)
|
||||
TLBMISS_HANDLER_SETUP_PGD(next->pgd);
|
||||
|
||||
/* mark mmu ownership change */
|
||||
cpu_clear(cpu, prev->cpu_vm_mask);
|
||||
cpu_set(cpu, next->cpu_vm_mask);
|
||||
cpumask_clear_cpu(cpu, mm_cpumask(prev));
|
||||
cpumask_set_cpu(cpu, mm_cpumask(next));
|
||||
|
||||
local_irq_restore(flags);
|
||||
}
|
||||
@@ -258,7 +258,7 @@ drop_mmu_context(struct mm_struct *mm, unsigned cpu)
|
||||
|
||||
local_irq_save(flags);
|
||||
|
||||
if (cpu_isset(cpu, mm->cpu_vm_mask)) {
|
||||
if (cpumask_test_cpu(cpu, mm_cpumask(mm))) {
|
||||
get_new_mmu_context(mm, cpu);
|
||||
#ifdef CONFIG_MIPS_MT_SMTC
|
||||
/* See comments for similar code above */
|
||||
|
||||
Some files were not shown because too many files have changed in this diff Show More
Reference in New Issue
Block a user