Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 40487
b: refs/heads/master
c: 9448b8f
h: refs/heads/master
i:
  40485: 09371d7
  40483: 31df4c5
  40479: 1ffdaf8
v: v3
  • Loading branch information
Manish Lachwani authored and Ralf Baechle committed Oct 30, 2006
1 parent 260d4ba commit 8c05ce5
Show file tree
Hide file tree
Showing 2 changed files with 14 additions and 5 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: f0ec69e52989986e861a352099803cbb77ca53ba
refs/heads/master: 9448b8f6a014f46450ef65d81c0be2ca5a81c867
17 changes: 13 additions & 4 deletions trunk/arch/mips/mm/c-sb1.c
Original file line number Diff line number Diff line change
Expand Up @@ -49,6 +49,15 @@ static unsigned short dcache_sets;
static unsigned int icache_range_cutoff;
static unsigned int dcache_range_cutoff;

static inline void sb1_on_each_cpu(void (*func) (void *info), void *info,
int retry, int wait)
{
preempt_disable();
smp_call_function(func, info, retry, wait);
func(info);
preempt_enable();
}

/*
* The dcache is fully coherent to the system, with one
* big caveat: the instruction stream. In other words,
Expand Down Expand Up @@ -226,7 +235,7 @@ static void sb1_flush_cache_page(struct vm_area_struct *vma, unsigned long addr,
args.vma = vma;
args.addr = addr;
args.pfn = pfn;
on_each_cpu(sb1_flush_cache_page_ipi, (void *) &args, 1, 1);
sb1_on_each_cpu(sb1_flush_cache_page_ipi, (void *) &args, 1, 1);
}
#else
void sb1_flush_cache_page(struct vm_area_struct *vma, unsigned long addr, unsigned long pfn)
Expand All @@ -249,7 +258,7 @@ void sb1___flush_cache_all_ipi(void *ignored)

static void sb1___flush_cache_all(void)
{
on_each_cpu(sb1___flush_cache_all_ipi, 0, 1, 1);
sb1_on_each_cpu(sb1___flush_cache_all_ipi, 0, 1, 1);
}
#else
void sb1___flush_cache_all(void)
Expand Down Expand Up @@ -299,7 +308,7 @@ void sb1_flush_icache_range(unsigned long start, unsigned long end)

args.start = start;
args.end = end;
on_each_cpu(sb1_flush_icache_range_ipi, &args, 1, 1);
sb1_on_each_cpu(sb1_flush_icache_range_ipi, &args, 1, 1);
}
#else
void sb1_flush_icache_range(unsigned long start, unsigned long end)
Expand All @@ -326,7 +335,7 @@ static void sb1_flush_cache_sigtramp_ipi(void *info)

static void sb1_flush_cache_sigtramp(unsigned long addr)
{
on_each_cpu(sb1_flush_cache_sigtramp_ipi, (void *) addr, 1, 1);
sb1_on_each_cpu(sb1_flush_cache_sigtramp_ipi, (void *) addr, 1, 1);
}
#else
void sb1_flush_cache_sigtramp(unsigned long addr)
Expand Down

0 comments on commit 8c05ce5

Please sign in to comment.