diff options
author | Rich Wiley <rwiley@nvidia.com> | 2014-05-22 10:47:29 -0700 |
---|---|---|
committer | Riham Haidar <rhaidar@nvidia.com> | 2014-05-29 15:53:39 -0700 |
commit | a39d4a70d52df4a9d4a74c818880b73d684db8c7 (patch) | |
tree | 2e431c288cc2a826a522afc7b809563501b4ed29 /arch/arm/mach-tegra/common.c | |
parent | 9bc67a731b1ccbb423db1a64b5a6351b6536addb (diff) |
arm: tegra: use ioremap_wc instead of ioremap for the framebuffer
Bug 1512416
Change-Id: I30a38e2e0ae4c4f07f240cf9190cbf60eab0b538
Signed-off-by: Alex Van Brunt <avanbrunt@nvidia.com>
Signed-off-by: Rich Wiley <rwiley@nvidia.com>
Reviewed-on: http://git-master/r/407832
Reviewed-by: Bharat Nihalani <bnihalani@nvidia.com>
Tested-by: Bharat Nihalani <bnihalani@nvidia.com>
Diffstat (limited to 'arch/arm/mach-tegra/common.c')
-rw-r--r-- | arch/arm/mach-tegra/common.c | 12 |
1 files changed, 7 insertions, 5 deletions
diff --git a/arch/arm/mach-tegra/common.c b/arch/arm/mach-tegra/common.c index 38b7ec64ca72..5de470e6f1d2 100644 --- a/arch/arm/mach-tegra/common.c +++ b/arch/arm/mach-tegra/common.c @@ -1774,7 +1774,7 @@ void __tegra_move_framebuffer(struct platform_device *pdev, BUG_ON(PAGE_ALIGN(from) != from); BUG_ON(PAGE_ALIGN(size) != size); - to_io = ioremap(to, size); + to_io = ioremap_wc(to, size); if (!to_io) { pr_err("%s: Failed to map target framebuffer\n", __func__); return; @@ -1788,7 +1788,7 @@ void __tegra_move_framebuffer(struct platform_device *pdev, kunmap(page); } } else if (from) { - void __iomem *from_io = ioremap(from, size); + void __iomem *from_io = ioremap_wc(from, size); if (!from_io) { pr_err("%s: Failed to map source framebuffer\n", __func__); @@ -1796,7 +1796,8 @@ void __tegra_move_framebuffer(struct platform_device *pdev, } for (i = 0; i < size; i += 4) - writel(readl(from_io + i), to_io + i); + writel_relaxed(readl_relaxed(from_io + i), to_io + i); + dmb(); iounmap(from_io); } @@ -1814,7 +1815,7 @@ void __tegra_clear_framebuffer(struct platform_device *pdev, BUG_ON(PAGE_ALIGN((unsigned long)to) != (unsigned long)to); BUG_ON(PAGE_ALIGN(size) != size); - to_io = ioremap(to, size); + to_io = ioremap_wc(to, size); if (!to_io) { pr_err("%s: Failed to map target framebuffer\n", __func__); return; @@ -1825,7 +1826,8 @@ void __tegra_clear_framebuffer(struct platform_device *pdev, memset(to_io + i, 0, PAGE_SIZE); } else { for (i = 0; i < size; i += 4) - writel(0, to_io + i); + writel_relaxed(0, to_io + i); + dmb(); } iounmap(to_io); |