MCPcopy Create free account
hub / github.com/F-Stack/f-stack / tcp_ts_getticks

Function tcp_ts_getticks

freebsd/netinet/tcp_seq.h:88–99  ·  view source on GitHub ↗

* tcp_ts_getticks() in ms, should be 1ms < x < 1000ms according to RFC 1323. * We always use 1ms granularity independent of hz. */

Source from the content-addressed store, hash-verified

86 * We always use 1ms granularity independent of hz.
87 */
88static __inline uint32_t
89tcp_ts_getticks(void)
90{
91 struct timeval tv;
92
93 /*
94 * getmicrouptime() should be good enough for any 1-1000ms granularity.
95 * Do not use getmicrotime() here as it might break nfsroot/tcp.
96 */
97 getmicrouptime(&tv);
98 return (tv.tv_sec * 1000 + tv.tv_usec / 1000);
99}
100#endif /* _KERNEL */
101
102#endif /* _NETINET_TCP_SEQ_H_ */

Callers 15

tcp_output.cFile · 0.70
tcp_syncache.cFile · 0.70
syncache_respondFunction · 0.70
tcp_twrespondFunction · 0.70
cc_ack_receivedFunction · 0.70
tcp_autorcvbufFunction · 0.70
tcp_do_segmentFunction · 0.70
tcp_respondFunction · 0.70
ctf_ts_checkFunction · 0.50
rack_remxt_tmrFunction · 0.50
rack_log_ackFunction · 0.50
rack_do_fastnewdataFunction · 0.50

Calls 1

getmicrouptimeFunction · 0.85

Tested by

no test coverage detected