From mboxrd@z Thu Jan 1 00:00:00 1970 From: David Miller Subject: Re: [PATCH net-next 0/8] mlxsw: Support DSCP prioritization and rewrite Date: Fri, 27 Jul 2018 13:18:18 -0700 (PDT) Message-ID: <20180727.131818.1528635320435833585.davem@davemloft.net> References: <20180727122702.17995-1-idosch@mellanox.com> Mime-Version: 1.0 Content-Type: Text/Plain; charset=us-ascii Content-Transfer-Encoding: 7bit Cc: netdev@vger.kernel.org, jiri@mellanox.com, petrm@mellanox.com, mlxsw@mellanox.com, john.fastabend@gmail.com To: idosch@mellanox.com Return-path: Received: from shards.monkeyblade.net ([23.128.96.9]:38194 "EHLO shards.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S2389341AbeG0Vlz (ORCPT ); Fri, 27 Jul 2018 17:41:55 -0400 In-Reply-To: <20180727122702.17995-1-idosch@mellanox.com> Sender: netdev-owner@vger.kernel.org List-ID: From: Ido Schimmel Date: Fri, 27 Jul 2018 15:26:54 +0300 > Petr says: > > On ingress, a network device such as a switch assigns to packets > priority based on various criteria. Common options include interpreting > PCP and DSCP fields according to user configuration. When a packet > egresses the switch, a reverse process may rewrite PCP and/or DSCP > headers according to packet priority. > > So far, mlxsw has supported prioritization based on PCP (802.1p priority > tag). This patch set introduces support for prioritization based on > DSCP, and DSCP rewrite. > > To configure the DSCP-to-priority maps, the user is expected to invoke > ieee_setapp and ieee_delapp DCBNL ops, e.g. by using lldptool: ... > With this patch set, mlxsw uses these values to configure priority for > DSCP values not explicitly specified in DSCP APP map. In the future we > expect to also use this to configure default port priority for untagged > packets. > > Access to DSCP-to-priority map, priority-to-DSCP map, and default > priority for a port is exposed through three new DCB helpers. Like the > already-existing dcb_ieee_getapp_mask() helper, these helpers operate in > terms of bitmaps, to support the arbitrary M:N mapping that the APP > rules allow. Such interface presents all the relevant information from > the APP database without necessitating exposition of iterators, locking > or other complex primitives. It is up to the driver to then digest the > mapping in a way that the device supports. In this patch set, mlxsw > resolves conflicts by favoring higher-numbered DSCP values and > priorities. Series applied, thank you!