Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > linux.kernel > #1578214
| From | Adrian Chadd <adrian@freebsd.org> |
|---|---|
| Newsgroups | linux.kernel |
| Subject | Re: [PATCH 1/3] ath10k: remove ath10k_vif_to_arvif() |
| Date | 2017-02-10 08:20 +0100 |
| Message-ID | <t9dES-jp-9@gated-at.bofh.it> (permalink) |
| References | <t6mOm-2Do-7@gated-at.bofh.it> <t6sh4-6ho-25@gated-at.bofh.it> <t8a6m-VT-19@gated-at.bofh.it> <t8ffH-49n-11@gated-at.bofh.it> <t9dvc-fW-39@gated-at.bofh.it> |
| Organization | linux.* mail to news gateway |
On 9 February 2017 at 23:03, Valo, Kalle <kvalo@qca.qualcomm.com> wrote: > Ben Greear <greearb@candelatech.com> writes: > >> On 02/07/2017 01:14 AM, Valo, Kalle wrote: >>> Adrian Chadd <adrian@freebsd.org> writes: >>> >>>> Removing this method makes the diff to FreeBSD larger, as "vif" in >>>> FreeBSD is a different pointer. >>>> >>>> (Yes, I have ath10k on freebsd working and I'd like to find a way to >>>> reduce the diff moving forward.) >>> >>> I don't like this "(void *) vif->drv_priv" style that much either but >>> apparently it's commonly used in Linux wireless code and already parts >>> of ath10k. So this patch just unifies the coding style. >> >> Surely the code compiles to the same thing, so why add a patch that >> makes it more difficult for Adrian and makes the code no easier to read >> for the rest of us? > > Because that's the coding style used already in Linux. It's great to see > that parts of ath10k can be used also in other systems but in principle > I'm not very fond of the idea starting to reject valid upstream patches > because of driver forks. > > I think backports project is doing it right, it's not limiting upstream > development in any way and handles all the API changes internally. Maybe > FreeBSD could do something similar? I tried, but ... well, imagine renaming vif->drv_priv to something else. That's what you're suggesting. :-) You can do it with coccinelle, but not via just backports API implementations. I'm a big fan of light weight accessor APIs for the same reason. (Since FreeBSD doesn't have that pointer in ieee80211vap, it's done a different way.) If you could convert other direct uses over to ath10k_vif_to_arvif() then that'd make me happier. If not, it's fine, when I push this into freebsd and fast-forward commits, I'll have to just maintain it. For what it's worth - the linux skb accessors are the same. If there were accessors for the skb data / len fields (like we do for mbufs) then porting the code would've involved about 5,000 less changed lines. -adrian
Back to linux.kernel | Previous | Next — Previous in thread | Next in thread | Find similar | Unroll thread
[PATCH 1/3] ath10k: remove ath10k_vif_to_arvif() Amadeusz Sławiński <amadeusz.slawinski@tieto.com> - 2017-02-02 11:30 +0100
[PATCH 3/3] ath10k: fix comment Amadeusz Sławiński <amadeusz.slawinski@tieto.com> - 2017-02-02 11:30 +0100
Re: [PATCH 1/3] ath10k: remove ath10k_vif_to_arvif() Adrian Chadd <adrian@freebsd.org> - 2017-02-02 17:20 +0100
Re: [PATCH 1/3] ath10k: remove ath10k_vif_to_arvif() "Valo, Kalle" <kvalo@qca.qualcomm.com> - 2017-02-07 10:20 +0100
Re: [PATCH 1/3] ath10k: remove ath10k_vif_to_arvif() Ben Greear <greearb@candelatech.com> - 2017-02-07 15:50 +0100
Re: [PATCH 1/3] ath10k: remove ath10k_vif_to_arvif() "Valo, Kalle" <kvalo@qca.qualcomm.com> - 2017-02-10 08:10 +0100
Re: [PATCH 1/3] ath10k: remove ath10k_vif_to_arvif() Adrian Chadd <adrian@freebsd.org> - 2017-02-10 08:20 +0100
Re: [PATCH 1/3] ath10k: remove ath10k_vif_to_arvif() Joe Perches <joe@perches.com> - 2017-02-10 08:40 +0100
Re: [PATCH 1/3] ath10k: remove ath10k_vif_to_arvif() Adrian Chadd <adrian@freebsd.org> - 2017-02-10 16:40 +0100
Re: [PATCH 1/3] ath10k: remove ath10k_vif_to_arvif() Ben Greear <greearb@candelatech.com> - 2017-02-10 18:40 +0100
csiph-web