diff options
author | Hiroshi DOYU <hdoyu@nvidia.com> | 2011-11-22 08:00:34 +0200 |
---|---|---|
committer | Varun Wadekar <vwadekar@nvidia.com> | 2011-12-08 18:05:18 +0530 |
commit | ce10e40d81442a446f6eb4284e0e840d6fa6c089 (patch) | |
tree | ef57f4221362e1da94929cd3bd3dab1043363ee1 /arch/arm/mach-tegra/iovmm-gart.c | |
parent | 7a31c3c7052a398a94c113a6c959d6c9663303dd (diff) |
ARM: tegra: gart: Use resource_size()
Use resource_size() instead of manual calculation
Change-Id: I0c2165b534bdec45fbba7ea0b69ccf10430d3259
Signed-off-by: Hiroshi DOYU <hdoyu@nvidia.com>
Reviewed-on: http://git-master/r/66365
Reviewed-by: Rohan Somvanshi <rsomvanshi@nvidia.com>
Tested-by: Rohan Somvanshi <rsomvanshi@nvidia.com>
Diffstat (limited to 'arch/arm/mach-tegra/iovmm-gart.c')
-rw-r--r-- | arch/arm/mach-tegra/iovmm-gart.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/arch/arm/mach-tegra/iovmm-gart.c b/arch/arm/mach-tegra/iovmm-gart.c index 83ea19bc896f..954b49552634 100644 --- a/arch/arm/mach-tegra/iovmm-gart.c +++ b/arch/arm/mach-tegra/iovmm-gart.c @@ -216,7 +216,7 @@ static int gart_probe(struct platform_device *pdev) gart->regs = gart_regs; gart->iovmm_base = (tegra_iovmm_addr_t)res_remap->start; - gart->page_count = res_remap->end - res_remap->start + 1; + gart->page_count = resource_size(res_remap); gart->page_count >>= GART_PAGE_SHIFT; gart->savedata = vmalloc(sizeof(u32) * gart->page_count); |