Search Linux Wireless

RE: [EXT] Re: [PATCH v8 1/2] wifi: mwifiex: add host mlme for client mode

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



> From: David Lin
> Sent: Thursday, February 29, 2024 11:53 AM
> To: 'Francesco Dolcini' <francesco@xxxxxxxxxx>
> Cc: linux-wireless@xxxxxxxxxxxxxxx; linux-kernel@xxxxxxxxxxxxxxx;
> briannorris@xxxxxxxxxxxx; kvalo@xxxxxxxxxx; Pete Hsieh
> <tsung-hsien.hsieh@xxxxxxx>
> Subject: RE: [EXT] Re: [PATCH v8 1/2] wifi: mwifiex: add host mlme for client
> mode
> 
> > From: Francesco Dolcini <francesco@xxxxxxxxxx>
> > Sent: Wednesday, February 28, 2024 1:53 AM
> > To: David Lin <yu-hao.lin@xxxxxxx>
> > Cc: linux-wireless@xxxxxxxxxxxxxxx; linux-kernel@xxxxxxxxxxxxxxx;
> > briannorris@xxxxxxxxxxxx; kvalo@xxxxxxxxxx; francesco@xxxxxxxxxx; Pete
> > Hsieh <tsung-hsien.hsieh@xxxxxxx>
> > Subject: [EXT] Re: [PATCH v8 1/2] wifi: mwifiex: add host mlme for
> > client mode
> >
> > Caution: This is an external email. Please take care when clicking
> > links or opening attachments. When in doubt, report the message using
> > the 'Report this email' button
> >
> >
> > On Fri, Dec 22, 2023 at 11:21:22AM +0800, David Lin wrote:
> > > Add host based MLME to enable WPA3 functionalities in client mode.
> > > This feature required a firmware with the corresponding V2 Key API
> > > support. The feature (WPA3) is currently enabled and verified only
> > > on IW416. Also, verified no regression with change when host MLME is
> > > disabled.
> > >
> > > Signed-off-by: David Lin <yu-hao.lin@xxxxxxx>
> >
> > Currently this do not apply cleanly on wireless-next/main git tree, it
> > should be rebased to that branch as v9 (the reason is your addition of
> > fw_ready_extra_delay from a previous, now merged, patch).
> >
> > In general the patch looks good to me, however I am no expert on
> > wireless driver or the related linux subsystem. I just have a couple
> > of small comments that I would suggest address in v9 (given that you
> > need to do it as a minimum to rebase your code).
> >
> 
> Yes. Will rebase and create patch v9.
> 
> >
> > > ---
> > >  .../net/wireless/marvell/mwifiex/cfg80211.c   | 315
> > ++++++++++++++++++
> > >  drivers/net/wireless/marvell/mwifiex/cmdevt.c |  25 ++
> > >  drivers/net/wireless/marvell/mwifiex/decl.h   |  22 ++
> > >  drivers/net/wireless/marvell/mwifiex/fw.h     |  33 ++
> > >  drivers/net/wireless/marvell/mwifiex/init.c   |   6 +
> > >  drivers/net/wireless/marvell/mwifiex/join.c   |  66 +++-
> > >  drivers/net/wireless/marvell/mwifiex/main.c   |  54 +++
> > >  drivers/net/wireless/marvell/mwifiex/main.h   |  17 +
> > >  drivers/net/wireless/marvell/mwifiex/scan.c   |   6 +
> > >  drivers/net/wireless/marvell/mwifiex/sdio.c   |  13 +
> > >  drivers/net/wireless/marvell/mwifiex/sdio.h   |   2 +
> > >  .../net/wireless/marvell/mwifiex/sta_event.c  |  36 +-
> > >  .../net/wireless/marvell/mwifiex/sta_ioctl.c  |   3 +-
> > >  drivers/net/wireless/marvell/mwifiex/sta_tx.c |   9 +-
> > >  drivers/net/wireless/marvell/mwifiex/util.c   |  80 +++++
> > >  15 files changed, 673 insertions(+), 14 deletions(-)
> > >
> > > diff --git a/drivers/net/wireless/marvell/mwifiex/cfg80211.c
> > > b/drivers/net/wireless/marvell/mwifiex/cfg80211.c
> > > index 7a15ea8072e6..3cee1b58465e 100644
> > > --- a/drivers/net/wireless/marvell/mwifiex/cfg80211.c
> > > +++ b/drivers/net/wireless/marvell/mwifiex/cfg80211.c
> > > @@ -4202,6 +4208,302 @@ mwifiex_cfg80211_change_station(struct
> > wiphy
> > > *wiphy, struct net_device *dev,
> >
> > ...
> >
> > > +static int
> > > +mwifiex_cfg80211_probe_client(struct wiphy *wiphy,
> > > +                           struct net_device *dev, const u8 *peer,
> > > +                           u64 *cookie) {
> > > +     return -1;
> >
> > See my following comment on this
> >
> > > +}
> > > +
> > >  /* station cfg80211 operations */
> > >  static struct cfg80211_ops mwifiex_cfg80211_ops = {
> > >       .add_virtual_intf = mwifiex_add_virtual_intf, @@ -4347,6
> > > +4649,16 @@ int mwifiex_register_cfg80211(struct mwifiex_adapter
> > *adapter)
> > >                           "%s: creating new wiphy\n", __func__);
> > >               return -ENOMEM;
> > >       }
> > > +     if (adapter->host_mlme_enabled) {
> > > +             mwifiex_cfg80211_ops.auth =
> > mwifiex_cfg80211_authenticate;
> > > +             mwifiex_cfg80211_ops.assoc =
> > mwifiex_cfg80211_associate;
> > > +             mwifiex_cfg80211_ops.deauth =
> > mwifiex_cfg80211_deauthenticate;
> > > +             mwifiex_cfg80211_ops.disassoc =
> > mwifiex_cfg80211_disassociate;
> > > +             mwifiex_cfg80211_ops.disconnect = NULL;
> > > +             mwifiex_cfg80211_ops.connect = NULL;
> > > +             mwifiex_cfg80211_ops.probe_client =
> > > +                     mwifiex_cfg80211_probe_client;
> >
> > Can you omit this one? You should get `-EOPNOTSUPP` for free with
> > probe_client set to NULL. Am I wrong?
> >
> 
> Yes. You are right. Remove in patch v9.
> 

This function must be hooked, otherwise AP mode can't work. I will hook this function as before but return -EOPNOTSUPP instead.
Patch v9 is almost done and will be submitted later. Thanks for your suggestion.

> > > +     }
> > >       wiphy->max_scan_ssids = MWIFIEX_MAX_SSID_LIST_LENGTH;
> > >       wiphy->max_scan_ie_len = MWIFIEX_MAX_VSIE_LEN;
> > >       wiphy->mgmt_stypes = mwifiex_mgmt_stypes;
> >
> > ...
> >
> > > diff --git a/drivers/net/wireless/marvell/mwifiex/sta_ioctl.c
> > > b/drivers/net/wireless/marvell/mwifiex/sta_ioctl.c
> > > index a2ad2b53f016..23639aacf092 100644
> > > --- a/drivers/net/wireless/marvell/mwifiex/sta_ioctl.c
> > > +++ b/drivers/net/wireless/marvell/mwifiex/sta_ioctl.c
> > > @@ -136,6 +136,7 @@ int mwifiex_fill_new_bss_desc(struct
> > mwifiex_private *priv,
> > >       const struct cfg80211_bss_ies *ies;
> > >
> > >       rcu_read_lock();
> > > +     bss_desc->bss = bss;
> > what is this change for? I was not able to understand it, nor to find
> > any user of this bss parameter. This looks like an unrelated fix, but
> > no code seems to be affected.
> >
> Yes. It will be removed in patch v9.
> 
> >
> > With these 2 comments addressed, please feel free to add to v9
> >
> > Reviewed-by: Francesco Dolcini <francesco.dolcini@xxxxxxxxxxx>
> >
> >
> > And thanks for this work!
> > Francesco





[Index of Archives]     [Linux Host AP]     [ATH6KL]     [Linux Wireless Personal Area Network]     [Linux Bluetooth]     [Wireless Regulations]     [Linux Netdev]     [Kernel Newbies]     [Linux Kernel]     [IDE]     [Git]     [Netfilter]     [Bugtraq]     [Yosemite Hiking]     [MIPS Linux]     [ARM Linux]     [Linux RAID]

  Powered by Linux