From patchwork Wed Feb 15 22:46:29 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Vladimir Oltean X-Patchwork-Id: 5478 Return-Path: Delivered-To: ouuuleilei@gmail.com Received: by 2002:adf:eb09:0:0:0:0:0 with SMTP id s9csp463115wrn; Wed, 15 Feb 2023 14:58:16 -0800 (PST) X-Google-Smtp-Source: AK7set9Vso9aB71oaUyX+VMjGXb5VPRnA1gNJSRrN1h2f1c/npcXQdIpMpkdcTFX9zWJHG7E2b8B X-Received: by 2002:aa7:d6d2:0:b0:4ab:2500:63b6 with SMTP id x18-20020aa7d6d2000000b004ab250063b6mr4011127edr.14.1676501896408; Wed, 15 Feb 2023 14:58:16 -0800 (PST) ARC-Seal: i=2; a=rsa-sha256; t=1676501896; cv=pass; d=google.com; s=arc-20160816; b=Uk9EQdox1uz949nmgVTHTlyPaK+HAJe6Tb47vjp/swWgle8RO8bqZPR2OPQg55NC+6 VzYr/opdCGOiy+XnPqxs09T8P2+qIP15ZEEu6pUb6DQqQvNQrq44PPsQ9yKjYbc3W8xM iXPDAxB0LFNlFn1Yy98zmHAvVMNXA/Un8X3Uwcz5Z9sOix4etIDko6/dSXIrgxk8ilnQ 99POIH7AnPfQ+E7YPSAhZeDiRCM8hRiVUG64YMyZ3C2h1hfe2mJJhcyK/Aue+XTTPHVm t+kMNUbWkxK53cia8rEK/Oqm3vonm/Ur8Jgckvg4dSxHv0Kmjd/b0uv2VjKacPR8UDXU x9CQ== ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:mime-version:content-transfer-encoding :message-id:date:subject:cc:to:from:dkim-signature; bh=Ar5kplMI4Kt2NpBOP70enFdc6bngcFvPoB3kgAg/WiA=; b=jXMEsK2Wz1uUfYe0dRHo8MaGTaSa+eLIIGgeKLyI8h/OSSk5Q8chW56/VzQop0zAOo jKVwTCqaSMCME/L7o55hTHMNMO4h+82u588YghfVxZbzASdmY3VOw4riTjg1FpZ0iBu4 A978rlOHzZ4o5nmJdo3qYZAwncXcGe/q2GqjVhBRgwrt7UgHbVLthW29uzHVtQzDw+oD g4aVcql/2vVbzUbJ2rneS/YtpdKP32xSqa9zhOsI2uHWSAUHW5WHKhK3ZiaqW/oaCI+C 4Wm+b+etojDBW2gVxEDj+ub/Pk2rf4r5biEa7Iy4mYI/6zIIYPh1XaviJ6su0wrDd2OO fjnQ== ARC-Authentication-Results: i=2; mx.google.com; dkim=pass header.i=@nxp.com header.s=selector2 header.b="OQ/Y+Spr"; arc=pass (i=1 spf=pass spfdomain=nxp.com dkim=pass dkdomain=nxp.com dmarc=pass fromdomain=nxp.com); spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=nxp.com Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id g18-20020aa7d1d2000000b004a2254ee2e7si132712edp.492.2023.02.15.14.57.28; Wed, 15 Feb 2023 14:58:16 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; dkim=pass header.i=@nxp.com header.s=selector2 header.b="OQ/Y+Spr"; arc=pass (i=1 spf=pass spfdomain=nxp.com dkim=pass dkdomain=nxp.com dmarc=pass fromdomain=nxp.com); spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=nxp.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S229886AbjBOWq5 (ORCPT + 99 others); Wed, 15 Feb 2023 17:46:57 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:46408 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229534AbjBOWqw (ORCPT ); Wed, 15 Feb 2023 17:46:52 -0500 Received: from EUR04-DB3-obe.outbound.protection.outlook.com (mail-db3eur04on2055.outbound.protection.outlook.com [40.107.6.55]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 57430233E1; Wed, 15 Feb 2023 14:46:50 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=IN58aNS434JWeCM4IvMC+c18d1LlQIDTqkh7driTScSL9uAhxzvfclXLtn/SSos0hD7ut2eyVRJ5I9UVfNwKQItcBKUBukbYScu5dMJL+HsziJqOOmDi2DOoIacuCkmb9dLkZTsQreNzbVBP3mJjx1NYkNRCp91qgoVqSRw7VxuRYWj2at0sDYRjXR+dKtDZOGSJvxWat7aZKA61qfEeFhp9JMUzDEiTZD7zrsYWvau7Edy+QxmN7KYcpH39n6+TQ8H26P5gOrS99U/pnXqdvNs4PCuKeO+sFVlPYVCi5NZtT+d754GNFzqTmzaMOetJEsOGpIDWqwtQ6/7ztHEApw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector9901; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-AntiSpam-MessageData-ChunkCount:X-MS-Exchange-AntiSpam-MessageData-0:X-MS-Exchange-AntiSpam-MessageData-1; bh=Ar5kplMI4Kt2NpBOP70enFdc6bngcFvPoB3kgAg/WiA=; b=nxKHkCRVcqt/ycFjHxAjAQKIxNN3hFk3FDvO6DjqUxgaW12UUiI6DZok9JyOf4ng8j8AkEpgaZAgj6J3tYtyLG8sBbxG5fW9jK4Y0p9TjesP7uZKM0H0qIUaXBr6fwhOPvNnimold+CBphHK1Km3FeY1C9o2ijmTtV8xcFrdJBSvD6aUxzW2DDdbqqsUY2PjKbJV1QtWO8SZ5PHZs+ygU+oaR02r5tAw48OXoX8OgliI8t7WuXowRC5U3uAioIi+tMAfETiN4SMV02sSsq/sMemj/Sse2xZjoidykAke5aAau1cfhsb6a/MgTiroXUJYqq95xHUDscdggaCeqSxaSA== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=nxp.com; dmarc=pass action=none header.from=nxp.com; dkim=pass header.d=nxp.com; arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=nxp.com; s=selector2; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=Ar5kplMI4Kt2NpBOP70enFdc6bngcFvPoB3kgAg/WiA=; b=OQ/Y+Spr2t/D0hKKMNz7GZdSx85BRlT5kK/puiuw0fXs71xE9MbB4X0yoc0SE6Af6Pd65NFokfOK2mmJpZhxCwUyXg/HyMC8Vchd01/cNYlOiQEfMepqt0ANkI4v3WbOp4PEO2Zur3XYipBHw17VttjNOCvh+BRa1zesCNUfHAQ= Authentication-Results: dkim=none (message not signed) header.d=none;dmarc=none action=none header.from=nxp.com; Received: from VI1PR04MB5136.eurprd04.prod.outlook.com (2603:10a6:803:55::19) by AM9PR04MB8748.eurprd04.prod.outlook.com (2603:10a6:20b:409::15) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.6086.26; Wed, 15 Feb 2023 22:46:47 +0000 Received: from VI1PR04MB5136.eurprd04.prod.outlook.com ([fe80::3cfb:3ae7:1686:a68b]) by VI1PR04MB5136.eurprd04.prod.outlook.com ([fe80::3cfb:3ae7:1686:a68b%4]) with mapi id 15.20.6086.026; Wed, 15 Feb 2023 22:46:47 +0000 From: Vladimir Oltean To: netdev@vger.kernel.org Cc: "David S. Miller" , Eric Dumazet , Jakub Kicinski , Paolo Abeni , Jamal Hadi Salim , Cong Wang , Jiri Pirko , Vinicius Costa Gomes , Kurt Kanzenbach , Gerhard Engleder , linux-kernel@vger.kernel.org Subject: [PATCH net-next 0/3] taprio queueMaxSDU fixes Date: Thu, 16 Feb 2023 00:46:29 +0200 Message-Id: <20230215224632.2532685-1-vladimir.oltean@nxp.com> X-Mailer: git-send-email 2.34.1 X-ClientProxiedBy: AM3PR04CA0138.eurprd04.prod.outlook.com (2603:10a6:207::22) To VI1PR04MB5136.eurprd04.prod.outlook.com (2603:10a6:803:55::19) MIME-Version: 1.0 X-MS-PublicTrafficType: Email X-MS-TrafficTypeDiagnostic: VI1PR04MB5136:EE_|AM9PR04MB8748:EE_ X-MS-Office365-Filtering-Correlation-Id: ed46aead-6238-428e-25a1-08db0fa684de X-MS-Exchange-SenderADCheck: 1 X-MS-Exchange-AntiSpam-Relay: 0 X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: jzzCBEar2l9ynAo6ViEmwOiAk1npwc0WNWLjoDnGf/Euru8A5xcjpis0llOpQ8WoWNgPERB4Bg6Z76CJOu2QkzSGXT8HRy9MhgW6mXJpucAeVlOT7sSqwbFcJ/NxF5GfvwRUzzXifUO4WhdbKqa4epFihPNIO08VT3+HWJnNrQvJ9bIxmn1NNKrwzVCjuUVQNlyjF/roviOSm+o6P7WDY0IIbOAxcvRDl7dDOtLfbG9b5HKpStfNV+fdhWUs0JBCSUOtULVBsBsytHfbHRgg1EN5gPheusydBv1w0xhM3BQVuH6/XUs7Jar9C1X2MZhRNTKROq4iGEfJ7P8SKBALjL6b8vexUqIR55ee8YrW60PncjR6DrYqIlU+t79frp3mtrO+mGvUukEw2QLvtC2ozptOeU/X0V3pykflFkwkmYc5fbfeFw2xODqahsAk/oh5LGBdULHfuA/5U4ktYwlb6UU0JtWodm4zyaWx0Wk9jkA9c/VgmA2DgZwdJxcgjiAoAVpEQz6MpAeKLHUk4V5AGxhj9WEsA14TYGmfNBzwO6Iqo54s408Wznt+gTtDWMBQmfXpkcWRdZaMB7bFwXeVBp7jh4P3iQuyAxAIQX4cEdgnEKrZ9u2QLL1cQdREQ3Y/srucJfOSKHwUMcJSIEqeSWTGHyIZVEDoKk+J+i8V3zNo3/tZkY9kqtSr2v863qrrCrtW2EkWyD0BXCKcU2svpg== X-Forefront-Antispam-Report: CIP:255.255.255.255;CTRY:;LANG:en;SCL:1;SRV:;IPV:NLI;SFV:NSPM;H:VI1PR04MB5136.eurprd04.prod.outlook.com;PTR:;CAT:NONE;SFS:(13230025)(4636009)(136003)(39860400002)(366004)(396003)(376002)(346002)(451199018)(478600001)(6666004)(6512007)(26005)(38100700002)(1076003)(186003)(6506007)(54906003)(6486002)(83380400001)(38350700002)(52116002)(41300700001)(2616005)(2906002)(86362001)(36756003)(4326008)(8676002)(6916009)(66476007)(66946007)(66556008)(316002)(44832011)(5660300002)(8936002)(7416002)(4744005);DIR:OUT;SFP:1101; X-MS-Exchange-AntiSpam-MessageData-ChunkCount: 1 X-MS-Exchange-AntiSpam-MessageData-0: 8xyIjye8BfboZVzMo6gmcBmTnqzHiOQlZnjK8GrInp/w+vXYl1WVHgU55+bWI5MIid8tDJ5/aNStusijmywPjQtXceQ51Lw1K4e238MubWLtO50Tt0WeazLz4R6wyWN/CRnQAcGkxg9HHZtXo+Z39JhaPw05h57xx30Fd9rc3VfF1hFLKfQ4OUo+wAFwRCmfRknR8tUvKMeodsRx5sPKGfZG7WKkPqZH3m8C4BqIqhx22TuceNDYm1miNKbO0INHwLjBjTsKq3ECwd0V2QQWGmuzo3yNxptlnz7rsPOry4s31+scYO/nLLwbU7axfDw5kQw5ZKqld/eA4az+ftBJj98ShtGx5ruM98gA0ZS9GfOVWL3RQuPrCrKa9LFL4xSCNwQL/aCr1eT3R/Kkt0DMw2c4kIi0n25o5NFycxXUP3n7BCt2fxm5MkI/u1bRnm91DQNYQGKqbjHEOY5/JK+sZyDfUqI4HyWm7DxFuKsr45SrfBuI9FBsMXlDTUNFcPUK91Q5cDT99GRrCr1km/eQqE3NqbGrtpiS8+u8qkL7zlgH8JbgnYJSbVRIhH+oupaFdeFtA+nvwd8SUnaVH35THBIQVhmK1zjF0e+7c5QsSj7yPPeZk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-MS-Exchange-CrossTenant-AuthSource: VI1PR04MB5136.eurprd04.prod.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-OriginalArrivalTime: 15 Feb 2023 22:46:47.4477 (UTC) X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-CrossTenant-Id: 686ea1d3-bc2b-4c6f-a92c-d99c5c301635 X-MS-Exchange-CrossTenant-MailboxType: HOSTED X-MS-Exchange-CrossTenant-UserPrincipalName: oik6C+QqPGtMY2YLAUR0NNng761opV6GPGIcmqBBXhhWSDnucsNbX99ibnZbnt45s4JKWZFnJz5AwEsWa8gajg== X-MS-Exchange-Transport-CrossTenantHeadersStamped: AM9PR04MB8748 X-Spam-Status: No, score=-2.1 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,RCVD_IN_DNSWL_NONE, RCVD_IN_MSPIKE_H2,SPF_HELO_PASS,SPF_PASS autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org X-getmail-retrieved-from-mailbox: =?utf-8?q?INBOX?= X-GMAIL-THRID: =?utf-8?q?1757939652329717337?= X-GMAIL-MSGID: =?utf-8?q?1757939652329717337?= This fixes 3 issues noticed while attempting to reoffload the dynamically calculated queueMaxSDU values. These are: - Dynamic queueMaxSDU is not calculated correctly due to a lost patch - Dynamically calculated queueMaxSDU needs to be clamped on the low end - Dynamically calculated queueMaxSDU needs to be clamped on the high end Vladimir Oltean (3): net/sched: taprio: fix calculation of maximum gate durations net/sched: taprio: don't allow dynamic max_sdu to go negative after stab adjustment net/sched: taprio: dynamic max_sdu larger than the max_mtu is unlimited net/sched/sch_taprio.c | 44 +++++++++++++++++++++++++----------------- 1 file changed, 26 insertions(+), 18 deletions(-)