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 for Android: free password hash cracker in your pocket
[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <035bb415-283f-e540-7c85-ae21103158de@roeck-us.net>
Date:   Sun, 2 Oct 2022 16:02:52 -0700
From:   Guenter Roeck <linux@...ck-us.net>
To:     Jakub Kicinski <kuba@...nel.org>
Cc:     davem@...emloft.net, netdev@...r.kernel.org, edumazet@...gle.com,
        pabeni@...hat.com, kvalo@...nel.org, johannes@...solutions.net,
        linux-wireless@...r.kernel.org, mkl@...gutronix.de,
        linux-can@...r.kernel.org
Subject: Re: [PATCH net-next] net: drop the weight argument from
 netif_napi_add

On 10/2/22 10:59, Jakub Kicinski wrote:
> On Sun, 2 Oct 2022 10:24:27 -0700 Guenter Roeck wrote:
>> On Tue, Sep 27, 2022 at 06:27:53AM -0700, Jakub Kicinski wrote:
>>> We tell driver developers to always pass NAPI_POLL_WEIGHT
>>> as the weight to netif_napi_add(). This may be confusing
>>> to newcomers, drop the weight argument, those who really
>>> need to tweak the weight can use netif_napi_add_weight().
>>>
>>> Signed-off-by: Jakub Kicinski <kuba@...nel.org>
>>
>> That seems to have missed some (or at least one) file(s).
>>
>> Building mips:cavium_octeon_defconfig ... failed
>> --------------
>> Error log:
>> drivers/net/ethernet/cavium/octeon/octeon_mgmt.c: In function 'octeon_mgmt_probe':
>> drivers/net/ethernet/cavium/octeon/octeon_mgmt.c:1399:9: error: too many arguments to function 'netif_napi_add'
>>   1399 |         netif_napi_add(netdev, &p->napi, octeon_mgmt_napi_poll,
>>        |         ^~~~~~~~~~~~~~
>> In file included from include/linux/etherdevice.h:21,
>>                   from drivers/net/ethernet/cavium/octeon/octeon_mgmt.c:11:
>> include/linux/netdevice.h:2562:1: note: declared here
>>   2562 | netif_napi_add(struct net_device *dev, struct napi_struct *napi,
> 
> Fix sent, sorry. I don't see any more problems grepping again now..

I think that was the only one. The following coccinelle script helps.

Guenter

---
virtual report

@s@
expression a, b, c, d;
position p;
@@

   netif_napi_add@p(a, b, c, d);

@script:python depends on report@
p << s.p;
@@
print "Bad netif_napi_add() call at %s:%s" % (p[0].file, p[0].line)

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ