From: Kalle Valo <kvalo@kernel.org>
To: "Jérôme Pouiller" <jerome.pouiller@silabs.com>
Cc: linux-wireless@vger.kernel.org, linux-kernel@vger.kernel.org
Subject: Re: [PATCH v2 1/9] wifi: wfx: fix power_save setting when AP is stopped
Date: Wed, 04 Oct 2023 14:30:45 +0300 [thread overview]
Message-ID: <877co27hga.fsf@kernel.org> (raw)
In-Reply-To: <14139521.lVVuGzaMjS@pc-42> ("Jérôme Pouiller"'s message of "Wed, 04 Oct 2023 12:37:02 +0200")
Jérôme Pouiller <jerome.pouiller@silabs.com> writes:
> Hi Kalle,
>
> On Wednesday 4 October 2023 12:20:12 CEST Kalle Valo wrote:
>>
>> Jérôme Pouiller <jerome.pouiller@silabs.com> writes:
>>
>> > The WF200 allow to start two network interfaces (one AP, one station) on
>> > two different channels. Since magic does not exist, it only works if the
>> > station interface enables power save.
>> >
>> > Thus, the driver detects this case and enforce power save as necessary.
>> >
>> > This patch fixes the case where the AP interface is stopped and it is no
>> > more necessary to enforce power saving on the station interface.
>> >
>> > Signed-off-by: Jérôme Pouiller <jerome.pouiller@silabs.com>
>> > ---
>> > drivers/net/wireless/silabs/wfx/sta.c | 5 +++++
>> > 1 file changed, 5 insertions(+)
>> >
>> > diff --git a/drivers/net/wireless/silabs/wfx/sta.c b/drivers/net/wireless/silabs/wfx/sta.c
>> > index 626dfb4b7a55d..9c0a11c277e97 100644
>> > --- a/drivers/net/wireless/silabs/wfx/sta.c
>> > +++ b/drivers/net/wireless/silabs/wfx/sta.c
>> > @@ -402,7 +402,12 @@ void wfx_stop_ap(struct ieee80211_hw *hw, struct ieee80211_vif *vif,
>> > struct ieee80211_bss_conf *link_conf)
>> > {
>> > struct wfx_vif *wvif = (struct wfx_vif *)vif->drv_priv;
>> > + struct wfx_dev *wdev = wvif->wdev;
>> >
>> > + wvif = NULL;
>> > + while ((wvif = wvif_iterate(wdev, wvif)) != NULL)
>> > + wfx_update_pm(wvif);
>>
>> Isn't the assignment of wvif to NULL unnecessary as in the next line we
>> assign it to again?
>
> wvif is also passed as argument to wvif_iterate(). wvif_iterate() uses this
> parameter to know where the iteration has stopped on previous call.
Ah, I missed that.
> However, the assignation during the declaration of wvif is useless.
Indeed, missed that as well.
--
https://patchwork.kernel.org/project/linux-wireless/list/
https://wireless.wiki.kernel.org/en/developers/documentation/submittingpatches
next prev parent reply other threads:[~2023-10-04 11:30 UTC|newest]
Thread overview: 16+ messages / expand[flat|nested] mbox.gz Atom feed top
2023-09-27 16:32 [PATCH v2 0/9] wfx: implement Remain On Channel Jérôme Pouiller
2023-09-27 16:32 ` [PATCH v2 1/9] wifi: wfx: fix power_save setting when AP is stopped Jérôme Pouiller
2023-10-04 10:20 ` Kalle Valo
2023-10-04 10:37 ` Jérôme Pouiller
2023-10-04 11:30 ` Kalle Valo [this message]
2023-10-04 17:26 ` Jérôme Pouiller
2023-09-27 16:32 ` [PATCH v2 2/9] wifi: wfx: relocate wfx_rate_mask_to_hw() Jérôme Pouiller
2023-09-27 16:32 ` [PATCH v2 3/9] wifi: wfx: move wfx_skb_*() out of the header file Jérôme Pouiller
2023-09-27 16:32 ` [PATCH v2 4/9] wifi: wfx: introduce hif_scan_uniq() Jérôme Pouiller
2023-09-27 16:32 ` [PATCH v2 5/9] wifi: wfx: add placeholders for remain_on_channel feature Jérôme Pouiller
2023-10-04 10:23 ` Kalle Valo
2023-10-04 10:40 ` Jérôme Pouiller
2023-09-27 16:32 ` [PATCH v2 6/9] wifi: wfx: implement wfx_remain_on_channel() Jérôme Pouiller
2023-09-27 16:32 ` [PATCH v2 7/9] wifi: wfx: allow to send frames during ROC Jérôme Pouiller
2023-09-27 16:32 ` [PATCH v2 8/9] wifi: wfx: scan_lock is global to the device Jérôme Pouiller
2023-09-27 16:32 ` [PATCH v2 9/9] wifi: wfx: fix possible lock-up between scan and Rx filters Jérôme Pouiller
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=877co27hga.fsf@kernel.org \
--to=kvalo@kernel.org \
--cc=jerome.pouiller@silabs.com \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-wireless@vger.kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.