Re: [PATCH] ARM: mmu64: Don't flush freshly invalidated region

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Thu, Aug 23, 2018 at 07:54:21PM -0700, Andrey Smirnov wrote:
> Current code for dma_sync_single_for_device(), when called with dir
> set to DMA_FROM_DEVICE, will first invalidate given region of memory
> as a first step and then clean+invalidate it as a second. While the
> second step should be harmless it seems to be an unnecessary no-op
> that could probably be avoided.
> 
> Analogous code in Linux kernel (4.18) in arch/arm64/mm/cache.S:
> 
> ENTRY(__dma_map_area)
> 	cmp	w2, #DMA_FROM_DEVICE
> 	b.eq	__dma_inv_area
> 	b	__dma_clean_area
> ENDPIPROC(__dma_map_area)
> 
> is written to only perform either invalidate or clean, depending on
> the direction, so change dma_sync_single_for_device() to behave in the
> same vein and perfom _either_ invlidate or flush of the given region.
> 
> Signed-off-by: Andrey Smirnov <andrew.smirnov@xxxxxxxxx>
> ---

Applied, thanks

Sascha

-- 
Pengutronix e.K.                           |                             |
Industrial Linux Solutions                 | http://www.pengutronix.de/  |
Peiner Str. 6-8, 31137 Hildesheim, Germany | Phone: +49-5121-206917-0    |
Amtsgericht Hildesheim, HRA 2686           | Fax:   +49-5121-206917-5555 |

_______________________________________________
barebox mailing list
barebox@xxxxxxxxxxxxxxxxxxx
http://lists.infradead.org/mailman/listinfo/barebox



[Index of Archives]     [Linux Embedded]     [Linux USB Devel]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]     [XFree86]

  Powered by Linux