Received: by 2002:a05:6358:11c7:b0:104:8066:f915 with SMTP id i7csp4213434rwl; Mon, 10 Apr 2023 07:47:39 -0700 (PDT) X-Google-Smtp-Source: AKy350bPaKH607b+RGoQT5NvuxsXRuFeU0aSMrQ8+OOJKie7Xq0jvd3vFBpLbQYkmPBKxTSzs4LZ X-Received: by 2002:aa7:d512:0:b0:504:98f1:464c with SMTP id y18-20020aa7d512000000b0050498f1464cmr4144762edq.23.1681138059112; Mon, 10 Apr 2023 07:47:39 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1681138059; cv=none; d=google.com; s=arc-20160816; b=JPHmWWWWAKQBESMc9bmFOq+q2ixflQHKzjTK9k3tRKc/Yq4ovcUI8lbw21UGusmvYD qLFyHN7bJ/PZuwdb+3t1qarl1KwfXED4g/AmPOpBov5CNP863D/7ixej6D3tGt4JVQMM PCEp8yIpSDrtqv23KsVDPNRmq9TZopPqJQGbTFs9YvXwvq55R4wBDdpQEQ0xlGs5MqFZ fqO090nkYG/mYwXmvlK7FHSjkRK554LmzYz3hekyRpvSdTWK7UG+oSuW+ElOXx5qZEof yOvnLqh84GpMRXKKvIeD7udcN0AUNk70qeA6Npd2zq1PISLj+WzyaGuLqiArXOQy7S/Q 1JUA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:in-reply-to:content-transfer-encoding :content-disposition:mime-version:references:message-id:subject:cc :to:from:date; bh=ao7a1jlKXO9QxtUbs7LpleA62bg9n/fodcn4PT6hiTE=; b=0zUWsKC4iD2Mym4SzxWDcAntYeaSCeG5IkRco3Rddr+OwhTgNKK3VotD6cc9f0waM/ 6x8o4JM6CBOiE7EGGIbaLpqbpkQDEcGKOGRwH9rB3oa4LOdaH9Bufq/+zaISbPDNjpP+ iio1v9EOnZoxJRXV5bxBkyc6ttfCY7Mzme9Vi55cUaG7PCq2yFdnWUG8smxs5szpU4z0 zIMHnmK93pylTaJH/7izt+qk/2QNvHLdCiwX1+BQpIEFRRmc0iqAcZXot+paaTpCoI9H uW34fozGNegNQ1RXqnGSp64v65yOqs1ocEBjldWMtJd0WfJ9F8CMibOht9AvuHM6b7rU TRVg== ARC-Authentication-Results: i=1; mx.google.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 Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id d9-20020a50ea89000000b004fd21257a30si9106697edo.623.2023.04.10.07.47.14; Mon, 10 Apr 2023 07:47:39 -0700 (PDT) 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; 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 Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S229861AbjDJOhc (ORCPT + 99 others); Mon, 10 Apr 2023 10:37:32 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:39930 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229840AbjDJOha (ORCPT ); Mon, 10 Apr 2023 10:37:30 -0400 Received: from fudo.makrotopia.org (fudo.makrotopia.org [IPv6:2a07:2ec0:3002::71]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 919B855A1; Mon, 10 Apr 2023 07:37:25 -0700 (PDT) Received: from local by fudo.makrotopia.org with esmtpsa (TLS1.3:TLS_AES_256_GCM_SHA384:256) (Exim 4.96) (envelope-from ) id 1plsdn-0007c2-2F; Mon, 10 Apr 2023 16:37:07 +0200 Date: Mon, 10 Apr 2023 15:37:04 +0100 From: Daniel Golle To: arinc9.unal@gmail.com Cc: Sean Wang , Landen Chao , DENG Qingfang , Andrew Lunn , Florian Fainelli , Vladimir Oltean , "David S. Miller" , Eric Dumazet , Jakub Kicinski , Paolo Abeni , Matthias Brugger , AngeloGioacchino Del Regno , Russell King , =?utf-8?B?QXLEsW7DpyDDnE5BTA==?= , Richard van Schagen , Richard van Schagen , Frank Wunderlich , erkin.bozoglu@xeront.com, netdev@vger.kernel.org, linux-kernel@vger.kernel.org, linux-arm-kernel@lists.infradead.org, linux-mediatek@lists.infradead.org Subject: Re: [RFC PATCH v2 net-next 13/14] net: dsa: mt7530: fix port capabilities for MT7988 Message-ID: References: <20230407134626.47928-1-arinc.unal@arinc9.com> <20230407134626.47928-14-arinc.unal@arinc9.com> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Disposition: inline Content-Transfer-Encoding: 8bit In-Reply-To: <20230407134626.47928-14-arinc.unal@arinc9.com> X-Spam-Status: No, score=0.0 required=5.0 tests=SPF_HELO_NONE,SPF_PASS autolearn=unavailable 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 Fri, Apr 07, 2023 at 04:46:25PM +0300, arinc9.unal@gmail.com wrote: > From: Arınç ÜNAL > > On the switch on the MT7988 SoC, there are only 4 PHYs. That's port 0 to 3. > Set the internal phy cases to '0 ... 3'. > > There's no need to clear the config->supported_interfaces bitmap before > reporting the supported interfaces as all bits in the bitmap will already > be initialized to zero when the phylink_config structure is allocated. > There's no code that would change the bitmap beforehand. Remove it. > > Signed-off-by: Arınç ÜNAL Acked-by: Daniel Golle > --- > drivers/net/dsa/mt7530.c | 4 +--- > 1 file changed, 1 insertion(+), 3 deletions(-) > > diff --git a/drivers/net/dsa/mt7530.c b/drivers/net/dsa/mt7530.c > index 6fbbdcb5987f..903e39b7b772 100644 > --- a/drivers/net/dsa/mt7530.c > +++ b/drivers/net/dsa/mt7530.c > @@ -2545,10 +2545,8 @@ static void mt7531_mac_port_get_caps(struct dsa_switch *ds, int port, > static void mt7988_mac_port_get_caps(struct dsa_switch *ds, int port, > struct phylink_config *config) > { > - phy_interface_zero(config->supported_interfaces); > - > switch (port) { > - case 0 ... 4: /* Internal phy */ > + case 0 ... 3: /* Internal phy */ > __set_bit(PHY_INTERFACE_MODE_INTERNAL, > config->supported_interfaces); > break; > -- > 2.37.2 >