From: Johannes Berg <johannes@sipsolutions.net>
To: "Hodaszi, Robert" <Robert.Hodaszi@digi.com>
Cc: "linux-wireless@vger.kernel.org" <linux-wireless@vger.kernel.org>
Subject: Re: [PATCH v2] Revert "cfg80211: fix processing world regdomain when non modular"
Date: Fri, 14 Jun 2019 15:30:57 +0200 [thread overview]
Message-ID: <ebab80c3f632f792373bfcace252c7a1bf65ce89.camel@sipsolutions.net> (raw)
In-Reply-To: <20190614131600.GA13897@a1-hr>
On Fri, 2019-06-14 at 13:16 +0000, Hodaszi, Robert wrote:
> This reverts commit 96cce12ff6e0bc9d9fcb2235e08b7fc150f96fd2.
>
> Re-triggering a reg_process_hint with the last request on all events,
> can make the regulatory domain fail in case of multiple WiFi modules. On
> slower boards (espacially with mdev), enumeration of the WiFi modules
> can end up in an intersected regulatory domain, and user cannot set it
> with 'iw reg set' anymore.
>
> This is happening, because:
> - 1st module enumerates, queues up a regulatory request
> - request gets processed by __reg_process_hint_driver():
> - checks if previous was set by CORE -> yes
> - checks if regulator domain changed -> yes, from '00' to e.g. 'US'
> -> sends request to the 'crda'
> - 2nd module enumerates, queues up a regulator request (which triggers
> the reg_todo() work)
> - reg_todo() -> reg_process_pending_hints() sees, that the last request
> is not processed yet, so it tries to process it again.
> __reg_process_hint driver() will run again, and:
> - checks if the last request's initiator was the core -> no, it was
> the driver (1st WiFi module)
> - checks, if the previous initiator was the driver -> yes
> - checks if the regulator domain changed -> yes, it was '00' (set by
> core, and crda call did not return yet), and should be changed to 'US'
>
> ------> __reg_process_hint_driver calls an intersect
>
> Besides, the reg_process_hint call with the last request is meaningless
> since the crda call has a timeout work. If that timeout expires, the
> first module's request will lost.
It's pointless to resend when I still have the original patch pending,
at least without any changes.
That said, I looked at this today and I'm not sure how the code doesn't
now have the original issue again?
johannes
next prev parent reply other threads:[~2019-06-14 13:31 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2019-06-14 13:16 [PATCH v2] Revert "cfg80211: fix processing world regdomain when non modular" Hodaszi, Robert
2019-06-14 13:30 ` Johannes Berg [this message]
2019-06-14 13:58 ` Hodaszi, Robert
2019-06-14 14:01 ` Johannes Berg
2019-06-14 14:06 ` Hodaszi, Robert
2019-06-20 7:48 ` Kalle Valo
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=ebab80c3f632f792373bfcace252c7a1bf65ce89.camel@sipsolutions.net \
--to=johannes@sipsolutions.net \
--cc=Robert.Hodaszi@digi.com \
--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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).