diff options
author | imp <imp@FreeBSD.org> | 2012-07-11 20:17:14 +0000 |
---|---|---|
committer | imp <imp@FreeBSD.org> | 2012-07-11 20:17:14 +0000 |
commit | 515d0c1d290c1ac2fb1aa99e74ef4175c158a007 (patch) | |
tree | cdb15b34649d1c3b0b980724718c54d34344146f /sys/arm/at91/at91rm9200.c | |
parent | 003ccf85faf91187b67eb412e643bb75b87ae2a6 (diff) | |
download | FreeBSD-src-515d0c1d290c1ac2fb1aa99e74ef4175c158a007.zip FreeBSD-src-515d0c1d290c1ac2fb1aa99e74ef4175c158a007.tar.gz |
Make the SoC stuff a little more modular, and start to move away from
having the CPU device that's a child of atmelarm that does stuff.
o Create a linker_set for the support fucntions for the SoCs.
o Rename soc_data to soc_info.
o Move the delay and reset function pointers to new soc_data struct
o Create elements for all known SoCs
o Add lookup of the SoC we found, and print a warning if it isn't one
we know about.
Diffstat (limited to 'sys/arm/at91/at91rm9200.c')
-rw-r--r-- | sys/arm/at91/at91rm9200.c | 12 |
1 files changed, 11 insertions, 1 deletions
diff --git a/sys/arm/at91/at91rm9200.c b/sys/arm/at91/at91rm9200.c index 22c331e..51627f0 100644 --- a/sys/arm/at91/at91rm9200.c +++ b/sys/arm/at91/at91rm9200.c @@ -42,7 +42,10 @@ __FBSDID("$FreeBSD$"); #include <arm/at91/at91rm92reg.h> #include <arm/at91/at91_aicreg.h> #include <arm/at91/at91_pmcreg.h> +#include <arm/at91/at91_streg.h> #include <arm/at91/at91_pmcvar.h> +#include <arm/at91/at91soc.h> + struct at91rm92_softc { device_t dev; @@ -171,7 +174,7 @@ static int at91_probe(device_t dev) { - device_set_desc(dev, soc_data.name); + device_set_desc(dev, soc_info.name); return (0); } @@ -277,3 +280,10 @@ static driver_t at91rm92_driver = { static devclass_t at91rm92_devclass; DRIVER_MODULE(at91rm920, atmelarm, at91rm92_driver, at91rm92_devclass, 0, 0); + +static struct at91_soc_data soc_data = { + .soc_delay = at91_st_delay, + .soc_reset = at91_st_cpu_reset +}; + +AT91_SOC(AT91_T_RM9200, &soc_data); |