'\" t .\" Title: regulatory_hint .\" Author: .\" Generator: DocBook XSL Stylesheets v1.79.1 .\" Date: January 2017 .\" Manual: Regulatory enforcement infrastructure .\" Source: Kernel Hackers Manual 4.8.15 .\" Language: English .\" .TH "REGULATORY_HINT" "9" "January 2017" "Kernel Hackers Manual 4\&.8\&." "Regulatory enforcement infrast" .\" ----------------------------------------------------------------- .\" * Define some portability stuff .\" ----------------------------------------------------------------- .\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ .\" http://bugs.debian.org/507673 .\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html .\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ .ie \n(.g .ds Aq \(aq .el .ds Aq ' .\" ----------------------------------------------------------------- .\" * set default formatting .\" ----------------------------------------------------------------- .\" disable hyphenation .nh .\" disable justification (adjust text to left margin only) .ad l .\" ----------------------------------------------------------------- .\" * MAIN CONTENT STARTS HERE * .\" ----------------------------------------------------------------- .SH "NAME" regulatory_hint \- driver hint to the wireless core a regulatory domain .SH "SYNOPSIS" .HP \w'int\ regulatory_hint('u .BI "int regulatory_hint(struct\ wiphy\ *\ " "wiphy" ", const\ char\ *\ " "alpha2" ");" .SH "ARGUMENTS" .PP \fIwiphy\fR .RS 4 the wireless device giving the hint (used only for reporting conflicts) .RE .PP \fIalpha2\fR .RS 4 the ISO/IEC 3166 alpha2 the driver claims its regulatory domain should be in\&. If \fIrd\fR is set this should be NULL\&. Note that if you set this to NULL you should still set rd\->alpha2 to some accepted alpha2\&. .RE .SH "DESCRIPTION" .PP Wireless drivers can use this function to hint to the wireless core what it believes should be the current regulatory domain by giving it an ISO/IEC 3166 alpha2 country code it knows its regulatory domain should be in or by providing a completely build regulatory domain\&. If the driver provides an ISO/IEC 3166 alpha2 userspace will be queried for a regulatory domain structure for the respective country\&. .PP The wiphy must have been registered to cfg80211 prior to this call\&. For cfg80211 drivers this means you must first use \fBwiphy_register\fR, for mac80211 drivers you must first use \fBieee80211_register_hw\fR\&. .PP Drivers should check the return value, its possible you can get an \-ENOMEM\&. .SH "RETURN" .PP 0 on success\&. \-ENOMEM\&. .SH "AUTHOR" .PP \fBJohannes Berg\fR <\&johannes@sipsolutions.net\&> .RS 4 Author. .RE .SH "COPYRIGHT" .br