summaryrefslogtreecommitdiffstats
path: root/sys/arm
diff options
context:
space:
mode:
authorimp <imp@FreeBSD.org>2009-01-22 21:54:26 +0000
committerimp <imp@FreeBSD.org>2009-01-22 21:54:26 +0000
commite68dc65ae142db228de66380005186e346f3dd0b (patch)
tree3dc54d9ca335b9a546b2a6fe81084deb464af87e /sys/arm
parent1e8881cf5443d3d5876679aeedef41cc645be7e9 (diff)
downloadFreeBSD-src-e68dc65ae142db228de66380005186e346f3dd0b.zip
FreeBSD-src-e68dc65ae142db228de66380005186e346f3dd0b.tar.gz
Store at91_master_clock in a global variable as opposed to a compile
time constant. This allows us to potentially change it at runtime or autodetect it early in the boot (the latter being much more likely to have a good outcome).
Diffstat (limited to 'sys/arm')
-rw-r--r--sys/arm/at91/at91.c2
-rw-r--r--sys/arm/at91/at91var.h2
2 files changed, 4 insertions, 0 deletions
diff --git a/sys/arm/at91/at91.c b/sys/arm/at91/at91.c
index 2c44857..c983e53 100644
--- a/sys/arm/at91/at91.c
+++ b/sys/arm/at91/at91.c
@@ -50,6 +50,8 @@ static struct at91_softc *at91_softc;
static void at91_eoi(void *);
+uint32_t at91_master_clock = AT91C_MASTER_CLOCK;
+
static int
at91_bs_map(void *t, bus_addr_t bpa, bus_size_t size, int flags,
bus_space_handle_t *bshp)
diff --git a/sys/arm/at91/at91var.h b/sys/arm/at91/at91var.h
index 3a32339..3f82dd7 100644
--- a/sys/arm/at91/at91var.h
+++ b/sys/arm/at91/at91var.h
@@ -43,4 +43,6 @@ struct at91_ivar {
struct resource_list resources;
};
+extern uint32_t at91_master_clock;
+
#endif /* _AT91VAR_H_ */
OpenPOWER on IntegriCloud