diff options
author | Patrick Wildt <patrick@cvs.openbsd.org> | 2013-08-06 14:20:16 +0000 |
---|---|---|
committer | Patrick Wildt <patrick@cvs.openbsd.org> | 2013-08-06 14:20:16 +0000 |
commit | b7832e043e31f6a8f0b5f802edfeb1a5409524f4 (patch) | |
tree | 591b75c4254cea23fcb9b0906c47d47aabe55c05 /sys | |
parent | 3f52870ceacb81005cb85e25ece44fc1905319b2 (diff) |
Attach amptimer only on Cortex-A9, as all Cortex-A8 doesn't have a generic
timer and the newer Cortexes have another generic timer.
ok rapha@ jsg@
Diffstat (limited to 'sys')
-rw-r--r-- | sys/arch/arm/cortex/amptimer.c | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/sys/arch/arm/cortex/amptimer.c b/sys/arch/arm/cortex/amptimer.c index e653f942028..6c2a3f635a6 100644 --- a/sys/arch/arm/cortex/amptimer.c +++ b/sys/arch/arm/cortex/amptimer.c @@ -1,4 +1,4 @@ -/* $OpenBSD: amptimer.c,v 1.2 2013/05/09 13:35:43 patrick Exp $ */ +/* $OpenBSD: amptimer.c,v 1.3 2013/08/06 14:20:15 patrick Exp $ */ /* * Copyright (c) 2011 Dale Rahn <drahn@openbsd.org> * @@ -144,7 +144,10 @@ amptimer_readcnt64(struct amptimer_softc *sc) int amptimer_match(struct device *parent, void *cfdata, void *aux) { - return (1); + if ((cpufunc_id() & CPU_ID_CORTEX_A9_MASK) == CPU_ID_CORTEX_A9) + return (1); + + return 0; } void |