mbox series

[wireless-next,0/3] wifi: netif_napi_add() conversions

Message ID 20220504163316.549648-1-kuba@kernel.org (mailing list archive)
Headers show
Series wifi: netif_napi_add() conversions | expand

Message

Jakub Kicinski May 4, 2022, 4:33 p.m. UTC
Convert wifi callers to the new netif_napi_add() APIs.

The callers passing 64 or NAPI_POLL_WEIGHT to the non-Tx flavor
are left alone. I'm planning to include wifi drivers in the massive
tree-wide patch/series which will drop the last argument from
netif_napi_add(). Alternatively I can switch all of wifi to
netif_napi_add_tx_weight() and back after the netif_napi_add()
change makes its wait into wireless-next.
Please LMK if you prefer that.

Jakub Kicinski (3):
  wifi: wil6210: switch to netif_napi_add_tx()
  wifi: mt76: switch to netif_napi_add_tx()
  wifi: qtnfmac: switch to netif_napi_add_weight()

 drivers/net/wireless/ath/wil6210/netdev.c              | 10 ++++------
 drivers/net/wireless/mediatek/mt76/mt7603/dma.c        |  4 ++--
 drivers/net/wireless/mediatek/mt76/mt7615/dma.c        |  4 ++--
 drivers/net/wireless/mediatek/mt76/mt76x02_mmio.c      |  4 ++--
 drivers/net/wireless/mediatek/mt76/mt7915/dma.c        |  4 ++--
 drivers/net/wireless/mediatek/mt76/mt7921/dma.c        |  4 ++--
 .../net/wireless/quantenna/qtnfmac/pcie/pearl_pcie.c   |  4 ++--
 .../net/wireless/quantenna/qtnfmac/pcie/topaz_pcie.c   |  4 ++--
 8 files changed, 18 insertions(+), 20 deletions(-)

Comments

Kalle Valo May 5, 2022, 4:25 a.m. UTC | #1
Jakub Kicinski <kuba@kernel.org> writes:

> Convert wifi callers to the new netif_napi_add() APIs.
>
> The callers passing 64 or NAPI_POLL_WEIGHT to the non-Tx flavor
> are left alone. I'm planning to include wifi drivers in the massive
> tree-wide patch/series which will drop the last argument from
> netif_napi_add(). Alternatively I can switch all of wifi to
> netif_napi_add_tx_weight() and back after the netif_napi_add()
> change makes its wait into wireless-next.
> Please LMK if you prefer that.
>
> Jakub Kicinski (3):
>   wifi: wil6210: switch to netif_napi_add_tx()
>   wifi: mt76: switch to netif_napi_add_tx()
>   wifi: qtnfmac: switch to netif_napi_add_weight()

We don't use that "wifi:" prefix, otherwise looks good. Feel free to
take via your tree:

Acked-by: Kalle Valo <kvalo@kernel.org>
Jakub Kicinski May 5, 2022, 3:54 p.m. UTC | #2
On Thu, 05 May 2022 07:25:03 +0300 Kalle Valo wrote:
> Jakub Kicinski <kuba@kernel.org> writes:
> 
> > Convert wifi callers to the new netif_napi_add() APIs.
> >
> > The callers passing 64 or NAPI_POLL_WEIGHT to the non-Tx flavor
> > are left alone. I'm planning to include wifi drivers in the massive
> > tree-wide patch/series which will drop the last argument from
> > netif_napi_add(). Alternatively I can switch all of wifi to
> > netif_napi_add_tx_weight() and back after the netif_napi_add()
> > change makes its wait into wireless-next.
> > Please LMK if you prefer that.
> >
> > Jakub Kicinski (3):
> >   wifi: wil6210: switch to netif_napi_add_tx()
> >   wifi: mt76: switch to netif_napi_add_tx()
> >   wifi: qtnfmac: switch to netif_napi_add_weight()  
> 
> We don't use that "wifi:" prefix, otherwise looks good. 

I know, my silent effort to make git log --oneline be more
understandable for folks outside of networking is not really
being met with much applause :) Ethernet people also don't
like the "eth:" prefix..

AFAICS drivers tend to use a format consisting of (numbers at 
the top denoting commonality):

3    4       1       2
net: vendor: driver: component: bla bla

Driver name is the most common prefix. It is the most meaningful
and natural for people working on the code. Not everyone is working 
on the driver code, tho.

1) When I send PRs to Linus I always wonder how much he can 
make out of the shortlog. And if people throw "net:" into the mix
whether it's still clear when something is "just" a driver bug vs
a core bug affecting everyone. So I started using "eth: " for ethernet
drivers, and "wifi: " for wireless drivers in the text of the PRs.

2) For people doing backporting the driver names may not be meaningful,
but if I'm doing backports for a datacenter kernel I know to pay
attention to "eth:" while "wifi:" I can safely skip.

3) The case of this set - I have conversions for the entire tree queued
up on a branch, it's quite useful for me to use a common area-specific
prefix to see what goes were.

Anyway, that's just me rambling. I hope you don't mind if I send things
with a wifi prefix from time to time given it's a convenient way for me
to mark the queued patches.

> Feel free to take via your tree:
> 
> Acked-by: Kalle Valo <kvalo@kernel.org>

Actually I didn't cc netdev so would be easier if you could take them :)
I have to wait for RDMA/infiniband to get merged up before I can start
deleting stuff anyway :(
Kalle Valo May 6, 2022, 5:30 a.m. UTC | #3
Jakub Kicinski <kuba@kernel.org> writes:

>> Feel free to take via your tree:
>> 
>> Acked-by: Kalle Valo <kvalo@kernel.org>
>
> Actually I didn't cc netdev so would be easier if you could take them :)
> I have to wait for RDMA/infiniband to get merged up before I can start
> deleting stuff anyway :(

Ah sorry, I misunderstood. Then I'll take these to wireless-next.
Kalle Valo May 9, 2022, 11:14 a.m. UTC | #4
Jakub Kicinski <kuba@kernel.org> writes:

> On Thu, 05 May 2022 07:25:03 +0300 Kalle Valo wrote:
>> Jakub Kicinski <kuba@kernel.org> writes:
>> 
>> > Convert wifi callers to the new netif_napi_add() APIs.
>> >
>> > The callers passing 64 or NAPI_POLL_WEIGHT to the non-Tx flavor
>> > are left alone. I'm planning to include wifi drivers in the massive
>> > tree-wide patch/series which will drop the last argument from
>> > netif_napi_add(). Alternatively I can switch all of wifi to
>> > netif_napi_add_tx_weight() and back after the netif_napi_add()
>> > change makes its wait into wireless-next.
>> > Please LMK if you prefer that.
>> >
>> > Jakub Kicinski (3):
>> >   wifi: wil6210: switch to netif_napi_add_tx()
>> >   wifi: mt76: switch to netif_napi_add_tx()
>> >   wifi: qtnfmac: switch to netif_napi_add_weight()  
>> 
>> We don't use that "wifi:" prefix, otherwise looks good. 
>
> I know, my silent effort to make git log --oneline be more
> understandable for folks outside of networking is not really
> being met with much applause :) Ethernet people also don't
> like the "eth:" prefix..
>
> AFAICS drivers tend to use a format consisting of (numbers at 
> the top denoting commonality):
>
> 3    4       1       2
> net: vendor: driver: component: bla bla

To me that's almost like the full path. An example from wireless
drivers:

drivers/net/wireless/ath/ath11k/mac.c

net: wireless: ath: ath11k: mac: blah blah

Only the directory name "drivers" is missing from the path.

Wouldn't it be easier to modify the tools showing logs (like git log or
gitk) to add that to each commit, then people who want to see that can
enable the feature :)

> Driver name is the most common prefix. It is the most meaningful
> and natural for people working on the code. Not everyone is working 
> on the driver code, tho.

Sure, I understand that not everyone are developers. It's always a
balance.

> 1) When I send PRs to Linus I always wonder how much he can 
> make out of the shortlog. And if people throw "net:" into the mix
> whether it's still clear when something is "just" a driver bug vs
> a core bug affecting everyone. So I started using "eth: " for ethernet
> drivers, and "wifi: " for wireless drivers in the text of the PRs.
>
> 2) For people doing backporting the driver names may not be meaningful,
> but if I'm doing backports for a datacenter kernel I know to pay
> attention to "eth:" while "wifi:" I can safely skip.

Is there a specific reason why you use "wifi:" and not "wireless:"? I
admit the term wireless is not great for our 802.11 subsystem but that
has been used as long as I know.

> 3) The case of this set - I have conversions for the entire tree queued
> up on a branch, it's quite useful for me to use a common area-specific
> prefix to see what goes were.
>
> Anyway, that's just me rambling. I hope you don't mind if I send things
> with a wifi prefix from time to time given it's a convenient way for me
> to mark the queued patches.

I don't mind if you submit with "wifi:", it's easy to edit patches with
my patchwork script during commit :) And if there's a strong need I
think we can change our title scheme in wireless patches. This has come
before but I have always resisted due to extra work involved. To me most
important is consistency within wireless subsystem, if different
wireless drivers (and stack) use a different scheme when the logs will
become hard to read. So I would hope everyone can agree to the new
scheme.
Jakub Kicinski May 9, 2022, 4:33 p.m. UTC | #5
On Mon, 09 May 2022 14:14:02 +0300 Kalle Valo wrote:
> > 1) When I send PRs to Linus I always wonder how much he can 
> > make out of the shortlog. And if people throw "net:" into the mix
> > whether it's still clear when something is "just" a driver bug vs
> > a core bug affecting everyone. So I started using "eth: " for ethernet
> > drivers, and "wifi: " for wireless drivers in the text of the PRs.
> >
> > 2) For people doing backporting the driver names may not be meaningful,
> > but if I'm doing backports for a datacenter kernel I know to pay
> > attention to "eth:" while "wifi:" I can safely skip.  
> 
> Is there a specific reason why you use "wifi:" and not "wireless:"? I
> admit the term wireless is not great for our 802.11 subsystem but that
> has been used as long as I know.

Right, I take the liberty of using wifi in PR texts since it seems most
appropriate as none of the low range or WWAN drivers go via the
wireless tree.

> > 3) The case of this set - I have conversions for the entire tree queued
> > up on a branch, it's quite useful for me to use a common area-specific
> > prefix to see what goes were.
> >
> > Anyway, that's just me rambling. I hope you don't mind if I send things
> > with a wifi prefix from time to time given it's a convenient way for me
> > to mark the queued patches.  
> 
> I don't mind if you submit with "wifi:", it's easy to edit patches with
> my patchwork script during commit :) And if there's a strong need I
> think we can change our title scheme in wireless patches. This has come
> before but I have always resisted due to extra work involved. To me most
> important is consistency within wireless subsystem, if different
> wireless drivers (and stack) use a different scheme when the logs will
> become hard to read. So I would hope everyone can agree to the new
> scheme.

No need to change the scheme overall. What you use now is the most
prevalent in the tree so I'm probably overthinking.