diff options
| author | John W. Linville <linville@tuxdriver.com> | 2014-03-13 14:21:43 -0400 |
|---|---|---|
| committer | John W. Linville <linville@tuxdriver.com> | 2014-03-13 14:21:43 -0400 |
| commit | 42775a34d23027b19e984956a539448f5e7ff075 (patch) | |
| tree | e344340c7f0aed4c8faf7534fabbc64607a8e784 /include/linux | |
| parent | 433131ba03c511a84e1fda5669c70cf8b44702e1 (diff) | |
| parent | 4e3b3bcd81776527fa6f11624d68849de8c8802e (diff) | |
Merge branch 'master' of git://git.kernel.org/pub/scm/linux/kernel/git/linville/wireless-next into for-davem
Conflicts:
drivers/net/wireless/ath/ath9k/recv.c
Diffstat (limited to 'include/linux')
| -rw-r--r-- | include/linux/ieee80211.h | 36 | ||||
| -rw-r--r-- | include/linux/miscdevice.h | 1 | ||||
| -rw-r--r-- | include/linux/tty.h | 6 | ||||
| -rw-r--r-- | include/linux/wl12xx.h | 24 |
4 files changed, 26 insertions, 41 deletions
diff --git a/include/linux/ieee80211.h b/include/linux/ieee80211.h index 5f349355ee54..06299048c4f4 100644 --- a/include/linux/ieee80211.h +++ b/include/linux/ieee80211.h | |||
| @@ -2308,42 +2308,6 @@ static inline bool ieee80211_is_public_action(struct ieee80211_hdr *hdr, | |||
| 2308 | } | 2308 | } |
| 2309 | 2309 | ||
| 2310 | /** | 2310 | /** |
| 2311 | * ieee80211_dsss_chan_to_freq - get channel center frequency | ||
| 2312 | * @channel: the DSSS channel | ||
| 2313 | * | ||
| 2314 | * Convert IEEE802.11 DSSS channel to the center frequency (MHz). | ||
| 2315 | * Ref IEEE 802.11-2007 section 15.6 | ||
| 2316 | */ | ||
| 2317 | static inline int ieee80211_dsss_chan_to_freq(int channel) | ||
| 2318 | { | ||
| 2319 | if ((channel > 0) && (channel < 14)) | ||
| 2320 | return 2407 + (channel * 5); | ||
| 2321 | else if (channel == 14) | ||
| 2322 | return 2484; | ||
| 2323 | else | ||
| 2324 | return -1; | ||
| 2325 | } | ||
| 2326 | |||
| 2327 | /** | ||
| 2328 | * ieee80211_freq_to_dsss_chan - get channel | ||
| 2329 | * @freq: the frequency | ||
| 2330 | * | ||
| 2331 | * Convert frequency (MHz) to IEEE802.11 DSSS channel | ||
| 2332 | * Ref IEEE 802.11-2007 section 15.6 | ||
| 2333 | * | ||
| 2334 | * This routine selects the channel with the closest center frequency. | ||
| 2335 | */ | ||
| 2336 | static inline int ieee80211_freq_to_dsss_chan(int freq) | ||
| 2337 | { | ||
| 2338 | if ((freq >= 2410) && (freq < 2475)) | ||
| 2339 | return (freq - 2405) / 5; | ||
| 2340 | else if ((freq >= 2482) && (freq < 2487)) | ||
| 2341 | return 14; | ||
| 2342 | else | ||
| 2343 | return -1; | ||
| 2344 | } | ||
| 2345 | |||
| 2346 | /** | ||
| 2347 | * ieee80211_tu_to_usec - convert time units (TU) to microseconds | 2311 | * ieee80211_tu_to_usec - convert time units (TU) to microseconds |
| 2348 | * @tu: the TUs | 2312 | * @tu: the TUs |
| 2349 | */ | 2313 | */ |
diff --git a/include/linux/miscdevice.h b/include/linux/miscdevice.h index 3737f7218f51..7bb6148d990f 100644 --- a/include/linux/miscdevice.h +++ b/include/linux/miscdevice.h | |||
| @@ -23,6 +23,7 @@ | |||
| 23 | #define TEMP_MINOR 131 /* Temperature Sensor */ | 23 | #define TEMP_MINOR 131 /* Temperature Sensor */ |
| 24 | #define RTC_MINOR 135 | 24 | #define RTC_MINOR 135 |
| 25 | #define EFI_RTC_MINOR 136 /* EFI Time services */ | 25 | #define EFI_RTC_MINOR 136 /* EFI Time services */ |
| 26 | #define VHCI_MINOR 137 | ||
| 26 | #define SUN_OPENPROM_MINOR 139 | 27 | #define SUN_OPENPROM_MINOR 139 |
| 27 | #define DMAPI_MINOR 140 /* DMAPI */ | 28 | #define DMAPI_MINOR 140 /* DMAPI */ |
| 28 | #define NVRAM_MINOR 144 | 29 | #define NVRAM_MINOR 144 |
diff --git a/include/linux/tty.h b/include/linux/tty.h index 90b4fdc8a61f..4781d7b27dd3 100644 --- a/include/linux/tty.h +++ b/include/linux/tty.h | |||
| @@ -518,9 +518,9 @@ extern void tty_port_put(struct tty_port *port); | |||
| 518 | 518 | ||
| 519 | static inline struct tty_port *tty_port_get(struct tty_port *port) | 519 | static inline struct tty_port *tty_port_get(struct tty_port *port) |
| 520 | { | 520 | { |
| 521 | if (port) | 521 | if (port && kref_get_unless_zero(&port->kref)) |
| 522 | kref_get(&port->kref); | 522 | return port; |
| 523 | return port; | 523 | return NULL; |
| 524 | } | 524 | } |
| 525 | 525 | ||
| 526 | /* If the cts flow control is enabled, return true. */ | 526 | /* If the cts flow control is enabled, return true. */ |
diff --git a/include/linux/wl12xx.h b/include/linux/wl12xx.h index a54fe82e704b..a9c723be1acf 100644 --- a/include/linux/wl12xx.h +++ b/include/linux/wl12xx.h | |||
| @@ -48,11 +48,15 @@ enum { | |||
| 48 | WL12XX_TCXOCLOCK_33_6 = 7, /* 33.6 MHz */ | 48 | WL12XX_TCXOCLOCK_33_6 = 7, /* 33.6 MHz */ |
| 49 | }; | 49 | }; |
| 50 | 50 | ||
| 51 | struct wl12xx_platform_data { | 51 | struct wl1251_platform_data { |
| 52 | void (*set_power)(bool enable); | 52 | int power_gpio; |
| 53 | /* SDIO only: IRQ number if WLAN_IRQ line is used, 0 for SDIO IRQs */ | 53 | /* SDIO only: IRQ number if WLAN_IRQ line is used, 0 for SDIO IRQs */ |
| 54 | int irq; | 54 | int irq; |
| 55 | bool use_eeprom; | 55 | bool use_eeprom; |
| 56 | }; | ||
| 57 | |||
| 58 | struct wl12xx_platform_data { | ||
| 59 | int irq; | ||
| 56 | int board_ref_clock; | 60 | int board_ref_clock; |
| 57 | int board_tcxo_clock; | 61 | int board_tcxo_clock; |
| 58 | unsigned long platform_quirks; | 62 | unsigned long platform_quirks; |
| @@ -68,6 +72,10 @@ int wl12xx_set_platform_data(const struct wl12xx_platform_data *data); | |||
| 68 | 72 | ||
| 69 | struct wl12xx_platform_data *wl12xx_get_platform_data(void); | 73 | struct wl12xx_platform_data *wl12xx_get_platform_data(void); |
| 70 | 74 | ||
| 75 | int wl1251_set_platform_data(const struct wl1251_platform_data *data); | ||
| 76 | |||
| 77 | struct wl1251_platform_data *wl1251_get_platform_data(void); | ||
| 78 | |||
| 71 | #else | 79 | #else |
| 72 | 80 | ||
| 73 | static inline | 81 | static inline |
| @@ -82,6 +90,18 @@ struct wl12xx_platform_data *wl12xx_get_platform_data(void) | |||
| 82 | return ERR_PTR(-ENODATA); | 90 | return ERR_PTR(-ENODATA); |
| 83 | } | 91 | } |
| 84 | 92 | ||
| 93 | static inline | ||
| 94 | int wl1251_set_platform_data(const struct wl1251_platform_data *data) | ||
| 95 | { | ||
| 96 | return -ENOSYS; | ||
| 97 | } | ||
| 98 | |||
| 99 | static inline | ||
| 100 | struct wl1251_platform_data *wl1251_get_platform_data(void) | ||
| 101 | { | ||
| 102 | return ERR_PTR(-ENODATA); | ||
| 103 | } | ||
| 104 | |||
| 85 | #endif | 105 | #endif |
| 86 | 106 | ||
| 87 | #endif | 107 | #endif |
