Date: Tue, 21 Jul 2020 12:59:09 -0700 From: Chris <bsd-lists@BSDforge.com> To: <freebsd-wireless@freebsd.org>, freebsd-wireless <freebsd-wireless@freebsd.org> Subject: Re: regdomain.xml Message-ID: <f429089c012869afa7c875fa24e941f3@udns.ultimatedns.net> In-Reply-To: <CAJ-VmomofP8%2B5r1kWTvHXvgd-imERKLOMf_BiQaTY8M8bQCeCw@mail.gmail.com>
next in thread | previous in thread | raw e-mail | index | archive | help
On Tue, 21 Jul 2020 09:02:07 -0700 Adrian Chadd adrian=2Echadd@gmail=2Ecom said > hi! >=20 > On Tue, 21 Jul 2020 at 02:06, Aaron <notjanedeere@gmail=2Ecom> wrote: >=20 > > Howdy FreeBSD wireless mailing list, > > > > Looking to help, only item on this list > > (https://wiki=2Efreebsd=2Eorg/WiFi/TodoStuff) I'm competent to address is > > "net80211 regulatory"=2E I read the "regdomain" manpage =2E=2E=2E no help ther= e=2E > > >=20 > Yeah, it's =2E=2E=2Eold=2E :-0 >=20 >=20 > > > > My assumptions: > > > > * the data you're looking to clean up/update/refactor is > > "/etc/regdomain=2Exml"=2E > > * you have some idea what you want this file to look like afterwards > > (an example would be very helpful) > > * the information you want added is available somewhere (FCC site, > > IEEE site, =2E=2E=2E) > > >=20 > Luckily we can just use what's in the linux regulatory domain tables > because they've already done the work of scouring the regulatory sites fo= r > their information :-) >=20 >=20 > > > > If my assumptions are correct and no-one's already doing it, my > > questions are: > > > > * the regulatory database is indexed by SKU, rather than by country=2E > > So adding a new _country_ is actually rather annoyingly difficult=2E > > o There's a <country-codes> section that links to <rd>, so either > > someone's already done the work here or I need this item explai= ned=2E > > >=20 > The file is organised per-SKU; 'rd' is regulatory domain, not country=2E >=20 > * Change the regulatory database code to be indexed by something that > > isn't hard-coded, and have the "regulatory domain entry index" map > > _to_ an SKU where needed=2E > > o "regulatory database code" meaning <rd id=3D"=2E=2E=2E">? > > o Since SKU in this context is not a Stock Keeping Unit =2E=2E=2E > > definition please? > > >=20 > it /is/ stock keeping unit=2E Ok, so! >=20 > This database is an XML representation of the Atheros regulatory database= =2E > You can find that in sys/dev/ath/ath_hal/ah_regdomain/ or something simil= ar > under ath_hal=2E > It's organised per-SKU because the Atheros parts are kinda organised that > way=2E Eg, there are multiple japan codes because the japan rules state tha= t > older hardware doesn't need to work with newer rules, but newer hardware > does=2E So each respin of the japan regdomain rules created a new SKU=2E >=20 >=20 > * This lets me do useful things like _update the regulatory database_=2E=2E > > o When you refer to the "regulatory database", do you just mean > > "/etc/regdomain=2Exml"? And what updates are you trying to do > > that are currently difficult? > > >=20 > Well, it's a pain to update things :-) Eg, if I wanted to update the US I= 'd > have to go update all the FCC domains that the US can use=2E FCC is FCC > without DFS channels; FCC3 is FCC with DFS channels=2E It's just a lot of > work=2E >=20 > * extend it to support new frequency ranges (60GHZ, VHF white spaces); > > in KHz settings rather than MHz increments; > > o Current <freqband>s are in MHz, not hard to change them to KHz=2E > > Would obviously impact every program that reads the file =2E=2E=2E > > o If I understand correctly, adding new freq ranges is just data > > entry=2E If so, is there a link to the new frequency ranges you > > want added? > > >=20 > Whatever's in the linux regdomain database would be a good start=2E >=20 >=20 > > * add VHT flags and 80/80+80/160MHz wide channel widths=2E > > o More data entry=2E Link to the data you want added? > > >=20 > I've added it for FCC=2E You can see what work it was just to add them ther= e=2E > :-) >=20 >=20 > > If having me add data, refactor, change hierarchy, etc=2E is helpful let > > me know=2E If it sounds like there'll be too much handholding, no hard > > feelings=2E >=20 >=20 > I'm sure we can help out :-) >=20 > So, I'd really like to figure out how to simplify the regdomain=2Exml file=2E > But - we should come up with a firm plan first=2E Luckily this IS basically > all userland work=2E :-) >=20 +1 for the offer to dig in, Aaron! > What do others think? What should we do? I vote for recreating it as a CSV file=2E Would then be easier to work with and easy to convert to other formats -- json/xml/=2E=2E=2E You asked=2E ;-) >=20 >=20 >=20 > -adrian --Chris
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?f429089c012869afa7c875fa24e941f3>