From patchwork Wed Jan 9 16:09:40 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: =?utf-8?q?Toke_H=C3=B8iland-J=C3=B8rgensen?= X-Patchwork-Id: 1022500 Return-Path: X-Original-To: patchwork-incoming-netdev@ozlabs.org Delivered-To: patchwork-incoming-netdev@ozlabs.org Authentication-Results: ozlabs.org; spf=none (mailfrom) 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=fail (p=none dis=none) header.from=redhat.com Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by ozlabs.org (Postfix) with ESMTP id 43ZYxP58jbz9sCs for ; Thu, 10 Jan 2019 03:10:01 +1100 (AEDT) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1732603AbfAIQKA (ORCPT ); Wed, 9 Jan 2019 11:10:00 -0500 Received: from mail-wr1-f68.google.com ([209.85.221.68]:38763 "EHLO mail-wr1-f68.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1731928AbfAIQKA (ORCPT ); Wed, 9 Jan 2019 11:10:00 -0500 Received: by mail-wr1-f68.google.com with SMTP id v13so8239236wrw.5 for ; Wed, 09 Jan 2019 08:09:59 -0800 (PST) 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:mime-version :content-transfer-encoding; bh=IyA+3MX7Gsjogxzhx/N6Wy1T9bm4/QhmS6HOiQS7omA=; b=GQeA3X+ajuWCckQEml4/yvdljAkpT9X92FG8ocoCaTeKL217rAxctYYKySnq8XPOTS TBtktxkjySQV12PRaPULTR0tgxNnKtE7oajcBjWogCJR9snFX8sqbUR3pnKGFEXFpJAh HCj/qrFzVcWfetvbO3V5oDF8X8xXsbSSH9z3X/JkgtCiXcQaPVw6bI4kh8UyYdiknszu 84l0ZDuzWI161X4cbWs/QqW0YOIZnUTcgSwz9P+NflW1S3C7XVqF/k47gSiSCXe+jXIy WWn0pNOwludqI4xCmTX93ytBpmgddxYAmUT54Lh0y6+beyJHduB6VuX8JBbHDciqcC1T 1fdw== X-Gm-Message-State: AJcUukeRygeSQQrBPG3IcwDtLD+/1CYaaw8+y4q9uppdt9znJPrUU0Qs JdwN4tq4I+fFPKPjWhrz8G7D5MW5xR8= X-Google-Smtp-Source: ALg8bN5RCeKzwGuUG0TX4ZTWYRllQyZ/rZuX2GYsXd+C7HR67Idzd+VGh+0LDOBnWvbyABFXPLxtWw== X-Received: by 2002:adf:f691:: with SMTP id v17mr5459490wrp.114.1547050198310; Wed, 09 Jan 2019 08:09:58 -0800 (PST) Received: from tohojo-x1-rh.localdomain (borgediget.toke.dk. [85.204.121.218]) by smtp.gmail.com with ESMTPSA id o81sm22741661wmd.10.2019.01.09.08.09.57 (version=TLS1_2 cipher=ECDHE-RSA-CHACHA20-POLY1305 bits=256/256); Wed, 09 Jan 2019 08:09:57 -0800 (PST) Received: by tohojo-x1-rh.localdomain (Postfix, from userid 1000) id DB0141833C1; Wed, 9 Jan 2019 17:09:56 +0100 (CET) From: =?utf-8?q?Toke_H=C3=B8iland-J=C3=B8rgensen?= To: netdev@vger.kernel.org Cc: =?utf-8?q?Toke_H=C3=B8iland-J=C3=B8rgensen?= Subject: [PATCH v2 0/3] sched: Fix qdisc interactions exposed by using sch_cake as a leaf qdisc Date: Wed, 9 Jan 2019 17:09:40 +0100 Message-Id: <20190109160943.18051-1-toke@redhat.com> X-Mailer: git-send-email 2.19.1 MIME-Version: 1.0 Sender: netdev-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: netdev@vger.kernel.org This series fixes a couple of issues exposed by running sch_cake as a leaf qdisc in an HFSC tree, which were discovered and reported by Pete Heist. The interaction between CAKE's GSO splitting and the parent qdisc's notion of its own queue length could cause queue stalls. While investigating the report, I also noticed that several qdiscs would dereference the skb pointer after dequeue, which is potentially problematic since the GSO splitting code also frees the original skb. See the individual patches in the series for details. Toke Høiland-Jørgensen (3): sched: Avoid dereferencing skb pointer after child enqueue sched: Fix detection of empty queues in child qdiscs sch_cake: Correctly update parent qlen when splitting GSO packets net/sched/sch_cake.c | 5 +++-- net/sched/sch_cbs.c | 3 ++- net/sched/sch_drr.c | 7 +++++-- net/sched/sch_dsmark.c | 3 ++- net/sched/sch_hfsc.c | 9 +++++---- net/sched/sch_htb.c | 3 ++- net/sched/sch_prio.c | 3 ++- net/sched/sch_qfq.c | 20 ++++++++++++-------- net/sched/sch_tbf.c | 3 ++- 9 files changed, 35 insertions(+), 21 deletions(-)