Re: [PATCH v3 2/7] arm64: HWCAP: add support for AT_HWCAP2

From
Dave Martin <Dave.Martin@arm.com>
Date
2019-04-03 09:11:35
Also in
linux-arm-kernel
Reply to
Andrew Murray, 2019-04-03
On Wed, Apr 03, 2019 at 09:32:55AM +0100, Andrew Murray wrote:
On Tue, Apr 02, 2019 at 03:58:31PM +0100, Dave Martin wrote:
quoted
On Mon, Apr 01, 2019 at 11:45:10AM +0100, Andrew Murray wrote:
[...]
quoted
quoted
diff --git a/drivers/clocksource/arm_arch_timer.c b/drivers/clocksource/arm_arch_timer.c
index aa4ec53281ce..6cc8aff83805 100644
--- a/drivers/clocksource/arm_arch_timer.c
+++ b/drivers/clocksource/arm_arch_timer.c
@@ -833,7 +833,11 @@ static void arch_timer_evtstrm_enable(int divider)
 	cntkctl |= (divider << ARCH_TIMER_EVT_TRIGGER_SHIFT)
 			| ARCH_TIMER_VIRT_EVT_EN;
 	arch_timer_set_cntkctl(cntkctl);
+#ifdef CONFIG_ARM64
+	cpu_set_named_feature(EVTSTRM);
+#else
 	elf_hwcap |= HWCAP_EVTSTRM;
+#endif
I wonder whether we can have a generic definition for this:

#define cpu_set_named_feature(x) (elf_hwcap |= HWCAP_ ## x)
You mean specific to arm32?

I will do this, along with a cpu_get_named_feature - but I think I'd prefer
to do this in a separate series.
Yes, we could do that.  We could also do it more widely, but it's
probably not worth the overhead of doing it.

[...]

Cheers
---Dave
Thread (23 messages) 23 messages, 3 authors, last reply 2019-04-03
Keyboard shortcuts
hback out one level
jnext message in thread / next series-diff position
kprevious message in thread / previous series-diff position
ldrill in
Escclose help / fold thread tree
?toggle this help