Re: v2.6.22.1-rt5

From: Daniel Walker
Date: Mon Jul 23 2007 - 17:42:24 EST


On Mon, 2007-07-23 at 22:29 +0100, Rui Nuno Capela wrote:
> Ingo Molnar wrote:
> > we are pleased to announce the v2.6.22.1-rt5 kernel (collected and
> > assembled by Thomas), which can be downloaded from the usual place:
> >
> > http://redhat.com/~mingo/realtime-preempt/
> >
> > more info about the -rt patchset can be found in the RT wiki:
> >
> > http://rt.wiki.kernel.org
> >
> > Changes since -rt4:
> >
> > - MM fix: PCP pages locking (Peter Zijlstra)
> >
> > - yield() fix: remove stale RCU-unlock (Daniel Walker)
> >
> > - dont do check_pgt_cache() in idle (found by Daniel Walker)
> >
> > - moved 8 patches, created 6 new patches out of larger patches to
> > make the -rt queue more bisectable (Daniel Walker)
> >
> > - cleanup (Daniel Walker)
> >
> > - fix the latency tracer under paravirt
> >
> > to build a 2.6.22.1-rt5 tree, the following patches should be applied:
> >
> > http://kernel.org/pub/linux/kernel/v2.6/linux-2.6.22.1.tar.bz2
> > http://redhat.com/~mingo/realtime-preempt/patch-2.6.22.1-rt5
> >
> > Ingo
> > -
>
> Maybe I was too quick, but `make all` on is failing here:
>
> ...
> In file included from arch/i386/mm/pgtable.c:16:
> include/linux/quicklist.h: In function âquicklist_allocâ:
> include/linux/quicklist.h:50: warning: unused variable âqâ
> include/linux/quicklist.h: In function â__quicklist_freeâ:
> include/linux/quicklist.h:79: error: âper_cpu__quicklistâ undeclared
> (first use in this function)
> include/linux/quicklist.h:79: error: (Each undeclared identifier is
> reported only once
> include/linux/quicklist.h:79: error: for each function it appears in.)
> include/linux/quicklist.h:79: warning: type defaults to âintâ in
> declaration of âtype nameâ
> include/linux/quicklist.h:79: error: invalid type argument of âunary *â
> make[1]: *** [arch/i386/mm/pgtable.o] Error 1
> make: *** [arch/i386/mm] Error 2

Yeah, the quicklist patch wasn't fully tested .. The delta patch below
is what I had to change to get it working ..

Signed-Off-By: Daniel Walker <dwalker@xxxxxxxxxx>

diff -u linux-2.6/include/linux/quicklist.h linux-2.6.22.1/include/linux/quicklist.h
--- linux-2.6/include/linux/quicklist.h
+++ linux-2.6.22.1/include/linux/quicklist.h
@@ -47,7 +47,6 @@

static inline void *quicklist_alloc(int nr, gfp_t flags, void (*ctor)(void *))
{
- struct quicklist *q;
void **p = NULL;
int cpu;

@@ -66,6 +65,7 @@
static inline void __quicklist_free(int nr, void (*dtor)(void *), void *p,
struct page *page)
{
+ int cpu;
struct quicklist *q;
int nid = page_to_nid(page);

@@ -76,11 +76,11 @@
return;
}

- q = &get_cpu_var(quicklist)[nr];
+ q = &get_cpu_var_locked(quicklist, &cpu)[nr];
*(void **)p = q->page;
q->page = p;
q->nr_pages++;
- put_cpu_var(quicklist);
+ put_cpu_var_locked(quicklist, cpu);
}

static inline void quicklist_free(int nr, void (*dtor)(void *), void *pp)
diff -u linux-2.6/mm/quicklist.c linux-2.6.22.1/mm/quicklist.c
--- linux-2.6/mm/quicklist.c
+++ linux-2.6.22.1/mm/quicklist.c
@@ -80,7 +80,7 @@
struct quicklist *ql, *q;

for_each_online_cpu(cpu) {
- ql = per_cpu(quicklist, cpu);
+ ql = per_cpu_var_locked(quicklist, cpu);
for (q = ql; q < ql + CONFIG_NR_QUICK; q++)
count += q->nr_pages;
}


-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/