]> git.karo-electronics.de Git - karo-tx-linux.git/commitdiff
s390/cpuinfo: show maximum thread id
authorHeiko Carstens <heiko.carstens@de.ibm.com>
Mon, 27 Jun 2016 11:19:22 +0000 (13:19 +0200)
committerMartin Schwidefsky <schwidefsky@de.ibm.com>
Mon, 4 Jul 2016 07:25:20 +0000 (09:25 +0200)
Expose the maximum thread id with /proc/cpuinfo.
With the new line the output looks like this:

vendor_id       : IBM/S390
bogomips per cpu: 20325.00
max thread id   : 1

With this new interface it is possible to always tell the correct
number of cpu threads potentially being used by the kernel.

Signed-off-by: Heiko Carstens <heiko.carstens@de.ibm.com>
Signed-off-by: Martin Schwidefsky <schwidefsky@de.ibm.com>
arch/s390/kernel/processor.c

index 6cf24b471b0c5b50d9bf54960a65b8443a3e1399..81d0808085e6bca9d2ff35c30619f7a238754db2 100644 (file)
@@ -104,6 +104,7 @@ static void show_cpu_summary(struct seq_file *m, void *v)
                   "bogomips per cpu: %lu.%02lu\n",
                   num_online_cpus(), loops_per_jiffy/(500000/HZ),
                   (loops_per_jiffy/(5000/HZ))%100);
+       seq_printf(m, "max thread id   : %d\n", smp_cpu_mtid);
        seq_puts(m, "features\t: ");
        for (i = 0; i < ARRAY_SIZE(hwcap_str); i++)
                if (hwcap_str[i] && (elf_hwcap & (1UL << i)))