summaryrefslogtreecommitdiffstats
path: root/sys/arm/versatile
diff options
context:
space:
mode:
authorian <ian@FreeBSD.org>2013-11-05 02:57:34 +0000
committerian <ian@FreeBSD.org>2013-11-05 02:57:34 +0000
commitb41cdbed2449cb7c863eb6c20c8081fc46e5415d (patch)
treec8199489e8d345aac66441bbe4373217ecb4dd06 /sys/arm/versatile
parent3209347d81ca5822f60cb7e47498afb8373e582a (diff)
downloadFreeBSD-src-b41cdbed2449cb7c863eb6c20c8081fc46e5415d.zip
FreeBSD-src-b41cdbed2449cb7c863eb6c20c8081fc46e5415d.tar.gz
Call initarm_lastaddr() later in the init sequence, after establishing
static device mappings, rather than as the first of the initializations that a platform can hook into. This allows a platform to allocate KVA from the top of the address space downwards for things like static device mapping, and return the final "last usable address" result after that and other early init work is done. Because some platforms were doing work in initarm_lastaddr() that needs to be done early, add a new initarm_early_init() routine and move the early init code to that routine on those platforms. Rename platform_devmap_init() to initarm_devmap_init() to match all the other init routines called from initarm() that are designed to be implemented by platform code. Add a comment block that explains when these routines are called and the type of work expected to be done in each of them.
Diffstat (limited to 'sys/arm/versatile')
-rw-r--r--sys/arm/versatile/versatile_machdep.c8
1 files changed, 7 insertions, 1 deletions
diff --git a/sys/arm/versatile/versatile_machdep.c b/sys/arm/versatile/versatile_machdep.c
index 08ce039..0be0ad5 100644
--- a/sys/arm/versatile/versatile_machdep.c
+++ b/sys/arm/versatile/versatile_machdep.c
@@ -65,6 +65,12 @@ initarm_lastaddr(void)
}
void
+initarm_early_init(void)
+{
+
+}
+
+void
initarm_gpio_init(void)
{
}
@@ -85,7 +91,7 @@ static struct arm_devmap_entry fdt_devmap[FDT_DEVMAP_MAX] = {
* Construct pmap_devmap[] with DT-derived config data.
*/
int
-platform_devmap_init(void)
+initarm_devmap_init(void)
{
int i = 0;
fdt_devmap[i].pd_va = 0xf0100000;
OpenPOWER on IntegriCloud