]> www.pilppa.org Git - linux-2.6-omap-h63xx.git/blobdiff - arch/x86/kernel/cpu/proc.c
Merge branch 'for-linus' of master.kernel.org:/home/rmk/linux-2.6-arm
[linux-2.6-omap-h63xx.git] / arch / x86 / kernel / cpu / proc.c
index 0d0d9057e7c0b63b36591385d89397ff7322bd99..01b1244ef1c0f47456a246f89324973b4f74269e 100644 (file)
@@ -160,14 +160,16 @@ static void *c_start(struct seq_file *m, loff_t *pos)
 {
        if (*pos == 0)  /* just in case, cpu 0 is not the first */
                *pos = first_cpu(cpu_online_map);
-       if ((*pos) < NR_CPUS && cpu_online(*pos))
+       else
+               *pos = next_cpu_nr(*pos - 1, cpu_online_map);
+       if ((*pos) < nr_cpu_ids)
                return &cpu_data(*pos);
        return NULL;
 }
 
 static void *c_next(struct seq_file *m, void *v, loff_t *pos)
 {
-       *pos = next_cpu(*pos, cpu_online_map);
+       (*pos)++;
        return c_start(m, pos);
 }