lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20210320090726.GA28364@b29397-desktop>
Date:   Sat, 20 Mar 2021 17:07:26 +0800
From:   Peter Chen <peter.chen@...nel.org>
To:     Christoph Hellwig <hch@...radead.org>
Cc:     Sanket Parmar <sparmar@...ence.com>, pawell@...ence.com,
        a-govindraju@...com, linux-usb@...r.kernel.org,
        linux-kernel@...r.kernel.org, kurahul@...ence.com,
        gregkh@...uxfoundation.org, kishon@...com
Subject: Re: [PATCH v2] usb: cdns3: Optimize DMA request buffer allocation

On 21-03-18 07:32:45, Christoph Hellwig wrote:
> On Wed, Mar 17, 2021 at 08:13:59PM +0100, Sanket Parmar wrote:
> > dma_alloc_coherent() might fail on the platform with a small
> > DMA region.
> > 
> > To avoid such failure in cdns3_prepare_aligned_request_buf(),
> > dma_alloc_coherent() is replaced with dma_alloc_noncoherent()
> > to allocate aligned request buffer of dynamic length.
> > 
> > Reported-by: Aswath Govindraju <a-govindraju@...com>
> > Signed-off-by: Sanket Parmar <sparmar@...ence.com>
> 
> Looks good to me:
> 
> Reviewed-by: Christoph Hellwig <hch@....de>

Hi Christoph,

I would like to confirm the dma_alloc_noncoherent allocates the memory
less than PAGE_SIZE if buffer size it would like to allocate is small
(eg, 64 bytes)? 

-- 

Thanks,
Peter Chen

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ