diff options
author | Johannes Berg <johannes@sipsolutions.net> | 2008-10-24 14:32:21 -0400 |
---|---|---|
committer | John W. Linville <linville@tuxdriver.com> | 2008-10-31 19:02:30 -0400 |
commit | be3d48106c1e5d075784e5e67928a6b5ffc0f3b6 (patch) | |
tree | 40f9a5d6beefa0f6812f06368a94f0b17658f247 /include/net | |
parent | d2372b315289aec9f565a855023c40654a5bff68 (diff) |
wireless: remove struct regdom hinting
The code needs to be split out and cleaned up, so as a
first step remove the capability, to add it back in a
subsequent patch as a separate function. Also remove the
publically facing return value of the function and the
wiphy argument. A number of internal functions go from
being generic helpers to just being used for alpha2
setting.
Signed-off-by: Johannes Berg <johannes@sipsolutions.net>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
Diffstat (limited to 'include/net')
-rw-r--r-- | include/net/wireless.h | 23 |
1 files changed, 4 insertions, 19 deletions
diff --git a/include/net/wireless.h b/include/net/wireless.h index 6e3ea0159045..41294c5f6f8f 100644 --- a/include/net/wireless.h +++ b/include/net/wireless.h | |||
@@ -342,34 +342,19 @@ ieee80211_get_channel(struct wiphy *wiphy, int freq) | |||
342 | 342 | ||
343 | /** | 343 | /** |
344 | * regulatory_hint - driver hint to the wireless core a regulatory domain | 344 | * regulatory_hint - driver hint to the wireless core a regulatory domain |
345 | * @wiphy: the driver's very own &struct wiphy | 345 | * @wiphy: the wireless device giving the hint (used only for reporting |
346 | * conflicts) | ||
346 | * @alpha2: the ISO/IEC 3166 alpha2 the driver claims its regulatory domain | 347 | * @alpha2: the ISO/IEC 3166 alpha2 the driver claims its regulatory domain |
347 | * should be in. If @rd is set this should be NULL. Note that if you | 348 | * should be in. If @rd is set this should be NULL. Note that if you |
348 | * set this to NULL you should still set rd->alpha2 to some accepted | 349 | * set this to NULL you should still set rd->alpha2 to some accepted |
349 | * alpha2. | 350 | * alpha2. |
350 | * @rd: a complete regulatory domain provided by the driver. If passed | ||
351 | * the driver does not need to worry about freeing it. | ||
352 | * | 351 | * |
353 | * Wireless drivers can use this function to hint to the wireless core | 352 | * Wireless drivers can use this function to hint to the wireless core |
354 | * what it believes should be the current regulatory domain by | 353 | * what it believes should be the current regulatory domain by |
355 | * giving it an ISO/IEC 3166 alpha2 country code it knows its regulatory | 354 | * giving it an ISO/IEC 3166 alpha2 country code it knows its regulatory |
356 | * domain should be in or by providing a completely build regulatory domain. | 355 | * domain should be in or by providing a completely build regulatory domain. |
357 | * If the driver provides an ISO/IEC 3166 alpha2 userspace will be queried | 356 | * If the driver provides an ISO/IEC 3166 alpha2 userspace will be queried |
358 | * for a regulatory domain structure for the respective country. If | 357 | * for a regulatory domain structure for the respective country. |
359 | * a regulatory domain is build and passed you should set the alpha2 | ||
360 | * if possible, otherwise set it to the special value of "99" which tells | ||
361 | * the wireless core it is unknown. | ||
362 | * | ||
363 | * Returns -EALREADY if *a regulatory domain* has already been set. Note that | ||
364 | * this could be by another driver. It is safe for drivers to continue if | ||
365 | * -EALREADY is returned, if drivers are not capable of world roaming they | ||
366 | * should not register more channels than they support. Right now we only | ||
367 | * support listening to the first driver hint. If the driver is capable | ||
368 | * of world roaming but wants to respect its own EEPROM mappings for | ||
369 | * specific regulatory domains it should register the @reg_notifier callback | ||
370 | * on the &struct wiphy. Returns 0 if the hint went through fine or through an | ||
371 | * intersection operation. Otherwise a standard error code is returned. | ||
372 | */ | 358 | */ |
373 | extern int regulatory_hint(struct wiphy *wiphy, | 359 | extern void regulatory_hint(struct wiphy *wiphy, const char *alpha2); |
374 | const char *alpha2, struct ieee80211_regdomain *rd); | ||
375 | #endif /* __NET_WIRELESS_H */ | 360 | #endif /* __NET_WIRELESS_H */ |