diff options
author | Ivo van Doorn <ivdoorn@gmail.com> | 2007-10-06 08:14:29 -0400 |
---|---|---|
committer | David S. Miller <davem@sunset.davemloft.net> | 2007-10-10 19:55:12 -0400 |
commit | feb24691e3e87a740caec4568be1a202db786f20 (patch) | |
tree | 76192bf145e989e0e7715a10f0da3c7417cfc254 /drivers/net/wireless/rt2x00/rt73usb.c | |
parent | 81873e9ccd5731ca77027bdb32b34904e7af25d0 (diff) |
[PATCH] rt2x00: Move TSF sync values into rt2x00config
All drivers use the same values for TSF sync,
this will move the value determination into rt2x00config.c,
and the definition for the values to rt2x00reg.h
Signed-off-by: Ivo van Doorn <IvDoorn@gmail.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
Diffstat (limited to 'drivers/net/wireless/rt2x00/rt73usb.c')
-rw-r--r-- | drivers/net/wireless/rt2x00/rt73usb.c | 12 |
1 files changed, 3 insertions, 9 deletions
diff --git a/drivers/net/wireless/rt2x00/rt73usb.c b/drivers/net/wireless/rt2x00/rt73usb.c index 6d1635b5cd07..919cca593bc1 100644 --- a/drivers/net/wireless/rt2x00/rt73usb.c +++ b/drivers/net/wireless/rt2x00/rt73usb.c | |||
@@ -279,9 +279,9 @@ static void rt73usb_config_bssid(struct rt2x00_dev *rt2x00dev, __le32 *bssid) | |||
279 | (2 * sizeof(__le32))); | 279 | (2 * sizeof(__le32))); |
280 | } | 280 | } |
281 | 281 | ||
282 | static void rt73usb_config_type(struct rt2x00_dev *rt2x00dev, const int type) | 282 | static void rt73usb_config_type(struct rt2x00_dev *rt2x00dev, const int type, |
283 | const int tsf_sync) | ||
283 | { | 284 | { |
284 | struct interface *intf = &rt2x00dev->interface; | ||
285 | u32 reg; | 285 | u32 reg; |
286 | 286 | ||
287 | /* | 287 | /* |
@@ -303,13 +303,7 @@ static void rt73usb_config_type(struct rt2x00_dev *rt2x00dev, const int type) | |||
303 | rt2x00_set_field32(®, TXRX_CSR9_TSF_TICKING, 1); | 303 | rt2x00_set_field32(®, TXRX_CSR9_TSF_TICKING, 1); |
304 | rt2x00_set_field32(®, TXRX_CSR9_TBTT_ENABLE, 1); | 304 | rt2x00_set_field32(®, TXRX_CSR9_TBTT_ENABLE, 1); |
305 | rt2x00_set_field32(®, TXRX_CSR9_BEACON_GEN, 0); | 305 | rt2x00_set_field32(®, TXRX_CSR9_BEACON_GEN, 0); |
306 | if (is_interface_type(intf, IEEE80211_IF_TYPE_IBSS) || | 306 | rt2x00_set_field32(®, TXRX_CSR9_TSF_SYNC, tsf_sync); |
307 | is_interface_type(intf, IEEE80211_IF_TYPE_AP)) | ||
308 | rt2x00_set_field32(®, TXRX_CSR9_TSF_SYNC, 2); | ||
309 | else if (is_interface_type(intf, IEEE80211_IF_TYPE_STA)) | ||
310 | rt2x00_set_field32(®, TXRX_CSR9_TSF_SYNC, 1); | ||
311 | else | ||
312 | rt2x00_set_field32(®, TXRX_CSR9_TSF_SYNC, 0); | ||
313 | rt73usb_register_write(rt2x00dev, TXRX_CSR9, reg); | 307 | rt73usb_register_write(rt2x00dev, TXRX_CSR9, reg); |
314 | } | 308 | } |
315 | 309 | ||