Received: by 2002:ab2:6991:0:b0:1f7:f6c3:9cb1 with SMTP id v17csp929063lqo; Wed, 8 May 2024 22:15:53 -0700 (PDT) X-Forwarded-Encrypted: i=3; AJvYcCVipoJ6V1AkkJ2ZZbTdqjik4ta8u7eTP+1rcawawt4KErA6ZzEMFUK6jjJxUG/zS5G5lGVofcXQhPkukeqrYoPA9fHK05/ZR9r5Su2bxA== X-Google-Smtp-Source: AGHT+IH70NpciKhdBEUPq0uTY/MZEgRG5ISABDP8Qvd7MD4hpi7mjKfp8iQZN7F3BBrbAWRP2/13 X-Received: by 2002:a05:6a00:1405:b0:6f3:ea4b:d1c1 with SMTP id d2e1a72fcca58-6f49c1f5e1emr5954419b3a.1.1715231753236; Wed, 08 May 2024 22:15:53 -0700 (PDT) ARC-Seal: i=2; a=rsa-sha256; t=1715231753; cv=pass; d=google.com; s=arc-20160816; b=FrzJSdputGYhT/p7IJckmkrnyHVLwaaH0IhHnr5B8mCE5Lv8JBGWDEPxtDTI9ASmIX u1wy4146lSEentytPQD9tFh4miN1Gfa5rU530pyDx/3g7rIDDrjhNjwv2GKq/U3OtdfM 4PJUPC1x8+V+Sh44oCXGDA0kw8lCcL2eejtTJ9dk1sC58twrvRlc3lvBvtkcIFkmLrCw RhRWsFPckDvaPjIvErvX6xyhonIhuKEiXp2+f3fYk7F9F3ZyANk5NLXOhMAb5oyCx5dh HHYTnqQNBUIYWwWJ7LK7rDJAj6A40nN9j8tlPov6y/dCKK9q1mzmgDKyATawqHcoVKXZ bwiA== ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=in-reply-to:content-disposition:mime-version:list-unsubscribe :list-subscribe:list-id:precedence:references:message-id:subject:cc :to:from:date; bh=2Jrb1pEA39oeEDdTcQoMExhySm7HrxYFvGAMAasTtZY=; fh=XiLi8SqjoYBgh9uwx9cNpyy771VowFG+uYuIoyi+jkY=; b=b8MYj7EQzY/BGrF2pS9/8oIOuPOUxkB0a4rEWKPGnuT3Cev/ea2M3YUDliHj+3D7oZ 6vN5J/85Nm7dPLea5TNnWLIeO5Ek//RhxeBQesIjkHrmzChAkGSvLQnwNr2wCN9WeV8F CmA3XzX+eodvR8gZa9FlzXk0fSK1gpZWje9b3zqQdiT7L3ahimUfTxDzB2cvrmmFIC5e WFJX9ErVz79SH2kcsPfw6b8ICK7t2wEk32spJNuLTAH/eZqAG/XLiBF8S4OCAKORnDTJ 7wnA4skqQuVvGgcraZCQO5vm1aDub72hvKuvXewTRR90vNr+vL5B53BFjk4h/lMxMCUY TXsQ==; dara=google.com ARC-Authentication-Results: i=2; mx.google.com; arc=pass (i=1 spf=pass spfdomain=pengutronix.de); spf=pass (google.com: domain of linux-kernel+bounces-174149-linux.lists.archive=gmail.com@vger.kernel.org designates 139.178.88.99 as permitted sender) smtp.mailfrom="linux-kernel+bounces-174149-linux.lists.archive=gmail.com@vger.kernel.org" Return-Path: Received: from sv.mirrors.kernel.org (sv.mirrors.kernel.org. [139.178.88.99]) by mx.google.com with ESMTPS id d2e1a72fcca58-6f4d2b1db55si725879b3a.269.2024.05.08.22.15.52 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 08 May 2024 22:15:53 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel+bounces-174149-linux.lists.archive=gmail.com@vger.kernel.org designates 139.178.88.99 as permitted sender) client-ip=139.178.88.99; Authentication-Results: mx.google.com; arc=pass (i=1 spf=pass spfdomain=pengutronix.de); spf=pass (google.com: domain of linux-kernel+bounces-174149-linux.lists.archive=gmail.com@vger.kernel.org designates 139.178.88.99 as permitted sender) smtp.mailfrom="linux-kernel+bounces-174149-linux.lists.archive=gmail.com@vger.kernel.org" Received: from smtp.subspace.kernel.org (wormhole.subspace.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by sv.mirrors.kernel.org (Postfix) with ESMTPS id DB0C1285BDC for ; Thu, 9 May 2024 05:15:52 +0000 (UTC) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id 503851494BB; Thu, 9 May 2024 05:15:37 +0000 (UTC) Received: from metis.whiteo.stw.pengutronix.de (metis.whiteo.stw.pengutronix.de [185.203.201.7]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 5ACAC14900A for ; Thu, 9 May 2024 05:15:34 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=185.203.201.7 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1715231736; cv=none; b=EDgmXoBH91r3mvyOA1RDFVouwyQQJ9HczSujM+N+yd3qHaiE6HqRHoO0Dmh598JOQnu6pR+ylgqK/Gj9YDMj7pcCcHT6gCOGbmd6uhSgGUSjba0XWpGrpzWZllHhUVJpITjp+XFGwCRKVEcUkfO+l7uagrX+JyaEheaeU/E9S10= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1715231736; c=relaxed/simple; bh=cIDQZAOFPzs20dF1EbvJv64A34Ri3yMsRyyX/TylLmk=; h=Date:From:To:Cc:Subject:Message-ID:References:MIME-Version: Content-Type:Content-Disposition:In-Reply-To; b=WqgwvmTZ7UpL8PJEmMnXxh62pWVGrqjGEaKAprkxFUCF2VtrUkmyiS9DH0qCpTMOgOUo5c45MbrjCMbgzjW1LpHZ9PqlKH0y+BqOKjqT5TLIwgRHNTBlvhAagx8RoGCnUS/VSn25f+q+nxgCdrkRph/jqVul5awldjqM6m7Nr68= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dmarc=none (p=none dis=none) header.from=pengutronix.de; spf=pass smtp.mailfrom=pengutronix.de; arc=none smtp.client-ip=185.203.201.7 Authentication-Results: smtp.subspace.kernel.org; dmarc=none (p=none dis=none) header.from=pengutronix.de Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=pengutronix.de Received: from drehscheibe.grey.stw.pengutronix.de ([2a0a:edc0:0:c01:1d::a2]) by metis.whiteo.stw.pengutronix.de with esmtps (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1s4w7o-0004Iw-3N; Thu, 09 May 2024 07:15:24 +0200 Received: from [2a0a:edc0:2:b01:1d::c5] (helo=pty.whiteo.stw.pengutronix.de) by drehscheibe.grey.stw.pengutronix.de with esmtps (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384 (Exim 4.94.2) (envelope-from ) id 1s4w7l-000P7C-Tw; Thu, 09 May 2024 07:15:21 +0200 Received: from ore by pty.whiteo.stw.pengutronix.de with local (Exim 4.96) (envelope-from ) id 1s4w7l-002KX4-2a; Thu, 09 May 2024 07:15:21 +0200 Date: Thu, 9 May 2024 07:15:21 +0200 From: Oleksij Rempel To: Arun.Ramadoss@microchip.com Cc: andrew@lunn.ch, olteanv@gmail.com, davem@davemloft.net, Woojung.Huh@microchip.com, pabeni@redhat.com, edumazet@google.com, f.fainelli@gmail.com, kuba@kernel.org, kernel@pengutronix.de, dsahern@kernel.org, san@skov.dk, willemb@google.com, linux-kernel@vger.kernel.org, netdev@vger.kernel.org, horms@kernel.org, UNGLinuxDriver@microchip.com Subject: Re: [PATCH net-next v1 3/3] net: dsa: microchip: dcb: set default apptrust to PCP only Message-ID: References: <20240508103902.4134098-1-o.rempel@pengutronix.de> <20240508103902.4134098-4-o.rempel@pengutronix.de> Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Disposition: inline In-Reply-To: X-Sent-From: Pengutronix Hildesheim X-URL: http://www.pengutronix.de/ X-Accept-Language: de,en X-Accept-Content-Type: text/plain X-SA-Exim-Connect-IP: 2a0a:edc0:0:c01:1d::a2 X-SA-Exim-Mail-From: ore@pengutronix.de X-SA-Exim-Scanned: No (on metis.whiteo.stw.pengutronix.de); SAEximRunCond expanded to false X-PTX-Original-Recipient: linux-kernel@vger.kernel.org Hi Arun, On Wed, May 08, 2024 at 03:11:24PM +0000, Arun.Ramadoss@microchip.com wrote: > Hi Oleksij, > > On Wed, 2024-05-08 at 12:39 +0200, Oleksij Rempel wrote: > > EXTERNAL EMAIL: Do not click links or open attachments unless you > > know the content is safe > > > > > > -static const u8 ksz8_port2_supported_apptrust[] = { > > - DCB_APP_SEL_PCP, > > -}; > > - > > static const char * const ksz_supported_apptrust_variants[] = { > > "empty", "dscp", "pcp", "dscp pcp" > > }; > > @@ -771,9 +767,8 @@ int ksz_port_get_apptrust(struct dsa_switch *ds, > > int port, u8 *sel, int *nsel) > > */ > > int ksz_dcb_init_port(struct ksz_device *dev, int port) > > { > > - const u8 *sel; > > + const u8 ksz_default_apptrust[] = { DCB_APP_SEL_PCP }; > > int ret, ipm; > > - int sel_len; > > > > if (is_ksz8(dev)) { > > ipm = ieee8021q_tt_to_tc(IEEE8021Q_TT_BE, > > @@ -789,18 +784,8 @@ int ksz_dcb_init_port(struct ksz_device *dev, > > int port) > > if (ret) > > return ret; > > > > - if (ksz_is_ksz88x3(dev) && port == KSZ_PORT_2) { > > - /* KSZ88x3 devices do not support DSCP classification > > on > > - * "Port 2. > > - */ > > - sel = ksz8_port2_supported_apptrust; > > - sel_len = ARRAY_SIZE(ksz8_port2_supported_apptrust); > > If we remove this, How the user application knows about the DSCP > resistriction of KSZ8 port 2. Is it implemented in other functions? Yes, it is implemented in ksz_port_set_apptrust()->ksz88x3_port_apptrust_quirk(). This patch affects only default configuration. -- Pengutronix e.K. | | Steuerwalder Str. 21 | http://www.pengutronix.de/ | 31137 Hildesheim, Germany | Phone: +49-5121-206917-0 | Amtsgericht Hildesheim, HRA 2686 | Fax: +49-5121-206917-5555 |