From patchwork Tue May 16 21:00:09 2017 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Eric Dumazet X-Patchwork-Id: 763205 X-Patchwork-Delegate: davem@davemloft.net Return-Path: X-Original-To: patchwork-incoming@ozlabs.org Delivered-To: patchwork-incoming@ozlabs.org Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by ozlabs.org (Postfix) with ESMTP id 3wS9Yt6M0kz9s7w for ; Wed, 17 May 2017 07:29:06 +1000 (AEST) Authentication-Results: ozlabs.org; dkim=pass (2048-bit key; unprotected) header.d=google.com header.i=@google.com header.b="X1Z5h4Av"; dkim-atps=neutral Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1753220AbdEPV3E (ORCPT ); Tue, 16 May 2017 17:29:04 -0400 Received: from mail-pg0-f53.google.com ([74.125.83.53]:33466 "EHLO mail-pg0-f53.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752815AbdEPV2X (ORCPT ); Tue, 16 May 2017 17:28:23 -0400 Received: by mail-pg0-f53.google.com with SMTP id u187so82198624pgb.0 for ; Tue, 16 May 2017 14:28:23 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=20161025; h=from:to:cc:subject:date:message-id:in-reply-to:references; bh=AUekGmHbRWwhx7ZmEVAwRz7pgQw41YFzhwS5R+G+yBw=; b=X1Z5h4AvwKah5xNDt+ngL36axhwdeoTPKvpH5+ZftaKvdLA6zJI+hdgRaQdz4uTrvJ 6PZXyqXduP+Fq6z4yEA5/Od1gSpXzrepkXCqf1KwxHYeKg1+wIC+Ef0H9r5xLESzhsKR BIkcD0xLyEzh9yczBMte76Zk9HpEFKjuhnz5wVqI5msv0L4VuU6CI+DcUkiT1lXrt8B4 IcbN5oHRB34lF9Uh7t4mS0eUbvAkkMbUuvrdVJkffdd2aT3ALoS1YTUcXMQ8bE50Vetc ryHImFw+83Sn1CEtlPAb2NRssVzWapM1NUPN7IifroguADtto6jf+/xJO+udZvI0UZ7C nKqQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references; bh=AUekGmHbRWwhx7ZmEVAwRz7pgQw41YFzhwS5R+G+yBw=; b=HynIMfdrVbTYk3zt9/3H5ST6I6ZvLuVbNpoT1nrfkJrD4xxgUDcWtpV/4g7FpAcIM+ sFa/GkxtvVCxTxExMBbgV9SkJnA5l3Tp5Z53w8wqqhXBhpgFISZHXADXozCGSR0NUv3K hcykqFwcTYO5dJF6NCrNneAxHUHU/+7I1rKiJgzp1gqB2aQalNbkNiSqUWrAZnAxxOFZ OMhH5RrHmCbC9UiwxzIB5jKrPC4rVIbMfsHRrTYGU2pFWTel2VfVSofas28j0hIswz4t RkdRMrmR6HRjg6bloMk7tB2KcV/VYzXHgdeqDBtBPVCg0Hr4gPUsGFLVijiSTZjkug+U QTzw== X-Gm-Message-State: AODbwcCJDdn6/Bs/T/3GT31G6Z2+JdU5SDFX6s3mIhAZ9c74yXltsJrt t8PXkOkVD+cwmvsX X-Received: by 10.84.254.2 with SMTP id b2mr24380plm.185.1494970102737; Tue, 16 May 2017 14:28:22 -0700 (PDT) Received: from localhost ([2620:15c:2cb:201:9008:b57d:ab98:11e3]) by smtp.gmail.com with ESMTPSA id l7sm30262pgn.10.2017.05.16.14.28.21 (version=TLS1_2 cipher=AES128-SHA bits=128/128); Tue, 16 May 2017 14:28:22 -0700 (PDT) From: Eric Dumazet To: "David S . Miller" , Neal Cardwell , Yuchung Cheng , Soheil Hassas Yeganeh , Wei Wang Cc: netdev , Eric Dumazet , Eric Dumazet Subject: [PATCH net-next 10/15] tcp: uses jiffies_32 to feed tp->chrono_start Date: Tue, 16 May 2017 14:00:09 -0700 Message-Id: <20170516210014.31176-11-edumazet@google.com> X-Mailer: git-send-email 2.13.0.303.g4ebf302169-goog In-Reply-To: <20170516210014.31176-1-edumazet@google.com> References: <20170516210014.31176-1-edumazet@google.com> Sender: netdev-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: netdev@vger.kernel.org tcp_time_stamp will no longer be tied to jiffies. Signed-off-by: Eric Dumazet Acked-by: Soheil Hassas Yeganeh --- net/ipv4/tcp.c | 2 +- net/ipv4/tcp_output.c | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/net/ipv4/tcp.c b/net/ipv4/tcp.c index d0bb61ee28bbceff8f2e27416ce87fec94935973..b85bfe7cb11dca68952cc4be19b169d893963fef 100644 --- a/net/ipv4/tcp.c +++ b/net/ipv4/tcp.c @@ -2757,7 +2757,7 @@ static void tcp_get_info_chrono_stats(const struct tcp_sock *tp, for (i = TCP_CHRONO_BUSY; i < __TCP_CHRONO_MAX; ++i) { stats[i] = tp->chrono_stat[i - 1]; if (i == tp->chrono_type) - stats[i] += tcp_time_stamp - tp->chrono_start; + stats[i] += tcp_jiffies32 - tp->chrono_start; stats[i] *= USEC_PER_SEC / HZ; total += stats[i]; } diff --git a/net/ipv4/tcp_output.c b/net/ipv4/tcp_output.c index f0fd1b4fdb3291638fcdca613d826db2cd27f517..1011ea40c2ba4c12cce21149cab176e1fa4db583 100644 --- a/net/ipv4/tcp_output.c +++ b/net/ipv4/tcp_output.c @@ -2202,7 +2202,7 @@ static bool tcp_small_queue_check(struct sock *sk, const struct sk_buff *skb, static void tcp_chrono_set(struct tcp_sock *tp, const enum tcp_chrono new) { - const u32 now = tcp_time_stamp; + const u32 now = tcp_jiffies32; if (tp->chrono_type > TCP_CHRONO_UNSPEC) tp->chrono_stat[tp->chrono_type - 1] += now - tp->chrono_start;