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  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]
Date:   Mon, 20 Jul 2020 18:29:30 +0300
From:   Alexander Lobakin <>
To:     Joe Perches <>
CC:     Alexander Lobakin <>,
        Andrew Lunn <>,
        "David S. Miller" <>,
        Jakub Kicinski <>,
        Igor Russkikh <>,
        Michal Kalderon <>,
        Ariel Elior <>,
        "Denis Bolotin" <>,
        "James E.J. Bottomley" <>,
        "Martin K. Petersen" <>,
        <>, <>,
        <>, <>
Subject: Re: [PATCH v2 net-next 01/14] qed: convert link mode from u32 to bitmap

Hi Joe,

From: Joe Perches <>
Date: Mon, 20 Jul 2020 08:19:52 -0700

> On Mon, 2020-07-20 at 12:23 +0300, Alexander Lobakin wrote:
>> Date: Sun, 19 Jul 2020 23:21:00 +0200 From: Andrew Lunn <>
>>> On Sun, Jul 19, 2020 at 11:14:40PM +0300, Alexander Lobakin wrote:
>>>> Currently qed driver already ran out of 32 bits to store link modes,
>>>> and this doesn't allow to add and support more speeds.
>>>> Convert link mode to bitmap that will always have enough space for
>>>> any number of speeds and modes.
> []
>>> Why not just throw away all these QED_LM_ defines and use the kernel
>>> link modes? The fact you are changing the u32 to a bitmap suggests the
>>> hardware does not use them.
>> I've just double-checked, and you're right, management firmware operates
>> with NVM_* definitions, while QED_LM_* are used only in QED and QEDE to
>> fill Ethtool link settings.
>> I didn't notice this while working on the series, but it would be really
>> a lot better to just use generic definitions.
>> So I'll send v3 soon.
> While you're at it, why are you using __set_bit and not set_bit?

Because I'm filling link modes and don't need any atomicity at all.
If you refer linkmode_*() functions [1], they also use non-atomic
variants of bitops.



Powered by blists - more mailing lists