From patchwork Wed Jan 22 11:35:30 2020 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Gautam Ramakrishnan X-Patchwork-Id: 1227198 X-Patchwork-Delegate: davem@davemloft.net Return-Path: X-Original-To: patchwork-incoming-netdev@ozlabs.org Delivered-To: patchwork-incoming-netdev@ozlabs.org Authentication-Results: ozlabs.org; spf=none (no SPF record) smtp.mailfrom=vger.kernel.org (client-ip=209.132.180.67; helo=vger.kernel.org; envelope-from=netdev-owner@vger.kernel.org; receiver=) Authentication-Results: ozlabs.org; dmarc=pass (p=none dis=none) header.from=gmail.com Authentication-Results: ozlabs.org; dkim=pass (2048-bit key; unprotected) header.d=gmail.com header.i=@gmail.com header.a=rsa-sha256 header.s=20161025 header.b=nBz5U6Mk; dkim-atps=neutral Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by ozlabs.org (Postfix) with ESMTP id 482jzG3sdnz9sP6 for ; Wed, 22 Jan 2020 22:36:26 +1100 (AEDT) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1729246AbgAVLgZ (ORCPT ); Wed, 22 Jan 2020 06:36:25 -0500 Received: from mail-pg1-f196.google.com ([209.85.215.196]:36871 "EHLO mail-pg1-f196.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1729012AbgAVLgZ (ORCPT ); Wed, 22 Jan 2020 06:36:25 -0500 Received: by mail-pg1-f196.google.com with SMTP id q127so3357859pga.4 for ; Wed, 22 Jan 2020 03:36:25 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=from:to:cc:subject:date:message-id:in-reply-to:references; bh=7QJ7r6VCbJ5yiJne5YJbfLdcih0PR3cC3oHUxUnk3EU=; b=nBz5U6MkGQghgoM+/oianKmyfUEMUS9qGHuEOJDad1hkeuTM77VhajN4G/XcT5Cd+7 ldBzcit8wYIdMLFLeUJ8foKReqmEG2aOsTUoK8+IEJyN1F76Dnx8mpb05SFU7OwN6EM5 KxkrVNX8UX7baeNRC15WO4QlIzYeT9kCwkJdJUlc3/2O4TUvhrscplEhR0WNzcHpHSwT bcrSRRT1oAeHCU0jeyTeQfjqDnwR4wKNGX0CIkUnVN1pLZagC1kUHjIxogJ2rHKZlQ5c wT/N8FE2i9uAFM8X3IacfZQ4Ie7V2VqkzY1VCR9n2vEuyhb8zZyVet9TuXWhuOyB+QS1 oK7w== 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=7QJ7r6VCbJ5yiJne5YJbfLdcih0PR3cC3oHUxUnk3EU=; b=qGKsAUi00vctK0EfOVUdo20PMXG6A7b89ARrgShVUvw1yHAeOlqbnmPHcOM3mehXVJ xCMiLGVHBFb2ag4ZeV+VZoxdkUVWBCk6lQ+MDN7AeP4vu/9SPt4vRfS5GAFWWqR8Zajn nEvQxPKVVZRSFpXHDGa9wtcD+278/GW5lW6+cw7ac1JXiSwMovrxT5LsfjOOxRLo6by0 tclQu9lT19CUVIpFyWw3scpH2FQa4Z0bG8PiSjSAU/ohYuNzJ0W1bMhd5SkKdvZFATaG flX5eWnmdTR4XyMZo4KuKT8ZXfHtbx6nSLxAp/i4lPNeLolQgB3Gh3QivdzvG/3NPAK3 qNjg== X-Gm-Message-State: APjAAAWOa6jS0YMu8Mahbcom5moSZNWywo+q5esY3trmyVOW5+KFqyKG EConSeGivDNXe9SIccqL5T4/HAh41VSkkNfD X-Google-Smtp-Source: APXvYqysON5fujS33cj6T4u0xP/S0KBmqxkmcm8hjyJYODMzLrIHF8qDcsK7HL0+7tRTh4gRq6/Wrg== X-Received: by 2002:aa7:92c7:: with SMTP id k7mr2234096pfa.8.1579692984412; Wed, 22 Jan 2020 03:36:24 -0800 (PST) Received: from localhost.localdomain ([223.186.203.82]) by smtp.gmail.com with ESMTPSA id c6sm2145962pgk.78.2020.01.22.03.36.19 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 22 Jan 2020 03:36:23 -0800 (PST) From: gautamramk@gmail.com To: netdev@vger.kernel.org Cc: "Mohit P. Tahiliani" , Jamal Hadi Salim , "David S . Miller" , Dave Taht , =?utf-8?q?Toke_H=C3=B8iland-J=C3=B8rgensen?= , Jakub Kicinski , Stephen Hemminger , Leslie Monis , Gautam Ramakrishnan Subject: [PATCH net-next v6 07/10] net: sched: pie: fix commenting Date: Wed, 22 Jan 2020 17:05:30 +0530 Message-Id: <20200122113533.28128-8-gautamramk@gmail.com> X-Mailer: git-send-email 2.17.1 In-Reply-To: <20200122113533.28128-1-gautamramk@gmail.com> References: <20200122113533.28128-1-gautamramk@gmail.com> Sender: netdev-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: netdev@vger.kernel.org From: "Mohit P. Tahiliani" Fix punctuation and logical mistakes in the comments. The logical mistake was that "dequeue_rate" is no longer the default way to calculate queuing delay and is not needed. The default way to calculate queue delay was changed in commit cec2975f2b70 ("net: sched: pie: enable timestamp based delay calculation"). Signed-off-by: Mohit P. Tahiliani Signed-off-by: Leslie Monis Signed-off-by: Gautam Ramakrishnan --- net/sched/sch_pie.c | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/net/sched/sch_pie.c b/net/sched/sch_pie.c index 0c583cc148f3..024f55569a38 100644 --- a/net/sched/sch_pie.c +++ b/net/sched/sch_pie.c @@ -248,10 +248,10 @@ static void pie_process_dequeue(struct Qdisc *sch, struct sk_buff *skb) q->vars.dq_count = 0; } - /* Calculate the average drain rate from this value. If queue length - * has receded to a small value viz., <= QUEUE_THRESHOLD bytes,reset + /* Calculate the average drain rate from this value. If queue length + * has receded to a small value viz., <= QUEUE_THRESHOLD bytes, reset * the dq_count to -1 as we don't have enough packets to calculate the - * drain rate anymore The following if block is entered only when we + * drain rate anymore. The following if block is entered only when we * have a substantial queue built up (QUEUE_THRESHOLD bytes or more) * and we calculate the drain rate for the threshold here. dq_count is * in bytes, time difference in psched_time, hence rate is in @@ -329,8 +329,8 @@ static void calculate_probability(struct Qdisc *sch) qdelay_old = q->vars.qdelay_old; } - /* If qdelay is zero and qlen is not, it means qlen is very small, less - * than dequeue_rate, so we do not update probabilty in this round + /* If qdelay is zero and qlen is not, it means qlen is very small, + * so we do not update probabilty in this round. */ if (qdelay == 0 && qlen != 0) update_prob = false;