Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > linux.kernel > #1734585 > unrolled thread

[PATCH net 0/7] Bug fixes for the HNS3 Ethernet Driver for Hip08 SoC

Started bySalil Mehta <salil.mehta@huawei.com>
First post2017-09-19 03:10 +0200
Last post2017-09-19 16:20 +0200
Articles 4 — 2 participants

Back to article view | Back to linux.kernel


Contents

  [PATCH net 0/7] Bug fixes for the HNS3 Ethernet Driver for Hip08 SoC Salil Mehta <salil.mehta@huawei.com> - 2017-09-19 03:10 +0200
    [PATCH net 3/7] net: hns3: Fix ring and vector map command Salil Mehta <salil.mehta@huawei.com> - 2017-09-19 03:10 +0200
    Re: [PATCH net 0/7] Bug fixes for the HNS3 Ethernet Driver for Hip08  SoC Leon Romanovsky <leon@kernel.org> - 2017-09-19 06:00 +0200
      RE: [PATCH net 0/7] Bug fixes for the HNS3 Ethernet Driver for  Hip08 SoC Salil Mehta <salil.mehta@huawei.com> - 2017-09-19 16:20 +0200

#1734585 — [PATCH net 0/7] Bug fixes for the HNS3 Ethernet Driver for Hip08 SoC

FromSalil Mehta <salil.mehta@huawei.com>
Date2017-09-19 03:10 +0200
Subject[PATCH net 0/7] Bug fixes for the HNS3 Ethernet Driver for Hip08 SoC
Message-ID<urfcZ-5PD-7@gated-at.bofh.it>
This patch set presents some bug fixes for the HNS3 Ethernet driver, identified
during internal testing & stabilization efforts.

This patch series is meant for Linux 4.14 kernel. 

Lipeng (6):
  net: hns3: get phy addr from NCL_config
  net: hns3: fix the command used to unmap ring from vector
  net: hns3: Fix ring and vector map command
  net: hns3: fix a bug of set mac address
  net: hns3: set default vlan id to PF
  net: hns3: Fixes the premature exit of loop when matching clients

Salil Mehta (1):
  net: hns3: fixes the ether address copy with more appropriate API

 drivers/net/ethernet/hisilicon/hns3/hnae3.c        | 43 +++++-----------------
 .../net/ethernet/hisilicon/hns3/hns3pf/hclge_cmd.h |  8 +++-
 .../ethernet/hisilicon/hns3/hns3pf/hclge_main.c    | 20 ++++++++--
 .../net/ethernet/hisilicon/hns3/hns3pf/hns3_enet.c |  7 ++--
 4 files changed, 35 insertions(+), 43 deletions(-)

-- 
2.11.0

[toc] | [next] | [standalone]


#1734586 — [PATCH net 3/7] net: hns3: Fix ring and vector map command

FromSalil Mehta <salil.mehta@huawei.com>
Date2017-09-19 03:10 +0200
Subject[PATCH net 3/7] net: hns3: Fix ring and vector map command
Message-ID<urfd0-5PD-21@gated-at.bofh.it>
In reply to#1734585
From: Lipeng <lipeng321@huawei.com>

This patch add INT_GL and VF id to vector configure when bind ring
with vector. INT_GL means Interrupt Gap Limiting. Vector id starts
from 0 in each VF, so the bind command must specify VF id.

Signed-off-by: Lipeng <lipeng321@huawei.com>
Signed-off-by: Mingguang Qu <qumingguang@huawei.com>
Signed-off-by: Salil Mehta <salil.mehta@huawei.com>
---
 drivers/net/ethernet/hisilicon/hns3/hns3pf/hclge_cmd.h  | 8 ++++++--
 drivers/net/ethernet/hisilicon/hns3/hns3pf/hclge_main.c | 8 ++++++++
 2 files changed, 14 insertions(+), 2 deletions(-)

diff --git a/drivers/net/ethernet/hisilicon/hns3/hns3pf/hclge_cmd.h b/drivers/net/ethernet/hisilicon/hns3/hns3pf/hclge_cmd.h
index 91ae0135ee50..c2b613b40509 100644
--- a/drivers/net/ethernet/hisilicon/hns3/hns3pf/hclge_cmd.h
+++ b/drivers/net/ethernet/hisilicon/hns3/hns3pf/hclge_cmd.h
@@ -238,7 +238,7 @@ struct hclge_tqp_map {
 	u8 rsv[18];
 };
 
-#define HCLGE_VECTOR_ELEMENTS_PER_CMD	11
+#define HCLGE_VECTOR_ELEMENTS_PER_CMD	10
 
 enum hclge_int_type {
 	HCLGE_INT_TX,
@@ -252,8 +252,12 @@ struct hclge_ctrl_vector_chain {
 #define HCLGE_INT_TYPE_S	0
 #define HCLGE_INT_TYPE_M	0x3
 #define HCLGE_TQP_ID_S		2
-#define HCLGE_TQP_ID_M		(0x3fff << HCLGE_TQP_ID_S)
+#define HCLGE_TQP_ID_M		(0x7ff << HCLGE_TQP_ID_S)
+#define HCLGE_INT_GL_IDX_S	13
+#define HCLGE_INT_GL_IDX_M	(0x3 << HCLGE_INT_GL_IDX_S)
 	__le16 tqp_type_and_id[HCLGE_VECTOR_ELEMENTS_PER_CMD];
+	u8 vfid;
+	u8 rsv;
 };
 
 #define HCLGE_TC_NUM		8
diff --git a/drivers/net/ethernet/hisilicon/hns3/hns3pf/hclge_main.c b/drivers/net/ethernet/hisilicon/hns3/hns3pf/hclge_main.c
index e324bc6e9f4f..eafd9c678162 100644
--- a/drivers/net/ethernet/hisilicon/hns3/hns3pf/hclge_main.c
+++ b/drivers/net/ethernet/hisilicon/hns3/hns3pf/hclge_main.c
@@ -2680,7 +2680,11 @@ int hclge_map_vport_ring_to_vector(struct hclge_vport *vport, int vector_id,
 			       hnae_get_bit(node->flag, HNAE3_RING_TYPE_B));
 		hnae_set_field(req->tqp_type_and_id[i], HCLGE_TQP_ID_M,
 			       HCLGE_TQP_ID_S,	node->tqp_index);
+		hnae_set_field(req->tqp_type_and_id[i], HCLGE_INT_GL_IDX_M,
+			       HCLGE_INT_GL_IDX_S,
+			       hnae_get_bit(node->flag, HNAE3_RING_TYPE_B));
 		req->tqp_type_and_id[i] = cpu_to_le16(req->tqp_type_and_id[i]);
+		req->vfid = vport->vport_id;
 
 		if (++i >= HCLGE_VECTOR_ELEMENTS_PER_CMD) {
 			req->int_cause_num = HCLGE_VECTOR_ELEMENTS_PER_CMD;
@@ -2764,8 +2768,12 @@ static int hclge_unmap_ring_from_vector(
 			       hnae_get_bit(node->flag, HNAE3_RING_TYPE_B));
 		hnae_set_field(req->tqp_type_and_id[i], HCLGE_TQP_ID_M,
 			       HCLGE_TQP_ID_S,	node->tqp_index);
+		hnae_set_field(req->tqp_type_and_id[i], HCLGE_INT_GL_IDX_M,
+			       HCLGE_INT_GL_IDX_S,
+			       hnae_get_bit(node->flag, HNAE3_RING_TYPE_B));
 
 		req->tqp_type_and_id[i] = cpu_to_le16(req->tqp_type_and_id[i]);
+		req->vfid = vport->vport_id;
 
 		if (++i >= HCLGE_VECTOR_ELEMENTS_PER_CMD) {
 			req->int_cause_num = HCLGE_VECTOR_ELEMENTS_PER_CMD;
-- 
2.11.0

[toc] | [prev] | [next] | [standalone]


#1734637 — Re: [PATCH net 0/7] Bug fixes for the HNS3 Ethernet Driver for Hip08 SoC

FromLeon Romanovsky <leon@kernel.org>
Date2017-09-19 06:00 +0200
SubjectRe: [PATCH net 0/7] Bug fixes for the HNS3 Ethernet Driver for Hip08 SoC
Message-ID<urhRv-7jo-1@gated-at.bofh.it>
In reply to#1734585

[Multipart message — attachments visible in raw view] — view raw

On Tue, Sep 19, 2017 at 02:06:21AM +0100, Salil Mehta wrote:
> This patch set presents some bug fixes for the HNS3 Ethernet driver, identified
> during internal testing & stabilization efforts.
>
> This patch series is meant for Linux 4.14 kernel.
>
> Lipeng (6):
>   net: hns3: get phy addr from NCL_config
>   net: hns3: fix the command used to unmap ring from vector
>   net: hns3: Fix ring and vector map command
>   net: hns3: fix a bug of set mac address
>   net: hns3: set default vlan id to PF
>   net: hns3: Fixes the premature exit of loop when matching clients
>
> Salil Mehta (1):
>   net: hns3: fixes the ether address copy with more appropriate API

1. The fixes patches should have Fixes line and not all of them have
(I didn't look all patches).
2. Please decide on one style: fixes vs. Fixes, fix vs. Fix in the titles
3. Subject should be descriptive and usable, I don't know if it applies
to the "fix a bug of set mac address" patch.

Thanks

>
>  drivers/net/ethernet/hisilicon/hns3/hnae3.c        | 43 +++++-----------------
>  .../net/ethernet/hisilicon/hns3/hns3pf/hclge_cmd.h |  8 +++-
>  .../ethernet/hisilicon/hns3/hns3pf/hclge_main.c    | 20 ++++++++--
>  .../net/ethernet/hisilicon/hns3/hns3pf/hns3_enet.c |  7 ++--
>  4 files changed, 35 insertions(+), 43 deletions(-)
>
> --
> 2.11.0
>
>

[toc] | [prev] | [next] | [standalone]


#1734943 — RE: [PATCH net 0/7] Bug fixes for the HNS3 Ethernet Driver for Hip08 SoC

FromSalil Mehta <salil.mehta@huawei.com>
Date2017-09-19 16:20 +0200
SubjectRE: [PATCH net 0/7] Bug fixes for the HNS3 Ethernet Driver for Hip08 SoC
Message-ID<urrxv-6uO-3@gated-at.bofh.it>
In reply to#1734637
Hi Leon,

> -----Original Message-----
> From: Leon Romanovsky [mailto:leon@kernel.org]
> Sent: Tuesday, September 19, 2017 4:59 AM
> To: Salil Mehta
> Cc: davem@davemloft.net; Zhuangyuzeng (Yisen); lipeng (Y);
> mehta.salil.lnk@gmail.com; netdev@vger.kernel.org; linux-
> kernel@vger.kernel.org; linux-rdma@vger.kernel.org; Linuxarm
> Subject: Re: [PATCH net 0/7] Bug fixes for the HNS3 Ethernet Driver for
> Hip08 SoC
> 
> On Tue, Sep 19, 2017 at 02:06:21AM +0100, Salil Mehta wrote:
> > This patch set presents some bug fixes for the HNS3 Ethernet driver,
> identified
> > during internal testing & stabilization efforts.
> >
> > This patch series is meant for Linux 4.14 kernel.
> >
> > Lipeng (6):
> >   net: hns3: get phy addr from NCL_config
> >   net: hns3: fix the command used to unmap ring from vector
> >   net: hns3: Fix ring and vector map command
> >   net: hns3: fix a bug of set mac address
> >   net: hns3: set default vlan id to PF
> >   net: hns3: Fixes the premature exit of loop when matching clients
> >
> > Salil Mehta (1):
> >   net: hns3: fixes the ether address copy with more appropriate API
> 
> 1. The fixes patches should have Fixes line and not all of them have
> (I didn't look all patches).
> 2. Please decide on one style: fixes vs. Fixes, fix vs. Fix in the
> titles
> 3. Subject should be descriptive and usable, I don't know if it applies
> to the "fix a bug of set mac address" patch.
Yes, missed these. Will fix them. Thanks!

Salil
> 
> Thanks
> 
> >
> >  drivers/net/ethernet/hisilicon/hns3/hnae3.c        | 43 +++++-------
> ----------
> >  .../net/ethernet/hisilicon/hns3/hns3pf/hclge_cmd.h |  8 +++-
> >  .../ethernet/hisilicon/hns3/hns3pf/hclge_main.c    | 20 ++++++++--
> >  .../net/ethernet/hisilicon/hns3/hns3pf/hns3_enet.c |  7 ++--
> >  4 files changed, 35 insertions(+), 43 deletions(-)
> >
> > --
> > 2.11.0
> >
> >

[toc] | [prev] | [standalone]


Back to top | Article view | linux.kernel


csiph-web