diff options
author | Sascha Hauer <s.hauer@pengutronix.de> | 2015-10-23 11:06:56 +0200 |
---|---|---|
committer | Sascha Hauer <s.hauer@pengutronix.de> | 2015-11-03 07:27:44 +0100 |
commit | b792124a7dd30f03b9ad0e06589b5b58ed930d3b (patch) | |
tree | 9811bbbc0b5bb5baade7d32309ced5b3c59046df /drivers/video/omap.c | |
parent | 6b127d4f189c03f4417f6185de1aeb55b1706f94 (diff) | |
download | barebox-b792124a7dd30f03b9ad0e06589b5b58ed930d3b.tar.gz barebox-b792124a7dd30f03b9ad0e06589b5b58ed930d3b.tar.xz |
rework remap_range
remap_range is for remapping regions with different cache attributes.
It is implemented for ARM and PowerPC only, the other architectures only
provide stubs.
Currently the new cache attributes are passed in an architecture specific
way and the attributes have to be retrieved by calls to
mmu_get_pte_cached_flags() and mmu_get_pte_uncached_flags().
Make this simpler by providing architecture independent flags which can
be directly passed to remap_range()
Also provide a MAP_ARCH_DEFAULT flag and a arch_can_remap() function.
The MAP_ARCH_DEFAULT defaults to whatever caching type the architecture
has as default. the arch_can_remap() function returns true if the
architecture can change the cache attributes, false otherwise. This
allows the memtest code to better find out what it has to do.
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
Diffstat (limited to 'drivers/video/omap.c')
-rw-r--r-- | drivers/video/omap.c | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/drivers/video/omap.c b/drivers/video/omap.c index 3603ad2ccb..884365f609 100644 --- a/drivers/video/omap.c +++ b/drivers/video/omap.c @@ -35,7 +35,7 @@ #include <mach/omap4-silicon.h> #include <mach/omap-fb.h> -#include <asm/mmu.h> +#include <mmu.h> #include "omap.h" @@ -487,8 +487,7 @@ static int omapfb_probe(struct device_d *dev) (void __iomem *)pdata->screen->start; fbi->prealloc_screen.size = resource_size(pdata->screen); remap_range(fbi->prealloc_screen.addr, - fbi->prealloc_screen.size, - mmu_get_pte_uncached_flags()); + fbi->prealloc_screen.size, MAP_UNCACHED); } rc = omapfb_reset(fbi); |