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] [day] [month] [year] [list]
Message-ID: <6151E490.4020403@gmail.com>
Date:   Mon, 27 Sep 2021 18:34:40 +0300
From:   Eli Billauer <eli.billauer@...il.com>
To:     Arnd Bergmann <arnd@...db.de>
CC:     gregkh <gregkh@...uxfoundation.org>,
        Linux Kernel Mailing List <linux-kernel@...r.kernel.org>,
        Christophe JAILLET <christophe.jaillet@...adoo.fr>
Subject: Re: [PATCH] char: xillybus: Eliminate redundant wrappers to DMA related
 calls

On 27/09/21 10:47, Arnd Bergmann wrote:
>> +static void xilly_sync_for_device(struct xilly_endpoint *ep,
>> >  +                                 dma_addr_t dma_handle,
>> >  +                                 size_t size,
>> >  +                                 int direction)
>> >  +{
>> >  +       if (ep->make_sync_calls)
>> >  +               dma_sync_single_for_device(ep->dev, dma_handle,
>> >  +                                          size, direction);
>> >  +}
>>
> These wrappers should not even be needed. When the device is
> marked as coherent in DT, the dma_sync_*() calls are supposed
> to do nothing, in a relatively efficient way. I would not expect
> the extra conditional to give you any measurable performance
> benefit over what you get normally, and it should not make a
> functional difference either.
>
> Can you remove the inlines and the ->make_sync_calls flag?
>
>
Thanks, I had no idea that the sync functions neutralize themselves this 
way. That is, since commit 591c1ee465ce ("of: configure the platform 
device dma parameters") from back in April 2014.

So indeed, I shall remove the the @make_sync_calls entry and related 
wrapper functions, and resubmit an second version of this patch.

Thanks again,
    Eli

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ