Home
last modified time | relevance | path

Searched full:tsf (Results 1 – 25 of 187) sorted by relevance

12345678

/freebsd/sys/dev/ath/
H A Dif_ath_tsf.h36 * a full 64-bit TSF using the specified TSF.
39 ath_extend_tsf15(u_int32_t rstamp, u_int64_t tsf) in ath_extend_tsf15() argument
41 if ((tsf & 0x7fff) < rstamp) in ath_extend_tsf15()
42 tsf -= 0x8000; in ath_extend_tsf15()
44 return ((tsf &~ 0x7fff) | rstamp); in ath_extend_tsf15()
49 * a full 64-bit TSF using the specified TSF.
52 ath_extend_tsf32(u_int32_t rstamp, u_int64_t tsf) in ath_extend_tsf32() argument
54 u_int32_t tsf_low = tsf & 0xffffffff; in ath_extend_tsf32()
55 u_int64_t tsf64 = (tsf & ~0xffffffffULL) | rstamp; in ath_extend_tsf32()
67 * Extend the TSF from the RX descriptor to a full 64 bit TSF.
[all …]
H A Dif_ath_tdma.c179 "%s: nexttbtt=%u (0x%08x), nexttbtt tsf=%lld (0x%08llx)\n", in ath_tdma_settimers()
212 sc->sc_tdmabintval >>= 10; /* TSF -> TU */ in ath_tdma_bintvalsetup()
344 * involved changing the TSF/TU calculations, we need to make
350 * into the timers wrap at (2^31)-1 TSF, all the various terms
365 u_int64_t tsf, rstamp, nextslot, nexttbtt, nexttbtt_full; in ath_tdma_update() local
396 tsf = ath_hal_gettsf64(ah); in ath_tdma_update()
397 rstamp = ath_extend_tsf(sc, rs->rs_tstamp, tsf); in ath_tdma_update()
440 * For 802.11n chips: nextslottu needs to be the full TSF space, in ath_tdma_update()
449 * adjustments are done by pulling the TSF forward and possibly in ath_tdma_update()
453 * The logic here assumes the nexttbtt counter is in TSF in ath_tdma_update()
[all …]
H A Dif_ath_beacon.c224 * Calculate a TSF adjustment factor required for staggered in ath_beacon_alloc()
234 * The beacon interval is in TU's; the TSF is in usecs. in ath_beacon_alloc()
236 * then convert to TSF units and handle byte swapping before in ath_beacon_alloc()
245 tsfadjust = htole64(tsfadjust << 10); /* TU -> TSF */ in ath_beacon_alloc()
912 * When operating as an AP this resets the TSF and sets
917 * beacon and the current TSF, configures PCF and DTIM
936 u_int64_t tsf, tsf_beacon; in ath_beacon_config() local
1012 * that the AP has started transmitting beacons at TSF values that in ath_beacon_config()
1045 * TSF and calculate dtim+cfp state for the result. in ath_beacon_config()
1047 tsf = ath_hal_gettsf64(ah); in ath_beacon_config()
[all …]
H A Dif_ath_rx.c441 …DPRINTF(sc, ATH_DEBUG_BEACON, "%s: %s: ni=%6D bssid=%6D tsf=%llu (%u), nexttbtt=%llu (%u), delta=%… in ath_recv_mgmt()
470 * Resync beacon timers using the tsf of the beacon in ath_recv_mgmt()
484 uint64_t tsf = ath_extend_tsf(sc, rstamp, in ath_recv_mgmt() local
487 * Handle ibss merge as needed; check the tsf on the in ath_recv_mgmt()
491 * is determined by the tsf. Note that hardware in ath_recv_mgmt()
496 if (le64toh(ni->ni_tstamp.tsf) >= tsf) { in ath_recv_mgmt()
498 "ibss merge, rstamp %u tsf %ju " in ath_recv_mgmt()
499 "tstamp %ju\n", rstamp, (uintmax_t)tsf, in ath_recv_mgmt()
500 (uintmax_t)ni->ni_tstamp.tsf); in ath_recv_mgmt()
511 const struct ath_rx_status *rs, u_int64_t tsf, int16_t nf) in ath_rx_tap_vendor() argument
[all …]
/freebsd/contrib/ntp/include/
H A Dtimevalops.h35 # define TVUTOTSF(tvu, tsf) \ argument
36 ((tsf) = ustotslo[(tvu) & 0xff] \
40 # define TVUTOTSF(tvu, tsf) \ argument
41 ((tsf) = (u_int32) \
62 # define TSFTOTVU(tsf, tvu) \ argument
63 ((tvu) = (tstoushi[((tsf) >> 24) & 0xff] \
64 + tstousmid[((tsf) >> 16) & 0xff] \
65 + tstouslo[((tsf) >> 9) & 0x7f] \
68 # define TSFTOTVU(tsf, tvu) \ argument
70 (((u_int64)(tsf) * MICROSECONDS + 0x80000000) >> 32))
[all …]
/freebsd/sys/dev/iwm/
H A Dif_iwm_mac_ctxt.c279 * The TSF ID is one of four TSF tracking resources in the firmware. in iwm_mac_ctxt_cmd_common()
282 * For now, just hard-code it to TSF tracking ID 0; we only support in iwm_mac_ctxt_cmd_common()
394 "BEACON: tsf: %llu, ni_intval=%d\n", in iwm_mac_ctxt_cmd_fill_sta()
395 (unsigned long long) le64toh(ni->ni_tstamp.tsf), in iwm_mac_ctxt_cmd_fill_sta()
400 uint64_t tsf; in iwm_mac_ctxt_cmd_fill_sta() local
410 * "sync_device_ts") and TSF timestamp aren't at exactly the in iwm_mac_ctxt_cmd_fill_sta()
411 * same offset in the frame -- the TSF is at the first symbol in iwm_mac_ctxt_cmd_fill_sta()
412 * of the TSF, the system timestamp is at signal acquisition in iwm_mac_ctxt_cmd_fill_sta()
423 * net80211: TSF is in 802.11 order, so convert up to local in iwm_mac_ctxt_cmd_fill_sta()
426 tsf = le64toh(ni->ni_tstamp.tsf); in iwm_mac_ctxt_cmd_fill_sta()
[all …]
/freebsd/sys/contrib/dev/athk/
H A Dspectral_common.h62 __be64 tsf; member
76 __be64 tsf; member
104 __be64 tsf; member
123 __be32 tsf; member
/freebsd/sys/contrib/dev/rtw89/
H A Dps.c498 u64 tsf; in rtw89_p2p_noa_once_recalc() local
504 ret = rtw89_mac_port_get_tsf(rtwdev, rtwvif_link, &tsf); in rtw89_p2p_noa_once_recalc()
506 rtw89_warn(rtwdev, "%s: failed to get tsf\n", __func__); in rtw89_p2p_noa_once_recalc()
531 tmp = (tsf & GENMASK_ULL(63, 32)) + tmp; in rtw89_p2p_noa_once_recalc()
532 if (unlikely(tmp <= tsf)) in rtw89_p2p_noa_once_recalc()
536 tmp = (tsf & GENMASK_ULL(63, 32)) | start_time; in rtw89_p2p_noa_once_recalc()
547 if (noa_once->tsf_end > tsf) { in rtw89_p2p_noa_once_recalc()
552 clr_delay_us = min_t(u64, tsf_end - tsf, UINT_MAX); in rtw89_p2p_noa_once_recalc()
554 if (tsf_begin <= tsf) { in rtw89_p2p_noa_once_recalc()
559 set_delay_us = tsf_begin - tsf; in rtw89_p2p_noa_once_recalc()
/freebsd/contrib/llvm-project/llvm/lib/Target/VE/
H A DVEInstrInfo.h46 #define HAS_VLINDEX(TSF) ((TSF)&VEII::VE_VLInUse) argument
47 #define GET_VLINDEX(TSF) \ argument
48 (HAS_VLINDEX(TSF) ? (int)(((TSF)&VEII::VE_VLMask) >> VEII::VE_VLShift) : -1)
/freebsd/sys/dev/wtap/
H A Dif_wtap.c164 uint64_t tsf = wtap_hal_get_tsf(sc->hal); in wtap_recv_mgmt() local
167 * Handle ibss merge as needed; check the tsf on the in wtap_recv_mgmt()
171 * is determined by the tsf. Note that hardware in wtap_recv_mgmt()
176 if (le64toh(ni->ni_tstamp.tsf) >= tsf) in wtap_recv_mgmt()
240 uint64_t tsf; in wtap_beacon_intrp() local
259 /* Get TSF from HAL, and insert it into beacon frame */ in wtap_beacon_intrp()
260 tsf = wtap_hal_get_tsf(sc->hal); in wtap_beacon_intrp()
262 memcpy(&wh[1], &tsf, sizeof(tsf)); in wtap_beacon_intrp()
316 * have a current TSF to use. Otherwise we're in wtap_newstate()
322 ni->ni_tstamp.tsf != 0) in wtap_newstate()
[all …]
/freebsd/sys/contrib/dev/ath/ath_hal/ar9300/
H A Dar9300_timer.c61 ar9300_alloc_generic_timer(struct ath_hal *ah, HAL_GEN_TIMER_DOMAIN tsf) in ar9300_alloc_generic_timer() argument
67 if (tsf == HAL_GEN_TIMER_TSF) { in ar9300_alloc_generic_timer()
82 if ((tsf == HAL_GEN_TIMER_TSF2) && !ahp->ah_enable_tsf2) { in ar9300_alloc_generic_timer()
134 * Starting from Jupiter, each generic timer can select which tsf to in ar9300_start_generic_timer()
135 * use. But we still follow the old rule, 0 - 7 use tsf and 8 - 15 in ar9300_start_generic_timer()
/freebsd/sys/contrib/dev/iwlwifi/fw/api/
H A Doffload.h45 * @tsf: TSF on air rise
54 __le64 tsf; member
H A Dmac.h78 * enum iwl_tsf_id - TSF hw timer ID
79 * @TSF_ID_A: use TSF A
80 * @TSF_ID_B: use TSF B
81 * @TSF_ID_C: use TSF C
82 * @TSF_ID_D: use TSF D
83 * @NUM_TSF_IDS: number of TSF timers available
96 * @beacon_tsf: beacon transmit time in TSF
119 * @beacon_tsf: beacon transmit time in TSF
157 * @dtim_tsf: DTIM arrival time in TSF
164 * @assoc_beacon_arrive_time: TSF of first beacon after association
[all …]
H A Dlocation.h512 * @tsf_timer_offset_msec: the recommended time offset (mSec) from the AP's TSF
546 * @tsf_delta_direction: TSF relatively to the subject AP
559 * @tsf_delta: TSF Delta in units of microseconds.
560 * The difference between the AP TSF and the device local clock.
1208 * TSF of this mac id. 0xff to disable TSF reporting.
1240 * TSF of this mac id. 0xff to disable TSF reporting.
1272 * TSF of this mac id. 0xff to disable TSF reporting.
1300 * TSF of this mac id. 0xff to disable TSF reporting.
1328 * TSF of this mac id. 0xff to disable TSF reporting.
1356 * TSF of this mac id. 0xff to disable TSF reporting.
[all …]
H A Drx.h33 * @timestamp: TSF at on air rise
281 /* TSF overload low dword */
298 /* TSF overload low dword */
335 /* TSF overload high dword */
338 * check this first - if TSF overload is set,
347 /* TSF overload high dword For HE rates*/
364 /* TSF overload high dword For EHT-MU/TB rates*/
520 * TSF value on air rise (INA), only valid if
617 * TSF value on air rise (INA), only valid if
/freebsd/contrib/ntp/libntp/
H A Dtimespecops.c25 # define FTOTVN(tsf) \ argument
27 (((u_int64)(tsf) * NANOSECONDS + 0x80000000) >> 32))
34 # define FTOTVN(tsf) \ argument
35 ((int32)((tsf) / NSECFRAC + 0.5))
/freebsd/sys/dev/ath/ath_hal/ar5416/
H A Dar5416_misc.c104 * Get the current hardware tsf for stamlme
132 * Update the TSF.
134 * The full TSF is only updated once the upper 32 bits have
135 * been written. Writing only the lower 32 bits of the TSF
136 * will not actually correctly update the TSF.
138 * The #if 0'ed code is to check whether the previous TSF
140 * TSF. Strictly speaking, it should be also checked before
141 * reading the TSF as the write/reset may not have completed.
166 * Reset the current hardware tsf for stamlme.
428 /* Add the nextStart offset to the current TSF */ in ar5416SetQuiet()
H A Dar5416_beacon.c32 * Return the hardware NextTBTT in TSF
64 * Reset TSF if required. in ar5416SetBeaconTimers()
215 * rather than TSF, we may be seeing the result of dumb rounding in ar5416SetStaBeaconTimers()
271 #define HAL_TSFOOR_THRESHOLD 0x00004240 /* TSF OOR threshold (16k us) */ in ar5416SetStaBeaconTimers()
273 /* TSF out of range threshold */ in ar5416SetStaBeaconTimers()
/freebsd/sys/contrib/dev/iwlwifi/mvm/
H A Dmac-ctxt.c67 * The TSF is a hardware/firmware resource, there are 4 and in iwl_mvm_mac_tsf_id_iter()
69 * there are cases where 2 MACs should share the same TSF ID in iwl_mvm_mac_tsf_id_iter()
87 * divisor of the beacon interval of the client, the same TSF in iwl_mvm_mac_tsf_id_iter()
115 * client or use the same TSF as an existing GO. There's no in iwl_mvm_mac_tsf_id_iter()
143 * their TSF (like P2P Device), but we won't be able in iwl_mvm_mac_tsf_id_iter()
144 * to share the TSF resource. in iwl_mvm_mac_tsf_id_iter()
150 * Unless we exited above, we can't share the TSF resource in iwl_mvm_mac_tsf_id_iter()
225 * Allocate a MAC ID and a TSF for this MAC, along with the queues in iwl_mvm_mac_ctxt_init()
233 * virtual interfaces, and all TSF IDs are cleared that can't be used in iwl_mvm_mac_ctxt_init()
236 * At the same time, we check if there's a preferred TSF in the case in iwl_mvm_mac_ctxt_init()
[all …]
/freebsd/sys/contrib/dev/mediatek/mt76/mt7615/
H A Dmain.c904 } tsf; in mt7615_get_tsf() local
913 /* TSF read */ in mt7615_get_tsf()
915 tsf.t32[0] = mt76_rr(dev, MT_LPON_UTTR0); in mt7615_get_tsf()
916 tsf.t32[1] = mt76_rr(dev, MT_LPON_UTTR1); in mt7615_get_tsf()
920 return tsf.t64; in mt7615_get_tsf()
932 } tsf = { .t64 = timestamp, }; in mt7615_set_tsf() local
941 mt76_wr(dev, MT_LPON_UTTR0, tsf.t32[0]); in mt7615_set_tsf()
942 mt76_wr(dev, MT_LPON_UTTR1, tsf.t32[1]); in mt7615_set_tsf()
943 /* TSF software overwrite */ in mt7615_set_tsf()
958 } tsf = { .t64 = timestamp, }; in mt7615_offset_tsf() local
[all …]
/freebsd/sys/contrib/dev/mediatek/mt76/
H A Dmt76x02_usb_core.c149 u64 tsf, time; in mt76x02u_restart_pre_tbtt_timer() local
157 tsf = (u64)dw0 << 32 | dw1; in mt76x02u_restart_pre_tbtt_timer()
158 dev_dbg(dev->mt76.dev, "TSF: %llu us TBTT %u us\n", tsf, tbtt); in mt76x02u_restart_pre_tbtt_timer()
H A Dmt792x_core.c253 } tsf; in mt792x_get_tsf() local
259 /* TSF software read */ in mt792x_get_tsf()
261 tsf.t32[0] = mt76_rr(dev, MT_LPON_UTTR0(0)); in mt792x_get_tsf()
262 tsf.t32[1] = mt76_rr(dev, MT_LPON_UTTR1(0)); in mt792x_get_tsf()
266 return tsf.t64; in mt792x_get_tsf()
279 } tsf = { .t64 = timestamp, }; in mt792x_set_tsf() local
285 mt76_wr(dev, MT_LPON_UTTR0(0), tsf.t32[0]); in mt792x_set_tsf()
286 mt76_wr(dev, MT_LPON_UTTR1(0), tsf.t32[1]); in mt792x_set_tsf()
287 /* TSF software overwrite */ in mt792x_set_tsf()
/freebsd/sys/contrib/dev/athk/ath10k/
H A Dspectral.h41 size_t bin_len, u64 tsf);
53 size_t bin_len, u64 tsf) in ath10k_spectral_process_fft() argument
/freebsd/sys/dev/ath/ath_hal/ar5312/
H A Dar5312_misc.c115 OS_REG_WRITE(ah, AR_TSF_PARM, 61); /* 32 KHz TSF incr */ in ar5312SetupClock()
118 OS_REG_WRITE(ah, AR_TSF_PARM, 1); /* 32 MHz TSF incr */ in ar5312SetupClock()
146 OS_REG_WRITE(ah, AR_TSF_PARM, 1); /* 32 MHz TSF incr */ in ar5312RestoreClock()
/freebsd/sys/dev/ath/ath_hal/ar5212/
H A Dar5212_beacon.c29 * Return the hardware NextTBTT in TSF
67 * When resetting the TSF, in ar5212SetBeaconTimers()
70 * signal to cause a reset of the TSF - but if the signal in ar5212SetBeaconTimers()
71 * is left high, it will reset the TSF on the next in ar5212SetBeaconTimers()

12345678