1 .\" Copyright (c) 2015 Adrian Chadd.
2 .\" All rights reserved.
4 .\" Redistribution and use in source and binary forms, with or without
5 .\" modification, are permitted provided that the following conditions
7 .\" 1. Redistributions of source code must retain the above copyright
8 .\" notice, this list of conditions and the following disclaimer.
9 .\" 2. Redistributions in binary form must reproduce the above copyright
10 .\" notice, this list of conditions and the following disclaimer in the
11 .\" documentation and/or other materials provided with the distribution.
13 .\" THIS SOFTWARE IS PROVIDED BY THE AUTHOR AND CONTRIBUTORS ``AS IS'' AND
14 .\" ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
15 .\" IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
16 .\" ARE DISCLAIMED. IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE
17 .\" FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
18 .\" DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
19 .\" OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
20 .\" HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
21 .\" LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
22 .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
29 .Nm lib80211_alloc_regdata ,
30 .Nm lib80211_free_regdata ,
31 .Nm lib80211_regdomain_readconfig ,
32 .Nm lib80211_regdomain_cleanup ,
33 .Nm lib80211_regdomain_findbysku ,
34 .Nm lib80211_regdomain_findbyname ,
35 .Nm lib80211_country_findbycc ,
36 .Nm lib80211_country_findbyname
37 .Nd manage net80211 configuration and regulatory database
41 .In lib80211/lib80211_regdomain.h
42 .In lib80211/lib80211_ioctl.h
44 .Fn lib80211_alloc_regdata void
46 .Fn lib80211_free_regdata "struct regdata *reg"
48 .Fn lib80211_regdomain_readconfig "struct regdata *reg" "const void *config" "size_t size"
50 .Fn lib80211_regdomain_cleanup "struct regdata *reg"
51 .Ft const struct regdomain *
52 .Fn lib80211_regdomain_findbysku "const struct regdata *reg" "enumRegDomainCode"
53 .Ft const struct regdomain *
54 .Fn lib80211_regdomain_findbyname "const struct regdata *reg" "const char *sku"
55 .Ft const struct country *
56 .Fn lib80211_country_findbycc "const struct regdata *reg" "enum ISOCountryCode"
57 .Ft const struct country *
58 .Fn lib80211_country_findbyname "const struct regdata *reg" "const char *cc"
62 library is an interface to the
65 It implements wrappers around the
67 ioctl command, as well as providing a convenient API to access the regulatory
71 .Fn lib80211_alloc_regdata
73 .Fn lib80211_free_regdata
74 function allocates / frees a regdata structure to store regulatory domain
78 .Fn lib80211_regdomain_readconfig
80 .Fn lib80211_regdomain_cleanup
81 functions read in the regulatory database XML configuration and free it when
85 .Fn lib80211_regdomain_findbysku
87 .Fn lib80211_regdomain_findbyname
88 functions look up a regulatory domain entry by SKU enum and SKU name
92 .Fn lib80211_country_findbycc
94 .Fn lib80211_country_findbyname
95 functions look up a country information entry by ISO country enum and
96 ISO country code string respectively.
99 .Fn lib80211_alloc_regdata ,
100 .Fn lib80211_regdomain_readconfig ,
101 .Fn lib80211_regdomain_findbysku ,
102 .Fn lib80211_regdomain_findbyname ,
103 .Fn lib80211_country_findbycc ,
104 .Fn lib80211_country_findbyname
114 library first appeared in