Received: by 2002:a05:6358:a55:b0:ec:fcf4:3ecf with SMTP id 21csp5844567rwb; Tue, 17 Jan 2023 20:12:56 -0800 (PST) X-Google-Smtp-Source: AMrXdXse32Ap+xqvp8v7iRqLkfhD9PktS6/iUdSQDw+jpo9c1M+krID1W1DUDbBt7OhDfMt9T/hG X-Received: by 2002:a17:902:e80c:b0:192:6b23:e38b with SMTP id u12-20020a170902e80c00b001926b23e38bmr6209177plg.24.1674015176535; Tue, 17 Jan 2023 20:12:56 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1674015176; cv=none; d=google.com; s=arc-20160816; b=TLzxqSAEvHXLI17F1VsNUeT1RXSgI+yfn0T2vT3SVyB3CyLo/iHw6PvaP9xicysBHk a4BRXwqT7cxQfYbnHbzGqtBACiIXIzjfsL4Tzs9G6Oz6WpkpOtiJ4tTFijsMhBYu4RJ8 2pKI6zDk5Hy6+kg34pcggm7itGRvFnNbsmd2ki4L8KMiMpwlHboFUdtGLvR0h4M4ILHh 3sPVMavpFzLkYinDtaR81T9/PUpAziXb9qsssH+Jvn1mtq1uLC6l2eB9FD+fjkh+Yas8 DmwRpI7LjoNpVkutG+Ok6Kattm286msYW9ELe1RbgfmIcyTu2Bj+/opHRzoZg3wG7Wd+ EMcg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :references:in-reply-to:message-id:subject:cc:to:from:date :dkim-signature; bh=MPAJ1XjYnlqAxQwv/eMI3o8KlarcP5YNtjVL5Rv7hos=; b=pbiI2g8TI3tNGk41ve8AOLxenDoce6b88Vnxvd16B5ClGW3sHB1/EO3yxwJoH0dm0P YJywKt+EjBZ5rs1qyVLQY3rD3tlCwiG+7s8xjIjOdCagcraX1BGqQ9NVqVWseYZmHcHs 9BDMLngetfihjVk8zR+oPcFFvctGPgKZoQgDhdy7332anUoqxxXxSIHSqvY2MtuRK8Mf +j/HAKuXUV0qFiOahEfrUPhdqYJ7PLuEWJtSBiiWia8arOWLWNkdOsY3/JZt+vq38YD+ /YSjciVeyhgezeAhatJF2SCCm/3LXf89jC3ZtMxRkdG3NdY8FQ+hCpGVVP7XNPAyQEks PIJA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b=HDk0iKij; 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=kernel.org Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id y4-20020a17090322c400b00189947bda10si37394783plg.127.2023.01.17.20.12.50; Tue, 17 Jan 2023 20:12:56 -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=@kernel.org header.s=k20201202 header.b=HDk0iKij; 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=kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S229618AbjARDw0 (ORCPT + 48 others); Tue, 17 Jan 2023 22:52:26 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:33974 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229448AbjARDwY (ORCPT ); Tue, 17 Jan 2023 22:52:24 -0500 Received: from dfw.source.kernel.org (dfw.source.kernel.org [139.178.84.217]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 7A0B3539A2; Tue, 17 Jan 2023 19:52:24 -0800 (PST) Received: from smtp.kernel.org (relay.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by dfw.source.kernel.org (Postfix) with ESMTPS id 13B1B6160E; Wed, 18 Jan 2023 03:52:24 +0000 (UTC) Received: by smtp.kernel.org (Postfix) with ESMTPSA id AD745C433EF; Wed, 18 Jan 2023 03:52:22 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1674013943; bh=i1VadpNoM63eIKc7YafNwYDH8B99ORLDSioJAK/BE34=; h=Date:From:To:Cc:Subject:In-Reply-To:References:From; b=HDk0iKijFpSBLtz3BzGz2gHS39W7dDBI6e1g87u3c76MWEiajL/rG53MwSrXRcGPo eBDoU3QWobNd1lSOjZLCkyatWD2jErwr4ymEu2P170FVF2RM+y5Y+arLXdgixLJBUj S5o/rmMbY17BRX55IBzNqREEz4rETV/4JP8YL16pxw191u6DYZjXNGT45Pbn0O5GnM 66l/wT5WoGIiCHWU18Uv48dl5FOd/+6P2obICQyKhd9Oa/dyMBUm2JQk3lNzE8DBnE nR1CFo3hkWdiuIQTRnyWQ/TGUpr8bZanDFzfOtWkhRk7btRBvJZhLL7pNgZ3bcky3F gADgcuIFHDZ4Q== Date: Tue, 17 Jan 2023 19:52:21 -0800 From: Jakub Kicinski To: Vladimir Oltean Cc: netdev@vger.kernel.org, linux-kernel@vger.kernel.org, "David S. Miller" , Eric Dumazet , Paolo Abeni , Michal Kubecek , Claudiu Manoil , Vinicius Costa Gomes , Xiaoliang Yang , Kurt Kanzenbach , Rui Sousa , Ferenc Fejes , Pranavi Somisetty , Harini Katakam , Colin Foster , UNGLinuxDriver@microchip.com, Alexandre Belloni , Andrew Lunn , Florian Fainelli Subject: Re: [PATCH v3 net-next 12/12] net: mscc: ocelot: add MAC Merge layer support for VSC9959 Message-ID: <20230117195221.3e216f90@kernel.org> In-Reply-To: <20230117085947.2176464-13-vladimir.oltean@nxp.com> References: <20230117085947.2176464-1-vladimir.oltean@nxp.com> <20230117085947.2176464-13-vladimir.oltean@nxp.com> MIME-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit X-Spam-Status: No, score=-7.1 required=5.0 tests=BAYES_00,DKIMWL_WL_HIGH, DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,RCVD_IN_DNSWL_HI, SPF_HELO_NONE,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 On Tue, 17 Jan 2023 10:59:47 +0200 Vladimir Oltean wrote: > Felix (VSC9959) has a DEV_GMII:MM_CONFIG block composed of 2 registers > (ENABLE_CONFIG and VERIF_CONFIG). Because the MAC Merge statistics and > pMAC statistics are already in the Ocelot switch lib even if just Felix > supports them, I'm adding support for the whole MAC Merge layer in the > common Ocelot library too. > > There is an interrupt (shared with the PTP interrupt) which signals > changes to the MM verification state. This is done because the > preemptible traffic classes should be committed to hardware only once > the verification procedure has declared the link partner of being > capable of receiving preemptible frames. > > We implement ethtool getters and setters for the MAC Merge layer state. > The "TX enabled" and "verify status" are taken from the IRQ handler, > using a mutex to ensure serialized access. Doesn't build now.