From patchwork Mon Apr 3 10:52:36 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Vladimir Oltean X-Patchwork-Id: 13198019 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id CE90BC76196 for ; Mon, 3 Apr 2023 10:53:20 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S231706AbjDCKxT (ORCPT ); Mon, 3 Apr 2023 06:53:19 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:42838 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S231971AbjDCKxN (ORCPT ); Mon, 3 Apr 2023 06:53:13 -0400 Received: from EUR05-AM6-obe.outbound.protection.outlook.com (mail-am6eur05on2060.outbound.protection.outlook.com [40.107.22.60]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 53B9310254 for ; Mon, 3 Apr 2023 03:53:05 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=GN+DaKnZAR0Xi3Tr9Dn4w5A4oQo7CI+3jeClnBHaZu4h1SGfZs6s5meJxsIRibOK36lEQwReXgakLgypBdGLgY3odjYU1K7ONRATYaDRe62qvCLNeJhKtwG2dIVs4hP//q1k0p+I5MDJH6KYiCHGdP2KhVuJmVPoMfdUJUDK65AAlhES+CBnBPLXDtg8ZZNnLnbwW2gj1MBUYNCATW+Z58/l60BXCKa52VjXtiaxzk5EvrOUWyFTFrhVX7wtciNGeOhk+qGo0NGbbnyMygrn0XKCpibaaP9vn99DlZN8qDt/BOrfsmdaeFTs3ARSRsjqz6mfUPSRE9xEQ+SAWU12Fg== 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=yWv2FeA1huTjvL9rXv9TEe75NzMKbwejjyh20YxAQV0=; b=hJA44PyHUR+6jIWApVx9oHH8ovl8gIY1sQcWrdsZYR3g0VXnSV9foVu8OxbAQ1U4/2xQHIAFkzTjfCaqgxPQjCOmq7MorlihhSELpw4DXHTTzUA69TnKHMxli3L7gH3INIrC8JIPhjh25zPGn4vEsX68c5IXPWk7y8rm12s8jqKuTdiGsHtW7Zi0scynlQz5Z2vQ1Qi9sM1remUffJ9TIYB6RU+Qh/H+Xujeo1ZuYWEaEQVzKyK8zeWj7KoMQ5hZbe/wFkaqgbD76nNOzgNepdLtvxj6t7Q1MPOvtAL99JqgCZObAxZ3rrMACJTwflnbavu+yyrjDW9+CuASXxgFiA== 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=yWv2FeA1huTjvL9rXv9TEe75NzMKbwejjyh20YxAQV0=; b=NFgaP9CRqzaTcZbBoiArVmCdgXAYMqKfSNjDKmYg2amxgjGws+ogRTSFV2tDOwywlBHOpSgd86zMKtAbkiiNTgiHGefxu7e4TUlf2rL0qXN+wefkLNHHOeJ2eRoesANIN5NNMMdJNpGYxRA7g0GL6A4Gnbabn3eFAqZva0pVnB8= Authentication-Results: dkim=none (message not signed) header.d=none;dmarc=none action=none header.from=nxp.com; Received: from AM0PR04MB6452.eurprd04.prod.outlook.com (2603:10a6:208:16d::21) by DB9PR04MB8479.eurprd04.prod.outlook.com (2603:10a6:10:2c5::10) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.6254.33; Mon, 3 Apr 2023 10:53:03 +0000 Received: from AM0PR04MB6452.eurprd04.prod.outlook.com ([fe80::dfa2:5d65:fad:a2a5]) by AM0PR04MB6452.eurprd04.prod.outlook.com ([fe80::dfa2:5d65:fad:a2a5%3]) with mapi id 15.20.6254.026; Mon, 3 Apr 2023 10:53:03 +0000 From: Vladimir Oltean To: netdev@vger.kernel.org Cc: David Ahern , Stephen Hemminger Subject: [PATCH iproute2-next 0/9] Add tc-mqprio and tc-taprio support for preemptible traffic classes Date: Mon, 3 Apr 2023 13:52:36 +0300 Message-Id: <20230403105245.2902376-1-vladimir.oltean@nxp.com> X-Mailer: git-send-email 2.34.1 X-ClientProxiedBy: FRYP281CA0006.DEUP281.PROD.OUTLOOK.COM (2603:10a6:d10::16) To AM0PR04MB6452.eurprd04.prod.outlook.com (2603:10a6:208:16d::21) MIME-Version: 1.0 X-MS-PublicTrafficType: Email X-MS-TrafficTypeDiagnostic: AM0PR04MB6452:EE_|DB9PR04MB8479:EE_ X-MS-Office365-Filtering-Correlation-Id: 33fa808d-bd2a-4066-e516-08db343198fe X-MS-Exchange-SenderADCheck: 1 X-MS-Exchange-AntiSpam-Relay: 0 X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: SVnsD+NeGnLqRyZSVxvC5rrTdN+iQBLHsedAaRMGbyKf721vGtZrh6sel/5ne++M2fGKHQ8ymzt9fOMs9uYkifzqGZYixioVluuaBXH9OmBVqjkYIl0Sq3LkWoZg07U1WR5H6uIEmt7/Azx7/b/Z8OJeT0iuFb0XnEafGkY8PZbHXzlPRN/BRdbgiYoWbTLAexqjIzWOEWI2loBtr5PpbWqx/lZSKFF28vo/7fZLvLeQqrkUwIlDPPnmzv31SYf9vGmKL48nyvpTD+FNgJo34RDLK8pBz5ORangjiukgIhlBOB8RXZT8dE8ghgSNUlsNblip42bKvnW1e3asYMgm3AaeZIk5Uyz/pZtMRMrGu7TZ5WDlewksYQvKuxcVBFMu7pAAYMEH9nhypyMzA0OQ2EAmeUYEmeMKR9Gfnwxy8sfciyAPx39Ohyg6UWKCA99iJFqv6L3w3EmEox5Ax/oumA/LQDyLkNvy+eZ2E6aCBUDMZJeZrRsSgPxPvkw8tQhz9GmhX3qY0WWsQxauqaMTn72R8fUBdgn73i3cAcf0j2jgSY9gRehmW9FgTaK6cAHonBWaL7GfFoTNiyS9bAttaA5crsBNvoWQAKSjDTw4wsY= X-Forefront-Antispam-Report: CIP:255.255.255.255;CTRY:;LANG:en;SCL:1;SRV:;IPV:NLI;SFV:NSPM;H:AM0PR04MB6452.eurprd04.prod.outlook.com;PTR:;CAT:NONE;SFS:(13230028)(4636009)(396003)(136003)(39860400002)(376002)(346002)(366004)(451199021)(8676002)(6916009)(66556008)(66476007)(66946007)(54906003)(316002)(478600001)(8936002)(44832011)(41300700001)(5660300002)(38100700002)(38350700002)(4326008)(186003)(83380400001)(2616005)(52116002)(966005)(6486002)(6666004)(1076003)(26005)(6506007)(6512007)(86362001)(36756003)(2906002);DIR:OUT;SFP:1101; X-MS-Exchange-AntiSpam-MessageData-ChunkCount: 1 X-MS-Exchange-AntiSpam-MessageData-0: T5nncTYl3FBxY4r5hem/wVgmawD8OyvPRatFFVInkeD967tNXMMB68O2bqUz1gS96T/2ad7+JIzuLIJzbgDcUCG3HGeuVrPd78iSa+aNoSoedJGyE6ucFbmnHNPbv5//BPltmt3CSMAzkAL0w+9VVBIqXt6rCVtMduaFnjuYdIWbqlaz3DsNfjIErdp+wDFxu0rqhXzxt1f1lWAcoj4ds0w7SHx2YFhi2dYdfb+spSRMAZsGzSXNT7e3Yj6eJmI1bwlZVxEK5EtaHQFWueazbxbVKzOzCFutGg8AU7UBKbELYCPMfAGT5otKjTwyPmlKaKqO4LHmP/pByfwzvLa2bA7/xQiSmpFB4iCuhpvaejU3k0G5f5PVKpV8wC6CxA2xcTNePu5jOOpfORJign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nFKbSFS/H+5pPmgyUCz5nyCsZom5Q78nTJ0REV04C6Svok47vAtgoxnUPS9CLOGeVQkEM5xnVDWLTqqykr4ys+bXYCo0gbTLF1H1Q9tCueqEBwyU9n7NPfQT4Qhi9uxiOKRDuuITWqYohEyz6WjJw== X-OriginatorOrg: nxp.com X-MS-Exchange-CrossTenant-Network-Message-Id: 33fa808d-bd2a-4066-e516-08db343198fe X-MS-Exchange-CrossTenant-AuthSource: AM0PR04MB6452.eurprd04.prod.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-OriginalArrivalTime: 03 Apr 2023 10:53:02.9428 (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: 4D4rIvQT35acxNc4A0vraBcmTcxkOEFQqrXhYpBZORVettIoMJUhZeHvL+W9B/GUhavHuoz9rtH9lQqTnfyVCA== X-MS-Exchange-Transport-CrossTenantHeadersStamped: DB9PR04MB8479 Precedence: bulk List-ID: X-Mailing-List: netdev@vger.kernel.org X-Patchwork-Delegate: dsahern@gmail.com This is the iproute2 support for the tc program to make use of the kernel feature for preemptible traffic classes described here: https://patchwork.kernel.org/project/netdevbpf/cover/20230403103440.2895683-1-vladimir.oltean@nxp.com/ The state of the man pages prior to this work was a bit unsatisfactory, so patches 03-07 contain some man page cleanup in tc-taprio(8) and tc-mqprio(8). Vladimir Oltean (9): uapi: add definitions for preemptible traffic classes in mqprio and taprio utils: add max() definition tc/taprio: add max-sdu to the man page SYNOPSIS section tc/taprio: add a size table to the examples from the man page tc/mqprio: fix stray ] in man page synopsis tc/mqprio: use words in man page to express min_rate/max_rate dependency on bw_rlimit tc/mqprio: break up synopsis into multiple lines tc/mqprio: add support for preemptible traffic classes tc/taprio: add support for preemptible traffic classes include/uapi/linux/pkt_sched.h | 17 ++++++ include/utils.h | 8 +++ man/man8/tc-mqprio.8 | 92 ++++++++++++++++++++++--------- man/man8/tc-taprio.8 | 27 ++++++++-- tc/q_mqprio.c | 98 +++++++++++++++++++++++++++++++++ tc/q_taprio.c | 99 +++++++++++++++++++++++++--------- 6 files changed, 289 insertions(+), 52 deletions(-)