Re: [PATCH] crypto: ccree - Remove a useless dma_supported() call

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

 



On Tue, Jul 19, 2022 at 10:27:50PM +0200, Christophe JAILLET wrote:
> There is no point in calling dma_supported() before calling
> dma_set_coherent_mask(). This function already calls dma_supported() and
> returns an error (-EIO) if it fails.
> 
> So remove the superfluous dma_supported() call.
> 
> While at it, fix the name of the function reported in a dev_err().
> 
> Signed-off-by: Christophe JAILLET <christophe.jaillet@xxxxxxxxxx>
> ---
> I guess that the whole while loop could be removed, but I don't remind the
> thread with the corresponding explanation, so leave it as-is :(

The loop should go away.  Setting a larger DMA mask will never fail when
setting a smaller one will succeed.

Also after this patch dma_supported can be marked static (Yay!)



[Index of Archives]     [Kernel Development]     [Kernel Announce]     [Kernel Newbies]     [Linux Networking Development]     [Share Photos]     [IDE]     [Security]     [Git]     [Netfilter]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Device Mapper]

  Powered by Linux