[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20140424154519.GE14110@arm.com>
Date: Thu, 24 Apr 2014 16:45:19 +0100
From: Will Deacon <will.deacon@....com>
To: Santosh Shilimkar <santosh.shilimkar@...com>
Cc: "linux-kernel@...r.kernel.org" <linux-kernel@...r.kernel.org>,
"linux-arm-kernel@...ts.infradead.org"
<linux-arm-kernel@...ts.infradead.org>,
"devicetree@...r.kernel.org" <devicetree@...r.kernel.org>,
Nicolas Pitre <nicolas.pitre@...aro.org>,
Russell King - ARM Linux <linux@....linux.org.uk>,
Catalin Marinas <Catalin.Marinas@....com>
Subject: Re: [PATCH v3 7/7] ARM: dma: use phys_addr_t in
__dma_page_[cpu_to_dev/dev_to_cpu]
On Thu, Apr 24, 2014 at 04:30:07PM +0100, Santosh Shilimkar wrote:
> On a 32 bit ARM architecture with LPAE extension physical addresses
> cannot fit into unsigned long variable.
>
> So fix it by using phys_addr_t instead of unsigned long.
>
> Cc: Nicolas Pitre <nicolas.pitre@...aro.org>
> Cc: Russell King - ARM Linux <linux@....linux.org.uk>
> Cc: Catalin Marinas <catalin.marinas@....com>
> Cc: Will Deacon <will.deacon@....com>
> Signed-off-by: Santosh Shilimkar <santosh.shilimkar@...com>
> ---
> arch/arm/mm/dma-mapping.c | 4 ++--
> 1 file changed, 2 insertions(+), 2 deletions(-)
Acked-by: Will Deacon <will.deacon@....com>
Will
> diff --git a/arch/arm/mm/dma-mapping.c b/arch/arm/mm/dma-mapping.c
> index f62aa06..5260f43 100644
> --- a/arch/arm/mm/dma-mapping.c
> +++ b/arch/arm/mm/dma-mapping.c
> @@ -885,7 +885,7 @@ static void dma_cache_maint_page(struct page *page, unsigned long offset,
> static void __dma_page_cpu_to_dev(struct page *page, unsigned long off,
> size_t size, enum dma_data_direction dir)
> {
> - unsigned long paddr;
> + phys_addr_t paddr;
>
> dma_cache_maint_page(page, off, size, dir, dmac_map_area);
>
> @@ -901,7 +901,7 @@ static void __dma_page_cpu_to_dev(struct page *page, unsigned long off,
> static void __dma_page_dev_to_cpu(struct page *page, unsigned long off,
> size_t size, enum dma_data_direction dir)
> {
> - unsigned long paddr = page_to_phys(page) + off;
> + phys_addr_t paddr = page_to_phys(page) + off;
>
> /* FIXME: non-speculating: not required */
> /* don't bother invalidating if DMA to device */
> --
> 1.7.9.5
>
>
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
Powered by blists - more mailing lists