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: <7df1a5fb-9c88-a077-c54e-25ea1a12427e@pensando.io>
Date:   Wed, 24 Jul 2019 13:23:15 -0700
From:   Shannon Nelson <snelson@...sando.io>
To:     Saeed Mahameed <saeedm@...lanox.com>,
        "netdev@...r.kernel.org" <netdev@...r.kernel.org>,
        "davem@...emloft.net" <davem@...emloft.net>
Subject: Re: [PATCH v4 net-next 02/19] ionic: Add hardware init and device
 commands

On 7/23/19 5:25 PM, Shannon Nelson wrote:
> On 7/23/19 4:47 PM, Saeed Mahameed wrote:
>> On Mon, 2019-07-22 at 14:40 -0700, Shannon Nelson wrote:

>> +
>> +    /* Wait for dev cmd to complete, retrying if we get EAGAIN,
>> +     * but don't wait any longer than max_seconds.
>> +     */
>> +    max_wait = jiffies + (max_seconds * HZ);
>> +try_again:
>> +    start_time = jiffies;
>> +    do {
>> +        done = ionic_dev_cmd_done(idev);
>> READ_ONCE required here ? to read from coherent memory modified
>> by the device and read by the driver ?
>
> Good idea, I'll add that in.

Looking closer at this, it is more for coordinating memory reads between 
threads and irq handlers.  This is polling a PCI register, which is 
already marked as volatile and in at least some definitions (e.g. x86) 
has a barrier.

sln

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ