Lines Matching defs:tcp_opt
234 bool cookie_check_timestamp(struct tcp_options_received *tcp_opt, bool *ecn_ok)
237 u32 options = tcp_opt->rcv_tsecr & TSMASK;
239 if (!tcp_opt->saw_tstamp) {
240 tcp_clear_options(tcp_opt);
247 tcp_opt->sack_ok = (options >> 4) & 0x1;
252 if (tcp_opt->sack_ok && !sysctl_tcp_sack)
258 tcp_opt->wscale_ok = 1;
259 tcp_opt->snd_wscale = options & 0xf;
267 struct tcp_options_received tcp_opt;
293 memset(&tcp_opt, 0, sizeof(tcp_opt));
294 tcp_parse_options(skb, &tcp_opt, &hash_location, 0);
296 if (!cookie_check_timestamp(&tcp_opt, &ecn_ok))
314 ireq->snd_wscale = tcp_opt.snd_wscale;
315 ireq->sack_ok = tcp_opt.sack_ok;
316 ireq->wscale_ok = tcp_opt.wscale_ok;
317 ireq->tstamp_ok = tcp_opt.saw_tstamp;
318 req->ts_recent = tcp_opt.saw_tstamp ? tcp_opt.rcv_tsval : 0;