Received: by 2002:ab2:23c8:0:b0:1f2:fdbc:cb93 with SMTP id a8csp18499lqe; Tue, 26 Mar 2024 18:31:29 -0700 (PDT) X-Forwarded-Encrypted: i=3; AJvYcCV+5ZN4n4eMnfxnCjXrdGj5AJ9eOqMVCSqgnLx2keNEaFHKw3SMI1t4GylS+1L4tIJR0D9fNLBGtaUeDQHHXyc+H/wpkiCaMd6z97QQ+Q== X-Google-Smtp-Source: AGHT+IHdp0WNwkJ3esjdIY+WO/IrzJwjM0Wnflm3suGDlhgAXORX20WsVDmA63+Gz0p7/PBRNlTb X-Received: by 2002:a05:6358:9497:b0:17f:8816:9b7 with SMTP id i23-20020a056358949700b0017f881609b7mr2851284rwb.14.1711503089616; Tue, 26 Mar 2024 18:31:29 -0700 (PDT) ARC-Seal: i=2; a=rsa-sha256; t=1711503089; cv=pass; d=google.com; s=arc-20160816; b=Mm3sNfMO2uJiznIQmYnsIMuspxlJtG+UYoIVe0BCxf2dCNWPfjHkHFG0ddRQcYCB6C UncV8RhAXp5kx9WnwRKdeSJnU8E2n2RumTKSerf6PkeFbqHO+n7DViSz7aRabVFF8RQJ Ixwczh++ywcu47M7OQDtl45hlQTitPO8vAA2euBs3nqXiyKz2zKzp+DTbc+soNq/jATi +JKgf+Hr6tjfDcOvwhrB0/pqQnRw7I6bZHGV95NfTrdpoxCbB8LBPHGQwIv9qvKtxniu mxf4i11Xk5BQ4XOs2SFodH+2CfMWQylgS27pwX7nPBE8zqRdsU+lDUPhZ97x2wv+ZqzB 3eIw== ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=feedback-id:content-language:thread-index:content-transfer-encoding :mime-version:list-unsubscribe:list-subscribe:list-id:precedence :message-id:date:subject:in-reply-to:references:cc:to:from; bh=CCieTRg9FyeE+gNlY+J3ouyBgo4Dm7W/muzTUceJbEk=; fh=eOU4NvqV5rd8c5N/WP6ag7BmLPxD6MUXW0uqVVho8Xo=; b=M8R5e91gg2/SdIknk733wpo4Hi6bcaRO0j/0PgZrLotJ3yzAb7Fi8u3YaUYP5E9b+A 86TL8B3Z1bTJnoyuzGbCd7NfFGeiGCu0hWBFwA5Kj0kU8Fcjw1slA1D7fLSLODTcU+nf rP/CKSqevb7Lpd0XUzPAk3LgmJ6UAxJ+4hm3zAv3iXsAzBY/K4olP8trbSVpIgA+yq1q 5puiWndFB3fREWFUEZgS4jszWZPlRbYw3FrXS2EeUTly/KwsHwah+e+EayL+VI7+ebMT 1spQ5JSIt+6lxcoOu42Ppq0uZQOjrZ6uQeCZplZ/icPiQWZOv3CGpAMtAqB2CiwXr5hy 3UrA==; dara=google.com ARC-Authentication-Results: i=2; mx.google.com; arc=pass (i=1 spf=pass spfdomain=net-swift.com); spf=pass (google.com: domain of linux-kernel+bounces-120175-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:45e3:2400::1 as permitted sender) smtp.mailfrom="linux-kernel+bounces-120175-linux.lists.archive=gmail.com@vger.kernel.org" Return-Path: Received: from sv.mirrors.kernel.org (sv.mirrors.kernel.org. [2604:1380:45e3:2400::1]) by mx.google.com with ESMTPS id o187-20020a6341c4000000b005dc50694bb3si10337820pga.718.2024.03.26.18.31.29 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 26 Mar 2024 18:31:29 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel+bounces-120175-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:45e3:2400::1 as permitted sender) client-ip=2604:1380:45e3:2400::1; Authentication-Results: mx.google.com; arc=pass (i=1 spf=pass spfdomain=net-swift.com); spf=pass (google.com: domain of linux-kernel+bounces-120175-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:45e3:2400::1 as permitted sender) smtp.mailfrom="linux-kernel+bounces-120175-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 398EA2A80B8 for ; Wed, 27 Mar 2024 01:31:29 +0000 (UTC) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id 8BA3F1CFBC; Wed, 27 Mar 2024 01:31:21 +0000 (UTC) Received: from smtpbgsg2.qq.com (smtpbgsg2.qq.com [54.254.200.128]) (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 9D70A1CF92; Wed, 27 Mar 2024 01:31:15 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=54.254.200.128 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1711503081; cv=none; b=HX14UsxjK2jnOuBn3Rv4b0/fYhRc/6w2jccIBDN5xCYUPdO5fAUTfaOpWLLshBqvXB7ihmcIwYVT61zqo4ApBi5wPffibl4SgDN/XzZeyTNUJ4jxngQxwgj/nlw+SB1dfNirTWkT/MQuEhOHzKf1KTD9m9iRqmABY+ZYRscaaEY= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1711503081; c=relaxed/simple; bh=PB78qaohyz8M/acpebMaE6FdLWqAdAAntBtk1iJ8u+g=; h=From:To:Cc:References:In-Reply-To:Subject:Date:Message-ID: MIME-Version:Content-Type; b=GDqNEoYpoh0lj1AzZSwo/gIBAT03vJiyDqD5qL7/9HfudFHV6Jw8JQwFlyNkS/N4rDGg+tVj1vpQkv/a8w87DIWqo4eOJrjkFzevcBvqyLO5AqfzFQ49KU1rYlectb8WXdNmTknVPQtR7j3MlDe6W+k4XemzvKbPVD1GmEFk1W0= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dmarc=none (p=none dis=none) header.from=net-swift.com; spf=pass smtp.mailfrom=net-swift.com; arc=none smtp.client-ip=54.254.200.128 Authentication-Results: smtp.subspace.kernel.org; dmarc=none (p=none dis=none) header.from=net-swift.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=net-swift.com X-QQ-mid:Yeas8t1711502976t933t54105 Received: from 73E00E8BC808433CB9DB281092DFBE6B (duanqiangwen@net-swift.com [122.235.142.34]) X-QQ-SSF:00400000000000F0FH4000000000000 From: duanqiangwen@net-swift.com X-BIZMAIL-ID: 293933216363626304 To: "'Jiri Pirko'" Cc: , , , , , , , , , , , References: <20240322080416.470517-1-duanqiangwen@net-swift.com> In-Reply-To: Subject: RE: [PATCH net v5] net: txgbe: fix i2c dev name cannot match clkdev Date: Wed, 27 Mar 2024 09:29:35 +0800 Message-ID: <001201da7fe6$3aa37f10$afea7d30$@net-swift.com> 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="gb2312" Content-Transfer-Encoding: quoted-printable X-Mailer: Microsoft Outlook 16.0 Thread-Index: AQFwLs5rgYGClTpBePjvbYMXpqMxXgKXsSFcsgqwUFA= Content-Language: zh-cn X-QQ-SENDSIZE: 520 Feedback-ID: Yeas:net-swift.com:qybglogicsvrsz:qybglogicsvrsz3a-1 > -----Original Message----- > From: Jiri Pirko > Sent: 2024=C4=EA3=D4=C222=C8=D5 16:12 > To: Duanqiang Wen > Cc: netdev@vger.kernel.org; jiawenwu@trustnetic.com; > mengyuanlou@net-swift.com; davem@davemloft.net; > edumazet@google.com; kuba@kernel.org; pabeni@redhat.com; > maciej.fijalkowski@intel.com; andrew@lunn.ch; > wangxiongfeng2@huawei.com; linux-kernel@vger.kernel.org; > michal.kubiak@intel.com > Subject: Re: [PATCH net v5] net: txgbe: fix i2c dev name cannot match clkdev >=20 > Fri, Mar 22, 2024 at 09:04:16AM CET, duanqiangwen@net-swift.com wrote: > >txgbe clkdev shortened clk_name, so i2c_dev info_name also need to > >shorten. Otherwise, i2c_dev cannot initialize clock. > > > >Change log: > >v4-v5: address comments: > > Jiri Pirko: > > Well, since it is used in txgbe_phy.c, it should be probably > > rather defined locally in txgbe_phy.c. >=20 > Did you read Florian's comment? Please do. >=20 > pw-bot: cr >=20 I replied to Florian:=20 " I want to shorten "i2c_desginware" to "i2c_dw" in txgbe driver, so = other drivers which use "i2c_designware" need another patch to use a define. " He hasn't replied to me for several days, what should I do next? >=20 > >v3->v4: address comments: > > Jakub Kicinski: > > No empty lines between Fixes and Signed-off... please. > >v2->v3: address comments: > > Jiawen Wu: > > Please add the define in txgbe_type.h > > > >Fixes: e30cef001da2 ("net: txgbe: fix clk_name exceed MAX_DEV_ID > >limits") > >Signed-off-by: Duanqiang Wen > >--- > > drivers/net/ethernet/wangxun/txgbe/txgbe_phy.c | 8 +++++--- > > 1 file changed, 5 insertions(+), 3 deletions(-) > > > >diff --git a/drivers/net/ethernet/wangxun/txgbe/txgbe_phy.c > >b/drivers/net/ethernet/wangxun/txgbe/txgbe_phy.c > >index 5b5d5e4310d1..2fa511227eac 100644 > >--- a/drivers/net/ethernet/wangxun/txgbe/txgbe_phy.c > >+++ b/drivers/net/ethernet/wangxun/txgbe/txgbe_phy.c > >@@ -20,6 +20,8 @@ > > #include "txgbe_phy.h" > > #include "txgbe_hw.h" > > > >+#define TXGBE_I2C_CLK_DEV_NAME "i2c_dw" > >+ > > static int txgbe_swnodes_register(struct txgbe *txgbe) { > > struct txgbe_nodes *nodes =3D &txgbe->nodes; @@ -571,8 +573,8 > @@ static > >int txgbe_clock_register(struct txgbe *txgbe) > > char clk_name[32]; > > struct clk *clk; > > > >- snprintf(clk_name, sizeof(clk_name), "i2c_dw.%d", > >- pci_dev_id(pdev)); > >+ snprintf(clk_name, sizeof(clk_name), "%s.%d", > >+ TXGBE_I2C_CLK_DEV_NAME, pci_dev_id(pdev)); > > > > clk =3D clk_register_fixed_rate(NULL, clk_name, NULL, 0, = 156250000); > > if (IS_ERR(clk)) > >@@ -634,7 +636,7 @@ static int txgbe_i2c_register(struct txgbe = *txgbe) > > > > info.parent =3D &pdev->dev; > > info.fwnode =3D software_node_fwnode(txgbe- > >nodes.group[SWNODE_I2C]); > >- info.name =3D "i2c_designware"; > >+ info.name =3D TXGBE_I2C_CLK_DEV_NAME; > > info.id =3D pci_dev_id(pdev); > > > > info.res =3D &DEFINE_RES_IRQ(pdev->irq); > >-- > >2.27.0 > > > > >=20