From f25c21988d703871f5b1e9f5e42792cfebd3461c Mon Sep 17 00:00:00 2001 From: Akshai M Date: Thu, 14 May 2020 16:46:49 +0530 Subject: [PATCH] gnrc/tcp : Move GNRC_TCP_RTO_GRANULARITY to 'CONFIG_' --- sys/include/net/gnrc/tcp/config.h | 4 ++-- sys/net/gnrc/transport_layer/tcp/gnrc_tcp_pkt.c | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/sys/include/net/gnrc/tcp/config.h b/sys/include/net/gnrc/tcp/config.h index 5a92a6e041..6f89b3f2e2 100644 --- a/sys/include/net/gnrc/tcp/config.h +++ b/sys/include/net/gnrc/tcp/config.h @@ -128,8 +128,8 @@ extern "C" { /** * @brief Assumes clock granularity for TCP of 10 ms (see RFC 6298) */ -#ifndef GNRC_TCP_RTO_GRANULARITY -#define GNRC_TCP_RTO_GRANULARITY (10U * MS_PER_SEC) +#ifndef CONFIG_GNRC_TCP_RTO_GRANULARITY +#define CONFIG_GNRC_TCP_RTO_GRANULARITY (10U * MS_PER_SEC) #endif /** diff --git a/sys/net/gnrc/transport_layer/tcp/gnrc_tcp_pkt.c b/sys/net/gnrc/transport_layer/tcp/gnrc_tcp_pkt.c index cbf345168e..827a75842b 100644 --- a/sys/net/gnrc/transport_layer/tcp/gnrc_tcp_pkt.c +++ b/sys/net/gnrc/transport_layer/tcp/gnrc_tcp_pkt.c @@ -388,7 +388,7 @@ int _pkt_setup_retransmit(gnrc_tcp_tcb_t *tcb, gnrc_pktsnip_t *pkt, const bool r tcb->rto = CONFIG_GNRC_TCP_RTO_LOWER_BOUND; } else { - tcb->rto = tcb->srtt + _max(GNRC_TCP_RTO_GRANULARITY, GNRC_TCP_RTO_K * tcb->rtt_var); + tcb->rto = tcb->srtt + _max(CONFIG_GNRC_TCP_RTO_GRANULARITY, GNRC_TCP_RTO_K * tcb->rtt_var); } } else {