From: Jakub Kicinski <kuba@kernel.org>
To: Huazhong Tan <tanhuazhong@huawei.com>
Cc: <davem@davemloft.net>, <netdev@vger.kernel.org>,
<linux-kernel@vger.kernel.org>, <salil.mehta@huawei.com>,
<yisen.zhuang@huawei.com>, <linuxarm@huawei.com>,
Yonglong Liu <liuyonglong@huawei.com>
Subject: Re: [PATCH net-next] net: hns3: adds support for reading module eeprom info
Date: Tue, 28 Apr 2020 11:49:10 -0700 [thread overview]
Message-ID: <20200428114910.7cc5182e@kicinski-fedora-pc1c0hjn.dhcp.thefacebook.com> (raw)
In-Reply-To: <1588075105-52158-1-git-send-email-tanhuazhong@huawei.com>
On Tue, 28 Apr 2020 19:58:25 +0800 Huazhong Tan wrote:
> From: Yonglong Liu <liuyonglong@huawei.com>
>
> This patch adds support for reading the optical module eeprom
> info via "ethtool -m".
>
> Signed-off-by: Yonglong Liu <liuyonglong@huawei.com>
> Signed-off-by: Huazhong Tan <tanhuazhong@huawei.com>
> diff --git a/drivers/net/ethernet/hisilicon/hns3/hns3_ethtool.c b/drivers/net/ethernet/hisilicon/hns3/hns3_ethtool.c
> index 4d9c85f..8364e1b 100644
> --- a/drivers/net/ethernet/hisilicon/hns3/hns3_ethtool.c
> +++ b/drivers/net/ethernet/hisilicon/hns3/hns3_ethtool.c
> @@ -12,6 +12,16 @@ struct hns3_stats {
> int stats_offset;
> };
>
> +#define HNS3_MODULE_TYPE_QSFP 0x0C
> +#define HNS3_MODULE_TYPE_QSFP_P 0x0D
> +#define HNS3_MODULE_TYPE_QSFP_28 0x11
> +#define HNS3_MODULE_TYPE_SFP 0x03
Could you use the SFF8024_ID_* defines from sfp.h here as well?
Otherwise looks good to me!
next prev parent reply other threads:[~2020-04-28 18:49 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2020-04-28 11:58 [PATCH net-next] net: hns3: adds support for reading module eeprom info Huazhong Tan
2020-04-28 18:49 ` Jakub Kicinski [this message]
2020-04-29 1:50 ` tanhuazhong
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20200428114910.7cc5182e@kicinski-fedora-pc1c0hjn.dhcp.thefacebook.com \
--to=kuba@kernel.org \
--cc=davem@davemloft.net \
--cc=linux-kernel@vger.kernel.org \
--cc=linuxarm@huawei.com \
--cc=liuyonglong@huawei.com \
--cc=netdev@vger.kernel.org \
--cc=salil.mehta@huawei.com \
--cc=tanhuazhong@huawei.com \
--cc=yisen.zhuang@huawei.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).