diff options
-rw-r--r-- | drivers/net/wireless/rt2x00/rt2800lib.c | 48 | ||||
-rw-r--r-- | drivers/net/wireless/rt2x00/rt2800lib.h | 10 | ||||
-rw-r--r-- | drivers/net/wireless/rt2x00/rt2800pci.c | 24 | ||||
-rw-r--r-- | drivers/net/wireless/rt2x00/rt2800usb.c | 24 |
4 files changed, 69 insertions, 37 deletions
diff --git a/drivers/net/wireless/rt2x00/rt2800lib.c b/drivers/net/wireless/rt2x00/rt2800lib.c index 55727328e227..64bfa6e6a4e5 100644 --- a/drivers/net/wireless/rt2x00/rt2800lib.c +++ b/drivers/net/wireless/rt2x00/rt2800lib.c | |||
@@ -2740,8 +2740,8 @@ EXPORT_SYMBOL_GPL(rt2800_probe_hw_mode); | |||
2740 | /* | 2740 | /* |
2741 | * IEEE80211 stack callback functions. | 2741 | * IEEE80211 stack callback functions. |
2742 | */ | 2742 | */ |
2743 | static void rt2800_get_tkip_seq(struct ieee80211_hw *hw, u8 hw_key_idx, | 2743 | void rt2800_get_tkip_seq(struct ieee80211_hw *hw, u8 hw_key_idx, u32 *iv32, |
2744 | u32 *iv32, u16 *iv16) | 2744 | u16 *iv16) |
2745 | { | 2745 | { |
2746 | struct rt2x00_dev *rt2x00dev = hw->priv; | 2746 | struct rt2x00_dev *rt2x00dev = hw->priv; |
2747 | struct mac_iveiv_entry iveiv_entry; | 2747 | struct mac_iveiv_entry iveiv_entry; |
@@ -2754,8 +2754,9 @@ static void rt2800_get_tkip_seq(struct ieee80211_hw *hw, u8 hw_key_idx, | |||
2754 | memcpy(iv16, &iveiv_entry.iv[0], sizeof(*iv16)); | 2754 | memcpy(iv16, &iveiv_entry.iv[0], sizeof(*iv16)); |
2755 | memcpy(iv32, &iveiv_entry.iv[4], sizeof(*iv32)); | 2755 | memcpy(iv32, &iveiv_entry.iv[4], sizeof(*iv32)); |
2756 | } | 2756 | } |
2757 | EXPORT_SYMBOL_GPL(rt2800_get_tkip_seq); | ||
2757 | 2758 | ||
2758 | static int rt2800_set_rts_threshold(struct ieee80211_hw *hw, u32 value) | 2759 | int rt2800_set_rts_threshold(struct ieee80211_hw *hw, u32 value) |
2759 | { | 2760 | { |
2760 | struct rt2x00_dev *rt2x00dev = hw->priv; | 2761 | struct rt2x00_dev *rt2x00dev = hw->priv; |
2761 | u32 reg; | 2762 | u32 reg; |
@@ -2791,9 +2792,10 @@ static int rt2800_set_rts_threshold(struct ieee80211_hw *hw, u32 value) | |||
2791 | 2792 | ||
2792 | return 0; | 2793 | return 0; |
2793 | } | 2794 | } |
2795 | EXPORT_SYMBOL_GPL(rt2800_set_rts_threshold); | ||
2794 | 2796 | ||
2795 | static int rt2800_conf_tx(struct ieee80211_hw *hw, u16 queue_idx, | 2797 | int rt2800_conf_tx(struct ieee80211_hw *hw, u16 queue_idx, |
2796 | const struct ieee80211_tx_queue_params *params) | 2798 | const struct ieee80211_tx_queue_params *params) |
2797 | { | 2799 | { |
2798 | struct rt2x00_dev *rt2x00dev = hw->priv; | 2800 | struct rt2x00_dev *rt2x00dev = hw->priv; |
2799 | struct data_queue *queue; | 2801 | struct data_queue *queue; |
@@ -2858,8 +2860,9 @@ static int rt2800_conf_tx(struct ieee80211_hw *hw, u16 queue_idx, | |||
2858 | 2860 | ||
2859 | return 0; | 2861 | return 0; |
2860 | } | 2862 | } |
2863 | EXPORT_SYMBOL_GPL(rt2800_conf_tx); | ||
2861 | 2864 | ||
2862 | static u64 rt2800_get_tsf(struct ieee80211_hw *hw) | 2865 | u64 rt2800_get_tsf(struct ieee80211_hw *hw) |
2863 | { | 2866 | { |
2864 | struct rt2x00_dev *rt2x00dev = hw->priv; | 2867 | struct rt2x00_dev *rt2x00dev = hw->priv; |
2865 | u64 tsf; | 2868 | u64 tsf; |
@@ -2872,12 +2875,11 @@ static u64 rt2800_get_tsf(struct ieee80211_hw *hw) | |||
2872 | 2875 | ||
2873 | return tsf; | 2876 | return tsf; |
2874 | } | 2877 | } |
2878 | EXPORT_SYMBOL_GPL(rt2800_get_tsf); | ||
2875 | 2879 | ||
2876 | static int rt2800_ampdu_action(struct ieee80211_hw *hw, | 2880 | int rt2800_ampdu_action(struct ieee80211_hw *hw, struct ieee80211_vif *vif, |
2877 | struct ieee80211_vif *vif, | 2881 | enum ieee80211_ampdu_mlme_action action, |
2878 | enum ieee80211_ampdu_mlme_action action, | 2882 | struct ieee80211_sta *sta, u16 tid, u16 *ssn) |
2879 | struct ieee80211_sta *sta, | ||
2880 | u16 tid, u16 *ssn) | ||
2881 | { | 2883 | { |
2882 | int ret = 0; | 2884 | int ret = 0; |
2883 | 2885 | ||
@@ -2901,29 +2903,7 @@ static int rt2800_ampdu_action(struct ieee80211_hw *hw, | |||
2901 | 2903 | ||
2902 | return ret; | 2904 | return ret; |
2903 | } | 2905 | } |
2904 | 2906 | EXPORT_SYMBOL_GPL(rt2800_ampdu_action); | |
2905 | const struct ieee80211_ops rt2800_mac80211_ops = { | ||
2906 | .tx = rt2x00mac_tx, | ||
2907 | .start = rt2x00mac_start, | ||
2908 | .stop = rt2x00mac_stop, | ||
2909 | .add_interface = rt2x00mac_add_interface, | ||
2910 | .remove_interface = rt2x00mac_remove_interface, | ||
2911 | .config = rt2x00mac_config, | ||
2912 | .configure_filter = rt2x00mac_configure_filter, | ||
2913 | .set_tim = rt2x00mac_set_tim, | ||
2914 | .set_key = rt2x00mac_set_key, | ||
2915 | .sw_scan_start = rt2x00mac_sw_scan_start, | ||
2916 | .sw_scan_complete = rt2x00mac_sw_scan_complete, | ||
2917 | .get_stats = rt2x00mac_get_stats, | ||
2918 | .get_tkip_seq = rt2800_get_tkip_seq, | ||
2919 | .set_rts_threshold = rt2800_set_rts_threshold, | ||
2920 | .bss_info_changed = rt2x00mac_bss_info_changed, | ||
2921 | .conf_tx = rt2800_conf_tx, | ||
2922 | .get_tsf = rt2800_get_tsf, | ||
2923 | .rfkill_poll = rt2x00mac_rfkill_poll, | ||
2924 | .ampdu_action = rt2800_ampdu_action, | ||
2925 | }; | ||
2926 | EXPORT_SYMBOL_GPL(rt2800_mac80211_ops); | ||
2927 | 2907 | ||
2928 | MODULE_AUTHOR(DRV_PROJECT ", Bartlomiej Zolnierkiewicz"); | 2908 | MODULE_AUTHOR(DRV_PROJECT ", Bartlomiej Zolnierkiewicz"); |
2929 | MODULE_VERSION(DRV_VERSION); | 2909 | MODULE_VERSION(DRV_VERSION); |
diff --git a/drivers/net/wireless/rt2x00/rt2800lib.h b/drivers/net/wireless/rt2x00/rt2800lib.h index eb3a4f50a363..10f8f2f8d65b 100644 --- a/drivers/net/wireless/rt2x00/rt2800lib.h +++ b/drivers/net/wireless/rt2x00/rt2800lib.h | |||
@@ -159,6 +159,14 @@ int rt2800_validate_eeprom(struct rt2x00_dev *rt2x00dev); | |||
159 | int rt2800_init_eeprom(struct rt2x00_dev *rt2x00dev); | 159 | int rt2800_init_eeprom(struct rt2x00_dev *rt2x00dev); |
160 | int rt2800_probe_hw_mode(struct rt2x00_dev *rt2x00dev); | 160 | int rt2800_probe_hw_mode(struct rt2x00_dev *rt2x00dev); |
161 | 161 | ||
162 | extern const struct ieee80211_ops rt2800_mac80211_ops; | 162 | void rt2800_get_tkip_seq(struct ieee80211_hw *hw, u8 hw_key_idx, u32 *iv32, |
163 | u16 *iv16); | ||
164 | int rt2800_set_rts_threshold(struct ieee80211_hw *hw, u32 value); | ||
165 | int rt2800_conf_tx(struct ieee80211_hw *hw, u16 queue_idx, | ||
166 | const struct ieee80211_tx_queue_params *params); | ||
167 | u64 rt2800_get_tsf(struct ieee80211_hw *hw); | ||
168 | int rt2800_ampdu_action(struct ieee80211_hw *hw, struct ieee80211_vif *vif, | ||
169 | enum ieee80211_ampdu_mlme_action action, | ||
170 | struct ieee80211_sta *sta, u16 tid, u16 *ssn); | ||
163 | 171 | ||
164 | #endif /* RT2800LIB_H */ | 172 | #endif /* RT2800LIB_H */ |
diff --git a/drivers/net/wireless/rt2x00/rt2800pci.c b/drivers/net/wireless/rt2x00/rt2800pci.c index c0c38f9705ae..4c138eb5369c 100644 --- a/drivers/net/wireless/rt2x00/rt2800pci.c +++ b/drivers/net/wireless/rt2x00/rt2800pci.c | |||
@@ -1088,6 +1088,28 @@ static int rt2800pci_probe_hw(struct rt2x00_dev *rt2x00dev) | |||
1088 | return 0; | 1088 | return 0; |
1089 | } | 1089 | } |
1090 | 1090 | ||
1091 | static const struct ieee80211_ops rt2800pci_mac80211_ops = { | ||
1092 | .tx = rt2x00mac_tx, | ||
1093 | .start = rt2x00mac_start, | ||
1094 | .stop = rt2x00mac_stop, | ||
1095 | .add_interface = rt2x00mac_add_interface, | ||
1096 | .remove_interface = rt2x00mac_remove_interface, | ||
1097 | .config = rt2x00mac_config, | ||
1098 | .configure_filter = rt2x00mac_configure_filter, | ||
1099 | .set_tim = rt2x00mac_set_tim, | ||
1100 | .set_key = rt2x00mac_set_key, | ||
1101 | .sw_scan_start = rt2x00mac_sw_scan_start, | ||
1102 | .sw_scan_complete = rt2x00mac_sw_scan_complete, | ||
1103 | .get_stats = rt2x00mac_get_stats, | ||
1104 | .get_tkip_seq = rt2800_get_tkip_seq, | ||
1105 | .set_rts_threshold = rt2800_set_rts_threshold, | ||
1106 | .bss_info_changed = rt2x00mac_bss_info_changed, | ||
1107 | .conf_tx = rt2800_conf_tx, | ||
1108 | .get_tsf = rt2800_get_tsf, | ||
1109 | .rfkill_poll = rt2x00mac_rfkill_poll, | ||
1110 | .ampdu_action = rt2800_ampdu_action, | ||
1111 | }; | ||
1112 | |||
1091 | static const struct rt2x00lib_ops rt2800pci_rt2x00_ops = { | 1113 | static const struct rt2x00lib_ops rt2800pci_rt2x00_ops = { |
1092 | .irq_handler = rt2800pci_interrupt, | 1114 | .irq_handler = rt2800pci_interrupt, |
1093 | .irq_handler_thread = rt2800pci_interrupt_thread, | 1115 | .irq_handler_thread = rt2800pci_interrupt_thread, |
@@ -1152,7 +1174,7 @@ static const struct rt2x00_ops rt2800pci_ops = { | |||
1152 | .tx = &rt2800pci_queue_tx, | 1174 | .tx = &rt2800pci_queue_tx, |
1153 | .bcn = &rt2800pci_queue_bcn, | 1175 | .bcn = &rt2800pci_queue_bcn, |
1154 | .lib = &rt2800pci_rt2x00_ops, | 1176 | .lib = &rt2800pci_rt2x00_ops, |
1155 | .hw = &rt2800_mac80211_ops, | 1177 | .hw = &rt2800pci_mac80211_ops, |
1156 | #ifdef CONFIG_RT2X00_LIB_DEBUGFS | 1178 | #ifdef CONFIG_RT2X00_LIB_DEBUGFS |
1157 | .debugfs = &rt2800_rt2x00debug, | 1179 | .debugfs = &rt2800_rt2x00debug, |
1158 | #endif /* CONFIG_RT2X00_LIB_DEBUGFS */ | 1180 | #endif /* CONFIG_RT2X00_LIB_DEBUGFS */ |
diff --git a/drivers/net/wireless/rt2x00/rt2800usb.c b/drivers/net/wireless/rt2x00/rt2800usb.c index df78e28526bf..f8eb6d776d99 100644 --- a/drivers/net/wireless/rt2x00/rt2800usb.c +++ b/drivers/net/wireless/rt2x00/rt2800usb.c | |||
@@ -645,6 +645,28 @@ static int rt2800usb_probe_hw(struct rt2x00_dev *rt2x00dev) | |||
645 | return 0; | 645 | return 0; |
646 | } | 646 | } |
647 | 647 | ||
648 | static const struct ieee80211_ops rt2800usb_mac80211_ops = { | ||
649 | .tx = rt2x00mac_tx, | ||
650 | .start = rt2x00mac_start, | ||
651 | .stop = rt2x00mac_stop, | ||
652 | .add_interface = rt2x00mac_add_interface, | ||
653 | .remove_interface = rt2x00mac_remove_interface, | ||
654 | .config = rt2x00mac_config, | ||
655 | .configure_filter = rt2x00mac_configure_filter, | ||
656 | .set_tim = rt2x00mac_set_tim, | ||
657 | .set_key = rt2x00mac_set_key, | ||
658 | .sw_scan_start = rt2x00mac_sw_scan_start, | ||
659 | .sw_scan_complete = rt2x00mac_sw_scan_complete, | ||
660 | .get_stats = rt2x00mac_get_stats, | ||
661 | .get_tkip_seq = rt2800_get_tkip_seq, | ||
662 | .set_rts_threshold = rt2800_set_rts_threshold, | ||
663 | .bss_info_changed = rt2x00mac_bss_info_changed, | ||
664 | .conf_tx = rt2800_conf_tx, | ||
665 | .get_tsf = rt2800_get_tsf, | ||
666 | .rfkill_poll = rt2x00mac_rfkill_poll, | ||
667 | .ampdu_action = rt2800_ampdu_action, | ||
668 | }; | ||
669 | |||
648 | static const struct rt2x00lib_ops rt2800usb_rt2x00_ops = { | 670 | static const struct rt2x00lib_ops rt2800usb_rt2x00_ops = { |
649 | .probe_hw = rt2800usb_probe_hw, | 671 | .probe_hw = rt2800usb_probe_hw, |
650 | .get_firmware_name = rt2800usb_get_firmware_name, | 672 | .get_firmware_name = rt2800usb_get_firmware_name, |
@@ -708,7 +730,7 @@ static const struct rt2x00_ops rt2800usb_ops = { | |||
708 | .tx = &rt2800usb_queue_tx, | 730 | .tx = &rt2800usb_queue_tx, |
709 | .bcn = &rt2800usb_queue_bcn, | 731 | .bcn = &rt2800usb_queue_bcn, |
710 | .lib = &rt2800usb_rt2x00_ops, | 732 | .lib = &rt2800usb_rt2x00_ops, |
711 | .hw = &rt2800_mac80211_ops, | 733 | .hw = &rt2800usb_mac80211_ops, |
712 | #ifdef CONFIG_RT2X00_LIB_DEBUGFS | 734 | #ifdef CONFIG_RT2X00_LIB_DEBUGFS |
713 | .debugfs = &rt2800_rt2x00debug, | 735 | .debugfs = &rt2800_rt2x00debug, |
714 | #endif /* CONFIG_RT2X00_LIB_DEBUGFS */ | 736 | #endif /* CONFIG_RT2X00_LIB_DEBUGFS */ |