This'll fix it up. Whoever invented cut-n-paste has a lot to
answer for.
--- 25/mm/swap.c~preempt-count-fix Tue Oct 29 22:19:54 2002
+++ 25-akpm/mm/swap.c Tue Oct 29 22:20:16 2002
@@ -90,11 +90,12 @@ void lru_cache_add_active(struct page *p
void lru_add_drain(void)
{
- struct pagevec *pvec = &per_cpu(lru_add_pvecs, get_cpu());
+ int cpu = get_cpu();
+ struct pagevec *pvec = &per_cpu(lru_add_pvecs, cpu);
if (pagevec_count(pvec))
__pagevec_lru_add(pvec);
- pvec = &per_cpu(lru_add_active_pvecs, get_cpu());
+ pvec = &per_cpu(lru_add_active_pvecs, cpu);
if (pagevec_count(pvec))
__pagevec_lru_add_active(pvec);
put_cpu();
.
I had a crash while testing SMP+preempt btw. Nasty one - took a
pagefault from userspace but do_page_fault() decided that the
fault was in-kernel or something. It fell all the way through
to die() and, well, died. I saw the same happen some months ago.
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/