[PATCH net-next 4/5] net: hns3: add support for ETHTOOL_GRXFH

2017-10-10 Thread Lipeng
This patch add support for ethtool's ETHTOOL_GRXFH in hns3_get_rxnfc(). Signed-off-by: Lipeng <lipeng...@huawei.com> --- drivers/net/ethernet/hisilicon/hns3/hnae3.h| 2 + .../ethernet/hisilicon/hns3/hns3pf/hclge_main.c| 64 ++ .../ethernet/hisilicon/hns3/

[PATCH net-next 3/5] net: hns3: add support for set_rxnfc

2017-10-10 Thread Lipeng
This patch supports the ethtool's set_rxnfc(). Signed-off-by: Lipeng <lipeng...@huawei.com> --- drivers/net/ethernet/hisilicon/hns3/hnae3.h| 2 + .../net/ethernet/hisilicon/hns3/hns3pf/hclge_cmd.c | 9 ++ .../net/ethernet/hisilicon/hns3/hns3pf/hclge_cmd.h | 1 + .../ethernet/his

[PATCH net-next 5/5] net: hns3: fix the ring count for ETHTOOL_GRXRINGS

2017-10-10 Thread Lipeng
This patch fix the ring count for ETHTOOL_GRXRINGS. Ring count not TC size should be return for command "ethtool -n ethx". Signed-off-by: Lipeng <lipeng...@huawei.com> --- drivers/net/ethernet/hisilicon/hns3/hns3pf/hns3_ethtool.c | 2 +- 1 file changed, 1 insertion(+), 1 deletio

[PATCH net-next 2/5] net: hns3: add support for set_ringparam

2017-10-10 Thread Lipeng
This patch supports the ethtool's set_ringparam(). Signed-off-by: Lipeng <lipeng...@huawei.com> --- .../net/ethernet/hisilicon/hns3/hns3pf/hns3_enet.c | 4 +- .../net/ethernet/hisilicon/hns3/hns3pf/hns3_enet.h | 4 ++ .../ethernet/hisilicon/hns3/hns3pf/hns3_ethtool.c

[PATCH net-next 0/5] Support set_ringparam and {set|get}_rxnfc ethtool commands

2017-10-10 Thread Lipeng
1, Patch [1/5,2/5] add support for ethtool ops set_ringparam (ethtool -G) and fix related bug. 2, Patch [3/5,4/5, 5/5] add support for ethtool ops set_rxnfc/get_rxnfc (-n/-N) and fix related bug. Lipeng (5): net: hns3: fixes the ring index in hns3_fini_ring net: hns3: add support

[PATCH net-next 1/5] net: hns3: fixes the ring index in hns3_fini_ring

2017-10-10 Thread Lipeng
This patch fixes the ring index in hns3_fini_ring. Signed-off-by: Lipeng <lipeng...@huawei.com> --- drivers/net/ethernet/hisilicon/hns3/hns3pf/hns3_enet.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/net/ethernet/hisilicon/hns3/hns3pf/hns3_enet.c b/drive

[PATCH net-next 6/8] net: hns3: fix bug of reuse command description

2017-08-31 Thread Lipeng
When reuse command description, the in/out bit and W/R bit of the command flag should be both updated. The old code did not update in/out bit, this patch fix it. Signed-off-by: Mingguang Qu <quminggu...@huawei.com> Signed-off-by: Lipeng <lipeng...@huawei.com> --- drivers/net/ethern

[PATCH net-next 8/8] net: hns3: reimplemmentation of pkt buffer allocation

2017-08-31 Thread Lipeng
Current implemmentation of buffer allocation in SSU do not meet the requirement to do the buffer reallocation. This patch fixs that in order to support buffer reallocation between Mac and PFC pause. Signed-off-by: Yunsheng Lin <linyunsh...@huawei.com> Signed-off-by: Lipeng <lipeng...@h

[PATCH net-next 0/8] Bug fixes & Code improvements in HNS driver

2017-08-31 Thread Lipeng
This patch-set introduces some bug fixes and code improvements. These have been identified during internal review or testing of the driver by internal Hisilicon teams. Lipeng (8): net: hns3: add check when initialize net: hns3: update ring and vector map command net: hns3: set default mac

[PATCH net-next 7/8] net: hns3: add vlan filter config of Ports

2017-08-31 Thread Lipeng
Config the self_define vlan_type as TPID(0x8100) for vlan identification. When normal port initialize vlan configure, set default vlan id as 0. Signed-off-by: Mingguang Qu <quminggu...@huawei.com> Signed-off-by: Lipeng <lipeng...@huawei.com> --- drivers/net/ethernet/hisilicon

[PATCH net-next 3/8] net: hns3: set default mac vlan mask

2017-08-31 Thread Lipeng
<quminggu...@huawei.com> Signed-off-by: Lipeng <lipeng...@huawei.com> --- .../net/ethernet/hisilicon/hns3/hns3pf/hclge_cmd.h | 9 + .../ethernet/hisilicon/hns3/hns3pf/hclge_main.c| 43 +- 2 files changed, 51 insertions(+), 1 deletion(-) diff --git a/drivers/

[PATCH net-next 2/8] net: hns3: update ring and vector map command

2017-08-31 Thread Lipeng
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 <lipeng...@huawei.com> Signed-off-by: Mingguang Qu <quminggu...@huawei.com> ---

[PATCH net-next 4/8] net: hns3: set default vlan id to PF

2017-08-31 Thread Lipeng
When there is no vlan id in the packets, hardware will treat the vlan id as 0 and look for the mac_vlan table. This patch set the default vlan id of PF as 0. Signed-off-by: Mingguang Qu <quminggu...@huawei.com> Signed-off-by: Lipeng <lipeng...@huawei.com> --- drivers/net/ethernet/hi

[PATCH net-next 5/8] net: hns3: set the VLAN Ethernet type to HW

2017-08-31 Thread Lipeng
This patch set the VLAN Ethetnet type(0x8100) to HW. With this configure, HW can identify vlan packets. Signed-off-by: Mingguang Qu <quminggu...@huawei.com> Signed-off-by: Lipeng <lipeng...@huawei.com> --- .../net/ethernet/hisilicon/hns3/hns3pf/hclge_cmd.h | 13 + .../ethernet/hi

[PATCH net-next 1/8] net: hns3: add check when initialize

2017-08-31 Thread Lipeng
if device do not support DCB. Signed-off-by: Lipeng <lipeng...@huawei.com> --- drivers/net/ethernet/hisilicon/hns3/hnae3.h| 1 + .../ethernet/hisilicon/hns3/hns3pf/hclge_main.c| 41 -- 2 files changed, 31 insertions(+), 11 deletions(-) diff --git a/drivers/net/et

[PATCH net-next 1/7] net: hns3: fix a bug when alloc new buffer

2017-10-23 Thread Lipeng
When alloce new buffer to HW, should unmap the old buffer first. This old code map the old buffer but not unmap the old buffer, this patch fixes it. Fixes: 76ad4f0 (net: hns3: Add support of HNS3 Ethernet Driver for hip08 SoC) Signed-off-by: Lipeng <lipeng...@huawei.com> --- drive

[PATCH net-next 2/7] net: hns3: fix the bug when map buffer fail

2017-10-23 Thread Lipeng
) Signed-off-by: Lipeng <lipeng...@huawei.com> --- drivers/net/ethernet/hisilicon/hns3/hns3pf/hns3_enet.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/net/ethernet/hisilicon/hns3/hns3pf/hns3_enet.c b/drivers/net/ethernet/hisilicon/hns3/hns3pf/hns3_enet.c

[PATCH net-next 4/7] net: hns3: get vf count by pci_sriov_get_totalvfs

2017-10-23 Thread Lipeng
This patch gets vf count by standard function pci_sriov_get_totalvfs, instead of info from NIC HW. Signed-off-by: Lipeng <lipeng...@huawei.com> --- drivers/net/ethernet/hisilicon/hns3/hns3pf/hclge_main.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/drivers/net/et

[PATCH net-next 6/7] net: hns3: remove redundant memset when alloc buffer

2017-10-23 Thread Lipeng
-off-by: Lipeng <lipeng...@huawei.com> --- drivers/net/ethernet/hisilicon/hns3/hns3pf/hns3_enet.c | 2 -- 1 file changed, 2 deletions(-) diff --git a/drivers/net/ethernet/hisilicon/hns3/hns3pf/hns3_enet.c b/drivers/net/ethernet/hisilicon/hns3/hns3pf/hns3_enet.c index 14de0f7..06af3c8

[PATCH net-next 7/7] net: hns3: fix a bug about hns3_clean_tx_ring

2017-10-23 Thread Lipeng
l decrease when clean a buffer. If there is no valid BD in TX ring, return 0 for hns3_clean_tx_ring will cause napi poll again and never complete the napi poll. This patch fixes the bug. Fixes: 76ad4f0 (net: hns3: Add support of HNS3 Ethernet Driver for hip08 SoC) Signed-off-by: Lipeng <lipeng.

[PATCH net-next 5/7] net: hns3: fix the TX/RX ring.queue_index in hns3_ring_get_cfg

2017-10-23 Thread Lipeng
The interface hns3_ring_get_cfg only update TX ring queue_index, but do not update RX ring queue_index. This patch fixes it. Fixes: 76ad4f0 (net: hns3: Add support of HNS3 Ethernet Driver for hip08 SoC) Signed-off-by: Lipeng <lipeng...@huawei.com> --- drivers/net/ethernet/hisilicon/hns3/

[PATCH net-next 3/7] net: hns3: fix the ops check in hns3_get_rxnfc

2017-10-23 Thread Lipeng
s3_get_rxnfc. Signed-off-by: Lipeng <lipeng...@huawei.com> --- drivers/net/ethernet/hisilicon/hns3/hns3pf/hns3_ethtool.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/net/ethernet/hisilicon/hns3/hns3pf/hns3_ethtool.c b/drivers/net/ethernet/hisilicon/hns3/hns3pf/hn

[PATCH net-next 0/7] net: hns3: bug fixes & code improvements

2017-10-23 Thread Lipeng
This patchset introduces various HNS3 bug fixes, optimizations and code improvements. Lipeng (7): net: hns3: fix a bug when alloc new buffer net: hns3: fix the bug when map buffer fail net: hns3: fix the ops check in hns3_get_rxnfc net: hns3: get vf count by pci_sriov_get_totalvfs net

[PATCH net-next 2/4] net: hns3: add nic_client check when initialize roce base information

2017-10-24 Thread Lipeng
gned-off-by: Lipeng <lipeng...@huawei.com> --- drivers/net/ethernet/hisilicon/hns3/hns3pf/hclge_main.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/net/ethernet/hisilicon/hns3/hns3pf/hclge_main.c b/drivers/net/ethernet/hisilicon/hns3/hns3pf/hclge_main.c ind

[PATCH net-next 3/4] net: hns3: fix a bug in hclge_uninit_client_instance

2017-10-24 Thread Lipeng
mmod hns3.ko after rmmod hns-roce-hw-v2.ko and hns-roce.ko. This patch fixes the issue. Fixes: 46a3df9 (net: hns3: Add HNS3 Acceleration Engine & Compatibility Layer Support) Signed-off-by: Lipeng <lipeng...@huawei.com> --- drivers/net/ethernet/hisilicon/hns3/hns3pf/hclge_main.c |

[PATCH net-next 4/4] net: hns3: fix the bug when reuse command description in hclge_add_mac_vlan_tbl

2017-10-24 Thread Lipeng
. [ 135.270983] hns3 :7d:00.0: add mac addr failed for cmd_send, ret =-5. This patch fixes the bug. Fixes: 46a3df9 (net: hns3: Add HNS3 Acceleration Engine & Compatibility Layer Support) Signed-off-by: Lipeng <lipeng...@huawei.com> --- drivers/net/ethernet/hisilicon/hns3/hns3pf/hclge_

[PATCH net-next 0/4] net: hns3: fix some bugs for HNS3 driver

2017-10-24 Thread Lipeng
This patchset fixes some bugs reported by Hisilicon test team. Lipeng (4): net: hns3: fix the bug of hns3_set_txbd_baseinfo net: hns3: add nic_client check when initialize roce base information net: hns3: fix a bug in hclge_uninit_client_instance net: hns3: fix the bug when reuse command

[PATCH net-next 1/4] net: hns3: fix the bug of hns3_set_txbd_baseinfo

2017-10-24 Thread Lipeng
conmunicate with its own PF need forwarding table. This patch sets SC bits of TX BD 0 and use forwarding table. Fixes: 76ad4f0 (net: hns3: Add support of HNS3 Ethernet Driver for hip08 SoC) Signed-off-by: Lipeng <lipeng...@huawei.com> --- drivers/net/ethernet/hisilicon/hns3/hns3pf/hns3_enet.c | 2

[PATCH net-next 16/17] net: hns3: Increase the default depth of bucket for TM shaper

2017-12-18 Thread Lipeng
com> Signed-off-by: Lipeng <lipeng...@huawei.com> --- drivers/net/ethernet/hisilicon/hns3/hns3pf/hclge_tm.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/drivers/net/ethernet/hisilicon/hns3/hns3pf/hclge_tm.c b/drivers/net/ethernet/hisilicon/hns3/hns3pf/hclge_tm.c i

[PATCH net-next 13/17] net: hns3: add support to update flow control settings after autoneg

2017-12-18 Thread Lipeng
Liang <liangfuy...@huawei.com> Signed-off-by: Lipeng <lipeng...@huawei.com> --- .../ethernet/hisilicon/hns3/hns3pf/hclge_main.c| 36 ++ .../ethernet/hisilicon/hns3/hns3pf/hclge_main.h| 1 + .../ethernet/hisilicon/hns3/hns3pf/hclge_mdio.c| 4 +++ 3 files

[PATCH net-next 15/17] net: hns3: add support for querying advertised pause frame by ethtool ethx

2017-12-18 Thread Lipeng
This patch adds support for querying advertised pause frame by using ethtool command(ethtool ethx). Fixes: 496d03e960ae (net: hns3: Add Ethtool support to HNS3 driver) Signed-off-by: Fuyun Liang <liangfuy...@huawei.com> Signed-off-by: Lipeng <lipeng...@huawei.com> --- drivers/

[PATCH net-next 01/17] net: hns3: add support to query tqps number

2017-12-18 Thread Lipeng
This patch add the support to query tqps number for PF driver by using ehtool -l command. Signed-off-by: qumingguang <quminggu...@huawei.com> Signed-off-by: Lipeng <lipeng...@huawei.com> --- drivers/net/ethernet/hisilicon/hns3/hnae3.h | 2 ++ drivers/net/ethernet/hi

[PATCH net-next 11/17] net: hns3: fix for getting auto-negotiation state in hclge_get_autoneg

2017-12-18 Thread Lipeng
state in hclge_get_autoneg(). Fixes: 46a3df9f9718 (net: hns3: Add HNS3 Acceleration Engine & Compatibility Layer Support) Signed-off-by: Fuyun Liang <liangfuy...@huawei.com> Signed-off-by: Lipeng <lipeng...@huawei.com> --- drivers/net/ethernet/hisilicon/hns3/hns3pf/hclge_main.c | 4 1 file

[PATCH net-next 05/17] net: hns3: Get rss_size_max from configuration but not hardcode

2017-12-18 Thread Lipeng
From: qumingguang <quminggu...@huawei.com> Add configuration for rss_size_max in hdev but not hardcode it. Signed-off-by: qumingguang <quminggu...@huawei.com> Signed-off-by: Lipeng <lipeng...@huawei.com> --- drivers/net/ethernet/hisilicon/hns3/hns3pf/hclge_cmd.h | 2 ++ dr

[PATCH net-next 17/17] net: hns3: change TM sched mode to TC-based mode when SRIOV enabled

2017-12-18 Thread Lipeng
TC-based sched mode supports SRIOV enabled and SRIOV disabled. This patch change the TM sched mode to TC-based mode in initialization process. Fixes: cc9bb43 (net: hns3: Add tc-based TM support for sriov enabled port) Signed-off-by: Lipeng <lipeng...@huawei.com> --- drivers/net/et

[PATCH net-next 12/17] net: hns3: add support for set_pauseparam

2017-12-18 Thread Lipeng
This patch adds set_pauseparam support for ethtool cmd. Signed-off-by: Fuyun Liang <liangfuy...@huawei.com> Signed-off-by: Lipeng <lipeng...@huawei.com> --- drivers/net/ethernet/hisilicon/hns3/hns3_ethtool.c | 13 .../ethernet/hisilicon/hns3/hns3pf/hclge_ma

[PATCH net-next 02/17] net: hns3: add support to modify tqps number

2017-12-18 Thread Lipeng
This patch add the support to change tqps number for PF driver by using ehtool -L command. Signed-off-by: qumingguang <quminggu...@huawei.com> Signed-off-by: Lipeng <lipeng...@huawei.com> --- drivers/net/ethernet/hisilicon/hns3/hnae3.h| 3 + drivers/net/ethernet/hi

[PATCH net-next 07/17] net: hns3: Add vlan offload config command

2017-12-18 Thread Lipeng
This patch adds vlan offload config commands, initializes the rules of tx/rx vlan tag handle for hw. Signed-off-by: Shenjian <shenjia...@huawei.com> Signed-off-by: Lipeng <lipeng...@huawei.com> --- .../net/ethernet/hisilicon/hns3/hns3pf/hclge_cmd.h | 45 ++ .../ethernet/hi

[PATCH net-next 06/17] net: hns3: Add a mask initialization for mac_vlan table

2017-12-18 Thread Lipeng
This patch sets vlan masked, in order to avoid the received packets being filtered. Signed-off-by: Shenjian <shenjia...@huawei.com> Signed-off-by: Lipeng <lipeng...@huawei.com> --- .../net/ethernet/hisilicon/hns3/hns3pf/hclge_cmd.h | 10 ++ .../ethernet/hisilicon/hns3/hns3pf/

[PATCH net-next 00/17] add some features and fix some bugs for HNS3 driver

2017-12-18 Thread Lipeng
hns3: cleanup mac auto-negotiation state query net: hns3: fix for getting auto-negotiation state in hclge_get_autoneg net: hns3: add Asym Pause support to phy default features Lipeng (13): net: hns3: add support to query tqps number net: hns3: add support to modify tqps number net:

[PATCH net-next 04/17] net: hns3: Free the ring_data structrue when change tqps

2017-12-18 Thread Lipeng
This patch fix a memory leak problems in change tqps process, the function hns3_uninit_all_ring and hns3_init_all_ring may be called many times. Signed-off-by: qumingguang <quminggu...@huawei.com> Signed-off-by: Lipeng <lipeng...@huawei.com> --- drivers/net/ethernet/hisilicon/hns3

[PATCH net-next 08/17] net: hns3: Add ethtool related offload command

2017-12-18 Thread Lipeng
This patch adds offload command related to "ethtool -K". Signed-off-by: Shenjian <shenjia...@huawei.com> Signed-off-by: Lipeng <lipeng...@huawei.com> --- drivers/net/ethernet/hisilicon/hns3/hnae3.h | 3 +++ drivers/net/ethernet/hisilicon/hns3/hn

[PATCH net-next 03/17] net: hns3: change the returned tqp number by ethtool -x

2017-12-18 Thread Lipeng
This patch modify the return data of get_rxnfc, it will return the current handle's rss_size but not the total tqp number. because the tc_size has been change to the log2 of roundup power of two of rss_size. Signed-off-by: qumingguang <quminggu...@huawei.com> Signed-off-by: Lipeng &

[PATCH net-next 14/17] net: hns3: add Asym Pause support to phy default features

2017-12-18 Thread Lipeng
se can not be advertised when the phy negotiates flow control. Fixes: c4fb2cdf575d (net: hns3: fix a bug for phy supported feature initialization) Signed-off-by: Fuyun Liang <liangfuy...@huawei.com> Signed-off-by: Lipeng <lipeng...@huawei.com> --- drivers/net/ethernet/hisilicon/hns3/h

[PATCH net-next 10/17] net: hns3: cleanup mac auto-negotiation state query

2017-12-18 Thread Lipeng
rdware. This patch removes the mac auto-negotiation state query. Signed-off-by: Fuyun Liang <liangfuy...@huawei.com> Signed-off-by: Lipeng <lipeng...@huawei.com> --- .../ethernet/hisilicon/hns3/hns3pf/hclge_main.c| 24 -- 1 file changed, 24 deletions(-) diff --git a/dr

[PATCH net-next 09/17] net: hns3: Add handling vlan tag offload in bd

2017-12-18 Thread Lipeng
This patch deals with the vlan tag information between sk_buff and rx/tx bd. Signed-off-by: Shenjian <shenjia...@huawei.com> Signed-off-by: Lipeng <lipeng...@huawei.com> --- drivers/net/ethernet/hisilicon/hns3/hns3_enet.c | 83 +++-- 1 file changed, 78 inse

[PATCH V2 net-next 16/17] net: hns3: Increase the default depth of bucket for TM shaper

2017-12-18 Thread Lipeng
com> Signed-off-by: Lipeng <lipeng...@huawei.com> --- drivers/net/ethernet/hisilicon/hns3/hns3pf/hclge_tm.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/drivers/net/ethernet/hisilicon/hns3/hns3pf/hclge_tm.c b/drivers/net/ethernet/hisilicon/hns3/hns3pf/hclge_tm.c i

[PATCH V2 net-next 08/17] net: hns3: Add ethtool related offload command

2017-12-18 Thread Lipeng
This patch adds offload command related to "ethtool -K". Signed-off-by: Shenjian <shenjia...@huawei.com> Signed-off-by: Lipeng <lipeng...@huawei.com> --- drivers/net/ethernet/hisilicon/hns3/hnae3.h | 3 +++ drivers/net/ethernet/hisilicon/hns3/hn

[PATCH V2 net-next 09/17] net: hns3: Add handling vlan tag offload in bd

2017-12-18 Thread Lipeng
This patch deals with the vlan tag information between sk_buff and rx/tx bd. Signed-off-by: Shenjian <shenjia...@huawei.com> Signed-off-by: Lipeng <lipeng...@huawei.com> --- drivers/net/ethernet/hisilicon/hns3/hns3_enet.c | 83 +++-- 1 file changed, 78 inse

[PATCH V2 net-next 15/17] net: hns3: add support for querying advertised pause frame by ethtool ethx

2017-12-18 Thread Lipeng
This patch adds support for querying advertised pause frame by using ethtool command(ethtool ethx). Fixes: 496d03e960ae ("net: hns3: Add Ethtool support to HNS3 driver") Signed-off-by: Fuyun Liang <liangfuy...@huawei.com> Signed-off-by: Lipeng <lipeng...@huawei.com> ---

[PATCH V2 net-next 03/17] net: hns3: change the returned tqp number by ethtool -x

2017-12-18 Thread Lipeng
This patch modifies the return data of get_rxnfc, it will return the current handle's rss_size but not the total tqp number. because the tc_size has been change to the log2 of roundup power of two of rss_size. Signed-off-by: qumingguang <quminggu...@huawei.com> Signed-off-by: Lipeng &

[PATCH V2 net-next 05/17] net: hns3: Get rss_size_max from configuration but not hardcode

2017-12-18 Thread Lipeng
From: qumingguang <quminggu...@huawei.com> Add configuration for rss_size_max in hdev but not hardcode it. Signed-off-by: qumingguang <quminggu...@huawei.com> Signed-off-by: Lipeng <lipeng...@huawei.com> --- drivers/net/ethernet/hisilicon/hns3/hns3pf/hclge_cmd.h | 2 ++ dr

[PATCH V2 net-next 00/17] add some features and fix some bugs for HNS3 driver

2017-12-18 Thread Lipeng
; V2: 1, fix the comments from Sergei Shtylyov. --- Fuyun Liang (3): net: hns3: cleanup mac auto-negotiation state query net: hns3: fix for getting auto-negotiation state in hclge_get_autoneg net: hns3: add Asym Pause support to phy default features Lipeng (13): net: hns3: add support t

[PATCH V2 net-next 13/17] net: hns3: add support to update flow control settings after autoneg

2017-12-18 Thread Lipeng
Liang <liangfuy...@huawei.com> Signed-off-by: Lipeng <lipeng...@huawei.com> --- .../ethernet/hisilicon/hns3/hns3pf/hclge_main.c| 36 ++ .../ethernet/hisilicon/hns3/hns3pf/hclge_main.h| 1 + .../ethernet/hisilicon/hns3/hns3pf/hclge_mdio.c| 4 +++ 3 files

[PATCH V2 net-next 07/17] net: hns3: Add vlan offload config command

2017-12-18 Thread Lipeng
This patch adds vlan offload config commands, initializes the rules of tx/rx vlan tag handle for hw. Signed-off-by: Shenjian <shenjia...@huawei.com> Signed-off-by: Lipeng <lipeng...@huawei.com> --- .../net/ethernet/hisilicon/hns3/hns3pf/hclge_cmd.h | 45 ++ .../ethernet/hi

[PATCH V2 net-next 11/17] net: hns3: fix for getting auto-negotiation state in hclge_get_autoneg

2017-12-18 Thread Lipeng
state in hclge_get_autoneg(). Fixes: 46a3df9f9718 ("net: hns3: Add HNS3 Acceleration Engine & Compatibility Layer Support") Signed-off-by: Fuyun Liang <liangfuy...@huawei.com> Signed-off-by: Lipeng <lipeng...@huawei.com> --- drivers/net/ethernet/hisilicon/hns3/hns3pf/hclge_main.c | 4 ++

[PATCH V2 net-next 12/17] net: hns3: add support for set_pauseparam

2017-12-18 Thread Lipeng
This patch adds set_pauseparam support for ethtool cmd. Signed-off-by: Fuyun Liang <liangfuy...@huawei.com> Signed-off-by: Lipeng <lipeng...@huawei.com> --- drivers/net/ethernet/hisilicon/hns3/hns3_ethtool.c | 13 .../ethernet/hisilicon/hns3/hns3pf/hclge_ma

[PATCH V2 net-next 02/17] net: hns3: add support to modify tqps number

2017-12-18 Thread Lipeng
This patch add the support to change tqps number for PF driver by using ehtool -L command. Signed-off-by: qumingguang <quminggu...@huawei.com> Signed-off-by: Lipeng <lipeng...@huawei.com> --- drivers/net/ethernet/hisilicon/hns3/hnae3.h| 3 + drivers/net/ethernet/hi

[PATCH V2 net-next 04/17] net: hns3: Free the ring_data structrue when change tqps

2017-12-18 Thread Lipeng
This patch fixes a memory leak problems in change tqps process, the function hns3_uninit_all_ring and hns3_init_all_ring may be called many times. Signed-off-by: qumingguang <quminggu...@huawei.com> Signed-off-by: Lipeng <lipeng...@huawei.com> --- drivers/net/ethernet/hisilicon/hns3

[PATCH V2 net-next 01/17] net: hns3: add support to query tqps number

2017-12-18 Thread Lipeng
This patch adds the support to query tqps number for PF driver by using ehtool -l command. Signed-off-by: qumingguang <quminggu...@huawei.com> Signed-off-by: Lipeng <lipeng...@huawei.com> --- drivers/net/ethernet/hisilicon/hns3/hnae3.h | 2 ++ drivers/net/ethernet/hi

[PATCH V2 net-next 10/17] net: hns3: cleanup mac auto-negotiation state query

2017-12-18 Thread Lipeng
rdware. This patch removes the mac auto-negotiation state query. Signed-off-by: Fuyun Liang <liangfuy...@huawei.com> Signed-off-by: Lipeng <lipeng...@huawei.com> --- .../ethernet/hisilicon/hns3/hns3pf/hclge_main.c| 24 -- 1 file changed, 24 deletions(-) diff --git a/dr

[PATCH V2 net-next 17/17] net: hns3: change TM sched mode to TC-based mode when SRIOV enabled

2017-12-18 Thread Lipeng
TC-based sched mode supports SRIOV enabled and SRIOV disabled. This patch change the TM sched mode to TC-based mode in initialization process. Fixes: cc9bb43ab394 ("net: hns3: Add tc-based TM support for sriov enabled port") Signed-off-by: Lipeng <lipeng...@huawei.com> --- driv

[PATCH V2 net-next 14/17] net: hns3: add Asym Pause support to phy default features

2017-12-18 Thread Lipeng
t Asym Pause can not be advertised when the phy negotiates flow control. Fixes: c4fb2cdf575d ("net: hns3: fix a bug for phy supported feature initialization") Signed-off-by: Fuyun Liang <liangfuy...@huawei.com> Signed-off-by: Lipeng <lipeng...@huawei.com> --- driv

[PATCH V2 net-next 06/17] net: hns3: Add a mask initialization for mac_vlan table

2017-12-18 Thread Lipeng
This patch sets vlan masked, in order to avoid the received packets being filtered. Signed-off-by: Shenjian <shenjia...@huawei.com> Signed-off-by: Lipeng <lipeng...@huawei.com> --- .../net/ethernet/hisilicon/hns3/hns3pf/hclge_cmd.h | 10 ++ .../ethernet/hisilicon/hns3/hns3pf/

[PATCH V3 net-next 07/17] net: hns3: Add vlan offload config command

2017-12-20 Thread Lipeng
This patch adds vlan offload config commands, initializes the rules of tx/rx vlan tag handle for hw. Signed-off-by: Shenjian <shenjia...@huawei.com> Signed-off-by: Lipeng <lipeng...@huawei.com> --- .../net/ethernet/hisilicon/hns3/hns3pf/hclge_cmd.h | 45 ++ .../ethernet/hi

[PATCH V3 net-next 11/17] net: hns3: fix for getting auto-negotiation state in hclge_get_autoneg

2017-12-20 Thread Lipeng
state in hclge_get_autoneg(). Fixes: 46a3df9f9718 ("net: hns3: Add HNS3 Acceleration Engine & Compatibility Layer Support") Signed-off-by: Fuyun Liang <liangfuy...@huawei.com> Signed-off-by: Lipeng <lipeng...@huawei.com> --- drivers/net/ethernet/hisilicon/hns3/hns3pf/hclge_main.c | 4 ++

[PATCH V3 net-next 08/17] net: hns3: Add ethtool related offload command

2017-12-20 Thread Lipeng
This patch adds offload command related to "ethtool -K". Signed-off-by: Shenjian <shenjia...@huawei.com> Signed-off-by: Lipeng <lipeng...@huawei.com> --- drivers/net/ethernet/hisilicon/hns3/hnae3.h | 3 +++ drivers/net/ethernet/hisilicon/hns3/hn

[PATCH V3 net-next 12/17] net: hns3: add support for set_pauseparam

2017-12-20 Thread Lipeng
This patch adds set_pauseparam support for ethtool cmd. Signed-off-by: Fuyun Liang <liangfuy...@huawei.com> Signed-off-by: Lipeng <lipeng...@huawei.com> --- drivers/net/ethernet/hisilicon/hns3/hns3_ethtool.c | 13 .../ethernet/hisilicon/hns3/hns3pf/hclge_ma

[PATCH V3 net-next 02/17] net: hns3: add support to modify tqps number

2017-12-20 Thread Lipeng
This patch adds the support to change tqps number for PF driver by using ehtool -L command. Signed-off-by: qumingguang <quminggu...@huawei.com> Signed-off-by: Lipeng <lipeng...@huawei.com> --- drivers/net/ethernet/hisilicon/hns3/hnae3.h| 3 + drivers/net/ethernet/hi

[PATCH V3 net-next 05/17] net: hns3: Get rss_size_max from configuration but not hardcode

2017-12-20 Thread Lipeng
From: qumingguang <quminggu...@huawei.com> Add configuration for rss_size_max in hdev but not hardcode it. Signed-off-by: qumingguang <quminggu...@huawei.com> Signed-off-by: Lipeng <lipeng...@huawei.com> --- drivers/net/ethernet/hisilicon/hns3/hns3pf/hclge_cmd.h | 2 ++ dr

[PATCH V3 net-next 16/17] net: hns3: Increase the default depth of bucket for TM shaper

2017-12-20 Thread Lipeng
com> Signed-off-by: Lipeng <lipeng...@huawei.com> --- drivers/net/ethernet/hisilicon/hns3/hns3pf/hclge_tm.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/drivers/net/ethernet/hisilicon/hns3/hns3pf/hclge_tm.c b/drivers/net/ethernet/hisilicon/hns3/hns3pf/hclge_tm.c i

[PATCH V3 net-next 17/17] net: hns3: change TM sched mode to TC-based mode when SRIOV enabled

2017-12-20 Thread Lipeng
TC-based sched mode supports SRIOV enabled and SRIOV disabled. This patch change the TM sched mode to TC-based mode in initialization process. Fixes: cc9bb43ab394 ("net: hns3: Add tc-based TM support for sriov enabled port") Signed-off-by: Lipeng <lipeng...@huawei.com> --- driv

[PATCH V3 net-next 10/17] net: hns3: cleanup mac auto-negotiation state query

2017-12-20 Thread Lipeng
rdware. This patch removes the mac auto-negotiation state query. Signed-off-by: Fuyun Liang <liangfuy...@huawei.com> Signed-off-by: Lipeng <lipeng...@huawei.com> --- .../ethernet/hisilicon/hns3/hns3pf/hclge_main.c| 24 -- 1 file changed, 24 deletions(-) diff --git a/dr

[PATCH V3 net-next 14/17] net: hns3: add Asym Pause support to phy default features

2017-12-20 Thread Lipeng
t Asym Pause can not be advertised when the phy negotiates flow control. Fixes: c4fb2cdf575d ("net: hns3: fix a bug for phy supported feature initialization") Signed-off-by: Fuyun Liang <liangfuy...@huawei.com> Signed-off-by: Lipeng <lipeng...@huawei.com> --- driv

[PATCH V3 net-next 15/17] net: hns3: add support for querying advertised pause frame by ethtool ethx

2017-12-20 Thread Lipeng
This patch adds support for querying advertised pause frame by using ethtool command(ethtool ethx). Fixes: 496d03e960ae ("net: hns3: Add Ethtool support to HNS3 driver") Signed-off-by: Fuyun Liang <liangfuy...@huawei.com> Signed-off-by: Lipeng <lipeng...@huawei.com> ---

[PATCH V3 net-next 13/17] net: hns3: add support to update flow control settings after autoneg

2017-12-20 Thread Lipeng
Liang <liangfuy...@huawei.com> Signed-off-by: Lipeng <lipeng...@huawei.com> --- .../ethernet/hisilicon/hns3/hns3pf/hclge_main.c| 36 ++ .../ethernet/hisilicon/hns3/hns3pf/hclge_main.h| 1 + .../ethernet/hisilicon/hns3/hns3pf/hclge_mdio.c| 4 +++ 3 files

[PATCH V3 net-next 09/17] net: hns3: Add handling vlan tag offload in bd

2017-12-20 Thread Lipeng
This patch deals with the vlan tag information between sk_buff and rx/tx bd. Signed-off-by: Shenjian <shenjia...@huawei.com> Signed-off-by: Lipeng <lipeng...@huawei.com> --- drivers/net/ethernet/hisilicon/hns3/hns3_enet.c | 83 +++-- 1 file changed, 78 inse

[PATCH V3 net-next 06/17] net: hns3: Add a mask initialization for mac_vlan table

2017-12-20 Thread Lipeng
This patch sets vlan masked, in order to avoid the received packets being filtered. Signed-off-by: Shenjian <shenjia...@huawei.com> Signed-off-by: Lipeng <lipeng...@huawei.com> --- .../net/ethernet/hisilicon/hns3/hns3pf/hclge_cmd.h | 10 ++ .../ethernet/hisilicon/hns3/hns3pf/

[PATCH V3 net-next 03/17] net: hns3: change the returned tqp number by ethtool -x

2017-12-20 Thread Lipeng
This patch modifies the return data of get_rxnfc, it will return the current handle's rss_size but not the total tqp number. because the tc_size has been change to the log2 of roundup power of two of rss_size. Signed-off-by: qumingguang <quminggu...@huawei.com> Signed-off-by: Lipeng &

[PATCH V3 net-next 00/17] add some features and fix some bugs for HNS3 driver

2017-12-20 Thread Lipeng
to-negotiation state in hclge_get_autoneg net: hns3: add Asym Pause support to phy default features Lipeng (13): net: hns3: add support to query tqps number net: hns3: add support to modify tqps number net: hns3: change the returned tqp number by ethtool -x net: hns3: Free the ring_data s

[PATCH V3 net-next 01/17] net: hns3: add support to query tqps number

2017-12-20 Thread Lipeng
This patch adds the support to query tqps number for PF driver by using ehtool -l command. Signed-off-by: qumingguang <quminggu...@huawei.com> Signed-off-by: Lipeng <lipeng...@huawei.com> --- drivers/net/ethernet/hisilicon/hns3/hnae3.h | 2 ++ drivers/net/ethernet/hi

[PATCH V3 net-next 04/17] net: hns3: Free the ring_data structrue when change tqps

2017-12-20 Thread Lipeng
This patch fixes a memory leak problems in change tqps process, the function hns3_uninit_all_ring and hns3_init_all_ring may be called many times. Signed-off-by: qumingguang <quminggu...@huawei.com> Signed-off-by: Lipeng <lipeng...@huawei.com> --- drivers/net/ethernet/hisilicon/hns3

[PATCH net-next 5/9] net: hns3: Add reset process in hclge_main

2017-11-01 Thread Lipeng
t. IMP reset is caused by watchdog timer expiration, the same range with core reset. PF reset will reset whole physical function. Signed-off-by: qumingguang <quminggu...@huawei.com> Signed-off-by: Lipeng <lipeng...@huawei.com> --- drivers/net/ethernet/hisilicon/hns3/hnae3.h

[PATCH net-next 7/9] net: hns3: Add reset interface implementation in client

2017-11-01 Thread Lipeng
This patch implement the interface of reset notification in hns3_enet it will do resetting business which include shutdown nic device, free and initialize client side resource. Signed-off-by: qumingguang <quminggu...@huawei.com> Signed-off-by: Lipeng <lipeng...@huawei.com> --- .../

[PATCH net-next 3/9] net: hns3: Refactor the initialization of command queue

2017-11-01 Thread Lipeng
rocess and initialization process, This patch moved out the descriptor allocate and memory maping from interface cmdq_init. Signed-off-by: qumingguang <quminggu...@huawei.com> Signed-off-by: Lipeng <lipeng...@huawei.com> --- .../net/ethernet/hisilicon/hns3/hns3pf/hclge_cmd.c | 39 +

[PATCH net-next 9/9] net: hns3: hns3:fix a bug about statistic counter in reset process

2017-11-01 Thread Lipeng
. This patch set all of the statistic counters to zero after reset. Signed-off-by: qumingguang <quminggu...@huawei.com> Signed-off-by: Lipeng <lipeng...@huawei.com> --- drivers/net/ethernet/hisilicon/hns3/hns3pf/hclge_main.c | 7 +++ 1 file changed, 7 insertions(+) diff --gi

[PATCH net-next 1/9] net: hns3: Refactor the mapping of tqp to vport

2017-11-01 Thread Lipeng
From: qumingguang <quminggu...@huawei.com> This patch refactor the mapping of tqp to vport, making the maping function can be used both in the reset process and initialization process. Signed-off-by: qumingguang <quminggu...@huawei.com> Signed-off-by: Lipeng <lipen

[PATCH net-next 2/9] net: hns3: Refactor mac_init function

2017-11-01 Thread Lipeng
rocess and initialization process. Signed-off-by: qumingguang <quminggu...@huawei.com> Signed-off-by: Lipeng <lipeng...@huawei.com> --- drivers/net/ethernet/hisilicon/hns3/hns3pf/hclge_main.c | 14 +++--- 1 file changed, 7 insertions(+), 7 deletions(-) diff --git a/drivers/net/

[PATCH net-next 0/9] net: hns3: add support for reset

2017-11-01 Thread Lipeng
expiration, the same range with core reset. PF reset will reset whole physical function. This patchset adds reset support for hns3 driver and fix some related bugs. Lipeng (2): net: hns3: Add timeout process in hns3_enet net: hns3: Add reset interface implementation in client qumingguang (7): net

[PATCH net-next 8/9] net: hns3: Fix a misuse to devm_free_irq

2017-11-01 Thread Lipeng
uawei.com> Signed-off-by: Lipeng <lipeng...@huawei.com> --- drivers/net/ethernet/hisilicon/hns3/hns3pf/hns3_enet.c | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/drivers/net/ethernet/hisilicon/hns3/hns3pf/hns3_enet.c b/drivers/net/ethernet/hisilicon/hns3/hns3pf

[PATCH net-next 4/9] net: hns3: Add support for misc interrupt

2017-11-01 Thread Lipeng
From: qumingguang <quminggu...@huawei.com> This patch adds initialization and deinitialization for misc interrupt. This interrupt will be used to handle reset message(IRQ). Signed-off-by: qumingguang <quminggu...@huawei.com> Signed-off-by: Lipeng <lipeng...@huawei.com> ---

[PATCH net-next 6/9] net: hns3: Add timeout process in hns3_enet

2017-11-01 Thread Lipeng
This patch add timeout handler in hns3_enet.c to handle TX side timeout event, when TX timeout event occur, it will triger NIC driver into reset process. Signed-off-by: qumingguang <quminggu...@huawei.com> Signed-off-by: Lipeng <lipeng...@huawei.com> --- .../net/ethernet/hisilicon

[PATCH net-next 5/6] net: hns3: add support for nway_reset

2017-11-02 Thread Lipeng
From: Fuyun Liang <liangfuy...@huawei.com> This patch adds nway_reset support for ethtool cmd. Signed-off-by: Fuyun Liang <liangfuy...@huawei.com> Signed-off-by: Lipeng <lipeng...@huawei.com> --- .../net/ethernet/hisilicon/hns3/hns3pf/hns3_ethtool.c | 18 ++

[PATCH net-next 2/6] net: hns3: fix for getting advertised_caps in hns3_get_link_ksettings

2017-11-02 Thread Lipeng
Signed-off-by: Fuyun Liang <liangfuy...@huawei.com> Signed-off-by: Lipeng <lipeng...@huawei.com> --- drivers/net/ethernet/hisilicon/hns3/hns3pf/hns3_ethtool.c | 3 +++ 1 file changed, 3 insertions(+) diff --git a/drivers/net/ethernet/hisilicon/hns3/hns3pf/hns3_ethtool.c b/drivers/net/

[PATCH net-next 1/6] net: hns3: fix for getting autoneg in hns3_get_link_ksettings

2017-11-02 Thread Lipeng
driver) Signed-off-by: Fuyun Liang <liangfuy...@huawei.com> Signed-off-by: Lipeng <lipeng...@huawei.com> --- .../ethernet/hisilicon/hns3/hns3pf/hns3_ethtool.c | 30 +++--- 1 file changed, 15 insertions(+), 15 deletions(-) diff --git a/drivers/net/ethernet/his

[PATCH net-next 0/6] net: hns3: support set_link_ksettings and for nway_reset ethtool command

2017-11-02 Thread Lipeng
This patch-set adds support for set_link_ksettings && for nway_resets ethtool command and fixes some related ethtool bugs. 1, patch[4/6] adds support for ethtool_ops.set_link_ksettings. 2, patch[5/6] adds support ethtool_ops.for nway_reset. 3, patch[1/6,2/6,3/6,6/6] fix some bugs for getting port

[PATCH net-next 6/6] net: hns3: fix a bug for phy supported feature initialization

2017-11-02 Thread Lipeng
tch fixes it. Fixes: 256727d (net: hns3: Add MDIO support to HNS3 Ethernet driver for hip08 SoC) Signed-off-by: Fuyun Liang <liangfuy...@huawei.com> Signed-off-by: Lipeng <lipeng...@huawei.com> --- drivers/net/ethernet/hisilicon/hns3/hns3pf/hclge_mdio.c | 10 ++ 1 file changed, 10 inse

[PATCH net-next 3/6] net: hns3: fix a bug in hns3_driv_to_eth_caps

2017-11-02 Thread Lipeng
Fixes: 496d03e (net: hns3: Add Ethtool support to HNS3 driver) Signed-off-by: Fuyun Liang <liangfuy...@huawei.com> Signed-off-by: Lipeng <lipeng...@huawei.com> --- drivers/net/ethernet/hisilicon/hns3/hns3pf/hns3_ethtool.c | 9 ++--- 1 file changed, 2 insertions(+), 7 deleti

[PATCH net-next 4/6] net: hns3: add support for set_link_ksettings

2017-11-02 Thread Lipeng
From: Fuyun Liang <liangfuy...@huawei.com> This patch adds set_link_ksettings support for ethtool cmd. Signed-off-by: Fuyun Liang <liangfuy...@huawei.com> Signed-off-by: Lipeng <lipeng...@huawei.com> --- drivers/net/ethernet/hisilicon/hns3/hns3pf/hns3_ethtool.c | 11 +

[PATCH net-next 2/2] {topost} net: hns3: cleanup mac auto-negotiation state query in hclge_update_speed_duplex

2017-11-07 Thread Lipeng
rdware. This patch removes mac auto-negotiation state query in hclge_update_speed_duplex(). Fixes: 46a3df9f9718 (net: hns3: Add HNS3 Acceleration Engine & Compatibility Layer Support) Signed-off-by: Fuyun Liang <liangfuy...@huawei.com> Signed-off-by: Lipeng <lipeng...@huawei.com> ---

  1   2   3   4   >