31 Aug 01:15
sparc64: Only Panther cheetah+ chips have POPC.
Linux Kernel Mailing List <linux-kernel <at> vger.kernel.org>
2011-08-30 23:15:18 GMT
2011-08-30 23:15:18 GMT
Gitweb: http://git.kernel.org/linus/1a8e0da5937a6c87807083baa318cf8f98dac9aa Commit: 1a8e0da5937a6c87807083baa318cf8f98dac9aa Parent: 0f43dd546d991ca260d8a72d07f617907c508de8 Author: David S. Miller <davem <at> davemloft.net> AuthorDate: Mon Aug 29 21:14:29 2011 -0700 Committer: David S. Miller <davem <at> davemloft.net> CommitDate: Mon Aug 29 21:14:29 2011 -0700 sparc64: Only Panther cheetah+ chips have POPC. Signed-off-by: David S. Miller <davem <at> davemloft.net> --- arch/sparc/kernel/setup_64.c | 10 ++++++++-- 1 files changed, 8 insertions(+), 2 deletions(-) diff --git a/arch/sparc/kernel/setup_64.c b/arch/sparc/kernel/setup_64.c index 3e9daea..3c5bb78 100644 --- a/arch/sparc/kernel/setup_64.c +++ b/arch/sparc/kernel/setup_64.c @@ -440,8 +440,14 @@ static void __init init_sparc64_elf_hwcap(void) cap |= AV_SPARC_VIS; if (tlb_type == cheetah || tlb_type == cheetah_plus) cap |= AV_SPARC_VIS | AV_SPARC_VIS2; - if (tlb_type == cheetah_plus) - cap |= AV_SPARC_POPC; + if (tlb_type == cheetah_plus) { + unsigned long impl, ver; + + __asm__ __volatile__("rdpr %%ver, %0" : "=r" (ver)); + impl = ((ver >> 32) & 0xffff);(Continue reading)
RSS Feed