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]
Date:   Thu, 12 Jan 2017 21:00:14 +0300
From:   Sergei Shtylyov <sergei.shtylyov@...entembedded.com>
To:     Lino Sanfilippo <lsanfil@...vell.com>,
        Simon Horman <horms@...ge.net.au>
Cc:     David Miller <davem@...emloft.net>,
        Magnus Damm <magnus.damm@...il.com>, netdev@...r.kernel.org,
        linux-renesas-soc@...r.kernel.org
Subject: Re: [EXT] Re: [PATCH/RFC v2 net-next] ravb: unmap descriptors when
 freeing rings

On 01/12/2017 07:55 PM, Lino Sanfilippo wrote:

>>>>>> +
>>>>>> +    for (; priv->cur_tx[q] - priv->dirty_tx[q] > 0; priv->dirty_tx[q]++) {
>>>
>>> BTW: How can this work correctly when cur_tx wraps and dirty_tx is greater?
>>
>>    {cur|dirty}_tx never wrap.
>>
>
> Both values are 32 bit and AFAICS they are only incremented (and never reset or
> decremented).

    Yeah, sorry, O thought you mean the TX ring size wrapping.

> So what prevents them from wrapping every 2^32 processed tx descriptors? Am I
> missing
> something?

    The math should still work all right IIUC.

> Regards,
> Lino

MBR, Sergei

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ