[patch net-next 02/11] net: hns: use device_* APIs instead of of_* APIs

2016-05-13 Thread Yisen Zhuang
* functions. Signed-off-by: Kejian Yan Signed-off-by: Yisen Zhuang --- drivers/net/ethernet/hisilicon/hns/hns_dsaf_main.c | 9 + drivers/net/ethernet/hisilicon/hns/hns_enet.c | 11 +++ 2 files changed, 8 insertions(+), 12 deletions(-) diff --git a/drivers/net/ethernet

[patch net-next 11/11] net: hns: enet adds support of acpi

2016-05-13 Thread Yisen Zhuang
From: Kejian Yan Enet needs to get configration parameter by acpi. This patch adds support of ACPI for enet. The configuration parameter will be configed in BIOS. Signed-off-by: Kejian Yan Signed-off-by: Yisen Zhuang --- drivers/net/ethernet/hisilicon/hns/hns_enet.c | 54

[patch net-next 08/11] net: hns: register phy device in each mac initial sequence

2016-05-13 Thread Yisen Zhuang
PHY PHY Signed-off-by: Kejian Yan <yankej...@huawei.com> Signed-off-by: Yisen Zhuang <yisen.zhu...@huawei.com> --- drivers/net/ethernet/hisilicon/hns/hns_dsaf_mac.c | 119 +- 1 file changed, 115 insertions(+), 4 deletions(-) diff --git a/drivers/net/ethe

[patch net-next 08/11] net: hns: register phy device in each mac initial sequence

2016-05-13 Thread Yisen Zhuang
-by: Kejian Yan Signed-off-by: Yisen Zhuang --- drivers/net/ethernet/hisilicon/hns/hns_dsaf_mac.c | 119 +- 1 file changed, 115 insertions(+), 4 deletions(-) diff --git a/drivers/net/ethernet/hisilicon/hns/hns_dsaf_mac.c b/drivers/net/ethernet/hisilicon/hns/hns_dsaf_mac.c index

[patch net-next 06/11] ACPI: bus: move acpi_match_device_ids() to linux/acpi.h

2016-05-13 Thread Yisen Zhuang
a stub function for it. Signed-off-by: Hanjun Guo <hanjun@linaro.org> Cc: Rafael J. Wysocki <r...@rjwysocki.net> Signed-off-by: Kejian Yan <yankej...@huawei.com> Signed-off-by: Yisen Zhuang <yisen.zhu...@huawei.com> --- include/acpi/acpi_bus.h | 2 -- include/linux/acpi.

[patch net-next 06/11] ACPI: bus: move acpi_match_device_ids() to linux/acpi.h

2016-05-13 Thread Yisen Zhuang
-off-by: Hanjun Guo Cc: Rafael J. Wysocki Signed-off-by: Kejian Yan Signed-off-by: Yisen Zhuang --- include/acpi/acpi_bus.h | 2 -- include/linux/acpi.h| 11 +++ 2 files changed, 11 insertions(+), 2 deletions(-) diff --git a/include/acpi/acpi_bus.h b/include/acpi/acpi_bus.h index

[patch net-next 01/11] net: hisilicon: add support of acpi for hns-mdio

2016-05-13 Thread Yisen Zhuang
quence by _DSD method in DSDT in ACPI case. Signed-off-by: Kejian Yan <yankej...@huawei.com> Signed-off-by: Yisen Zhuang <yisen.zhu...@huawei.com> --- drivers/net/ethernet/hisilicon/hns_mdio.c | 145 ++ 1 file changed, 90 insertions(+), 55 deletions(-) di

[patch net-next 00/11] net: hns: add support of ACPI

2016-05-13 Thread Yisen Zhuang
HNS driver needs to run only in ACPI case, so this series adds HNS support of acpi. The routine will call some ACPI helper functions, like acpi_match_device_ids() and acpi_evaluate_dsm(), which are not included in other cases. In order to make system compile successfully in other cases except

[patch net-next 10/11] net: hns: implement the reset sequence by asl

2016-05-13 Thread Yisen Zhuang
From: Kejian Yan <yankej...@huawei.com> The reset sequence is implemented in BIOS, the kernel can call _DSM method help to call the implementation in ACPI case. Here is a patch to do that. Signed-off-by: Kejian Yan <yankej...@huawei.com> Signed-off-by: Yisen Zhuang <yisen.zh

[patch net-next 10/11] net: hns: implement the reset sequence by asl

2016-05-13 Thread Yisen Zhuang
From: Kejian Yan The reset sequence is implemented in BIOS, the kernel can call _DSM method help to call the implementation in ACPI case. Here is a patch to do that. Signed-off-by: Kejian Yan Signed-off-by: Yisen Zhuang --- drivers/net/ethernet/hisilicon/hns/hns_dsaf_misc.c | 113

[patch net-next 01/11] net: hisilicon: add support of acpi for hns-mdio

2016-05-13 Thread Yisen Zhuang
in DSDT in ACPI case. Signed-off-by: Kejian Yan Signed-off-by: Yisen Zhuang --- drivers/net/ethernet/hisilicon/hns_mdio.c | 145 ++ 1 file changed, 90 insertions(+), 55 deletions(-) diff --git a/drivers/net/ethernet/hisilicon/hns_mdio.c b/drivers/net/ethernet/hisilicon

[patch net-next 00/11] net: hns: add support of ACPI

2016-05-13 Thread Yisen Zhuang
HNS driver needs to run only in ACPI case, so this series adds HNS support of acpi. The routine will call some ACPI helper functions, like acpi_match_device_ids() and acpi_evaluate_dsm(), which are not included in other cases. In order to make system compile successfully in other cases except

[PATCH v2 net-next] net: hns: add support of pause frame ctrl for HNS V2

2016-03-31 Thread Yisen Zhuang
pdated status function called by upper layer routine. Signed-off-by: Lisheng <lisheng...@huawei.com> Signed-off-by: Yisen Zhuang <yisen.zhu...@huawei.com> Reviewed-by: Andy Shevchenko <andriy.shevche...@linux.intel.com> --- change log: PATCH V2: - delete the useless code found by An

[PATCH v2 net-next] net: hns: add support of pause frame ctrl for HNS V2

2016-03-31 Thread Yisen Zhuang
by upper layer routine. Signed-off-by: Lisheng Signed-off-by: Yisen Zhuang Reviewed-by: Andy Shevchenko --- change log: PATCH V2: - delete the useless code found by Andy Shevchenko PATCH V1: - initial submit V1 Link: https://lkml.org/lkml/2016/3/29/77 --- drivers/net/ethernet/hisilicon/hns

[PATCH net-next] net: hns: add support of pause frame ctrl for HNS V2

2016-03-29 Thread Yisen Zhuang
pdated status function called by upper layer routine. Signed-off-by: Lisheng <lisheng...@huawei.com> Signed-off-by: Yisen Zhuang <yisen.zhu...@huawei.com> --- drivers/net/ethernet/hisilicon/hns/hns_ae_adapt.c | 21 ++- drivers/net/ethernet/hisilicon/hns/hns_dsaf_mac.c | 30 +++-

[PATCH net-next] net: hns: add support of pause frame ctrl for HNS V2

2016-03-29 Thread Yisen Zhuang
by upper layer routine. Signed-off-by: Lisheng Signed-off-by: Yisen Zhuang --- drivers/net/ethernet/hisilicon/hns/hns_ae_adapt.c | 21 ++- drivers/net/ethernet/hisilicon/hns/hns_dsaf_mac.c | 30 +++-- drivers/net/ethernet/hisilicon/hns/hns_dsaf_main.c | 73 +++--- drivers

[PATCH net-next 1/2] net: hns: fixed the setting and getting overtime bug

2016-03-28 Thread Yisen Zhuang
From: Lisheng <lisheng...@huawei.com> The overtime setting and getting REGs in HNS V2 is defferent from HNS V1. It needs to be distinguished between them if getting or setting the REGs. Signed-off-by: Lisheng <lisheng...@huawei.com> Signed-off-by: Yisen Zhuang <yisen.zh

[PATCH net-next 1/2] net: hns: fixed the setting and getting overtime bug

2016-03-28 Thread Yisen Zhuang
From: Lisheng The overtime setting and getting REGs in HNS V2 is defferent from HNS V1. It needs to be distinguished between them if getting or setting the REGs. Signed-off-by: Lisheng Signed-off-by: Yisen Zhuang --- drivers/net/ethernet/hisilicon/hns/hns_ae_adapt.c | 60 +++ drivers

[PATCH net-next 0/2] net: hns: add setting coalescing parameters for HNS v2

2016-03-28 Thread Yisen Zhuang
There are some different REGs about coalescing setting between HNS V2 and HNS V1. The current HNS driver is only considering the situation for HNS V1. It needs to support both of them. And Ethtool needs to know if it is successful to set the parameters as well. The patchset as below: >from

[PATCH net-next 2/2] net: hns: set-coalesce-usecs returns errno by dsaf.ko

2016-03-28 Thread Yisen Zhuang
From: Lisheng <lisheng...@huawei.com> It may fail to set coalesce usecs to HW, and Ethtool needs to know if it is successful to cfg the parameter or not. So it needs return the errno by dsaf.ko. Signed-off-by: Lisheng <lisheng...@huawei.com> Signed-off-by: Yisen Zhuang <yisen.zh

[PATCH net-next 0/2] net: hns: add setting coalescing parameters for HNS v2

2016-03-28 Thread Yisen Zhuang
There are some different REGs about coalescing setting between HNS V2 and HNS V1. The current HNS driver is only considering the situation for HNS V1. It needs to support both of them. And Ethtool needs to know if it is successful to set the parameters as well. The patchset as below: >from

[PATCH net-next 2/2] net: hns: set-coalesce-usecs returns errno by dsaf.ko

2016-03-28 Thread Yisen Zhuang
From: Lisheng It may fail to set coalesce usecs to HW, and Ethtool needs to know if it is successful to cfg the parameter or not. So it needs return the errno by dsaf.ko. Signed-off-by: Lisheng Signed-off-by: Yisen Zhuang --- drivers/net/ethernet/hisilicon/hns/hnae.h | 2 +- drivers

[PATCH net 0/7] net: hns: fix some bugs in HNS driver

2016-03-24 Thread Yisen Zhuang
Here are some bug fixed patches for HNS driver. They are: >from Kejian, fix for the warning of passing zero to 'PTR_ERR' >from qianqian, four fixes for inappropriate operation in hns driver >from Sheng, one fix for optimization of irq proccess in hns driver, and one fix for hilink status for

[PATCH net 4/7] net: hns: remove useless variable assignment and comment

2016-03-24 Thread Yisen Zhuang
; Signed-off-by: Yisen Zhuang <yisen.zhu...@huawei.com> --- drivers/net/ethernet/hisilicon/hns/hns_enet.c | 5 + 1 file changed, 1 insertion(+), 4 deletions(-) diff --git a/drivers/net/ethernet/hisilicon/hns/hns_enet.c b/drivers/net/ethernet/hisilicon/hns/hns_enet.c index 71aa3

[PATCH net 6/7] net: hns: fix warning of passing zero to 'PTR_ERR'

2016-03-24 Thread Yisen Zhuang
yankej...@huawei.com> Signed-off-by: Yisen Zhuang <yisen.zhu...@huawei.com> --- drivers/net/ethernet/hisilicon/hns/hns_enet.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/net/ethernet/hisilicon/hns/hns_enet.c b/drivers/net/ethernet/hisilicon/hns/hns_enet.c in

[PATCH net 0/7] net: hns: fix some bugs in HNS driver

2016-03-24 Thread Yisen Zhuang
Here are some bug fixed patches for HNS driver. They are: >from Kejian, fix for the warning of passing zero to 'PTR_ERR' >from qianqian, four fixes for inappropriate operation in hns driver >from Sheng, one fix for optimization of irq proccess in hns driver, and one fix for hilink status for

[PATCH net 4/7] net: hns: remove useless variable assignment and comment

2016-03-24 Thread Yisen Zhuang
From: Qianqian Xie The variable head in hns_nic_tx_fini_pro has read a value, but it is obviously no use. The patch will fix it. And the comment is nothing to do with the routine, so it has to be removed Signed-off-by: Qianqian Xie Signed-off-by: Yisen Zhuang --- drivers/net/ethernet

[PATCH net 6/7] net: hns: fix warning of passing zero to 'PTR_ERR'

2016-03-24 Thread Yisen Zhuang
R_ERR(ae_node); dev_err(dev, "not find ae-handle\n"); goto out_read_prop_fail; } if the ae_node is NULL, PTR_ERR(ae_node) means it returns success. And the return value should be -ENODEV. Signed-off-by: Kejian Yan Signed-off-by: Yisen Zhuang --

[PATCH net 2/7] net: hns: optimizate fmt of snprintf()

2016-03-24 Thread Yisen Zhuang
ring[i].desc); Signed-off-by: Qianqian Xie <xieqianq...@huawei.com> Signed-off-by: Kejian Yan <yankej...@huawei.com> Signed-off-by: Yisen Zhuang <yisen.zhu...@huawei.com> --- drivers/net/ethernet/hisilicon/hns/hns_dsaf_gmac.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) dif

[PATCH net 2/7] net: hns: optimizate fmt of snprintf()

2016-03-24 Thread Yisen Zhuang
qian Xie Signed-off-by: Kejian Yan Signed-off-by: Yisen Zhuang --- drivers/net/ethernet/hisilicon/hns/hns_dsaf_gmac.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/drivers/net/ethernet/hisilicon/hns/hns_dsaf_gmac.c b/drivers/net/ethernet/hisilicon/hns/hns_dsaf_gmac.c index 6e2

[PATCH net 7/7] net: hns: bug fix about getting hilink status for HNS v2

2016-03-24 Thread Yisen Zhuang
From: Sheng Li The hilink status reg in HNS V2 is different from HNS v1. In HNS V2, It distinguishes differnt lane status according to the bit-field of the reg. As is shown below: [0:0] ---> lane0 [1:1] ---> lane1 ... But the current driver reads the reg to get the hilink

[PATCH net 7/7] net: hns: bug fix about getting hilink status for HNS v2

2016-03-24 Thread Yisen Zhuang
From: Sheng Li The hilink status reg in HNS V2 is different from HNS v1. In HNS V2, It distinguishes differnt lane status according to the bit-field of the reg. As is shown below: [0:0] ---> lane0 [1:1] ---> lane1 ... But the current driver reads the reg to get the hilink status ONLY

[PATCH net 3/7] net: hns: bug fix for return values

2016-03-24 Thread Yisen Zhuang
From: Qianqian Xie <xieqianq...@huawei.com> The return values in the first two functions mdiobus_write() are ignored. The patch will fix it. Signed-off-by: Qianqian Xie <xieqianq...@huawei.com> Signed-off-by: Yisen Zhuang <yisen.zhu...@huawei.com> --- drivers/net/ethe

[PATCH net 3/7] net: hns: bug fix for return values

2016-03-24 Thread Yisen Zhuang
From: Qianqian Xie The return values in the first two functions mdiobus_write() are ignored. The patch will fix it. Signed-off-by: Qianqian Xie Signed-off-by: Yisen Zhuang --- drivers/net/ethernet/hisilicon/hns/hns_ethtool.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff

[PATCH net 5/7] net: hns: optimizate irq proccess for HNS V2

2016-03-24 Thread Yisen Zhuang
s to NULL. Signed-off-by: Sheng Li <lisheng...@huawei.com> Signed-off-by: Yisen Zhuang <yisen.zhu...@huawei.com> --- drivers/net/ethernet/hisilicon/hns/hns_enet.c | 9 + 1 file changed, 5 insertions(+), 4 deletions(-) diff --git a/drivers/net/ethernet/hisilicon/hns/hns_enet.c b

[PATCH net 1/7] net: hns: fix a bug for cycle index

2016-03-24 Thread Yisen Zhuang
From: Qianqian Xie <xieqianq...@huawei.com> The cycle index should be varied while the variable j is a fixed value. The patch will fix this bug. Signed-off-by: Qianqian Xie <xieqianq...@huawei.com> Signed-off-by: Yisen Zhuang <yisen.zhu...@huawei.com> --- drivers/net/ethe

[PATCH net 5/7] net: hns: optimizate irq proccess for HNS V2

2016-03-24 Thread Yisen Zhuang
Li Signed-off-by: Yisen Zhuang --- drivers/net/ethernet/hisilicon/hns/hns_enet.c | 9 + 1 file changed, 5 insertions(+), 4 deletions(-) diff --git a/drivers/net/ethernet/hisilicon/hns/hns_enet.c b/drivers/net/ethernet/hisilicon/hns/hns_enet.c index f0c9a41..66d1652 100644 --- a/drivers/

[PATCH net 1/7] net: hns: fix a bug for cycle index

2016-03-24 Thread Yisen Zhuang
From: Qianqian Xie The cycle index should be varied while the variable j is a fixed value. The patch will fix this bug. Signed-off-by: Qianqian Xie Signed-off-by: Yisen Zhuang --- drivers/net/ethernet/hisilicon/hns/hns_dsaf_main.c | 12 ++-- 1 file changed, 6 insertions(+), 6

[PATCH V2 net 02/10] net: hns: fixed portid bug in sending manage pkt

2016-03-22 Thread Yisen Zhuang
, when sending mamagement packets, the driver should config the port id to BD descs. Signed-off-by: Sheng Li <lisheng...@huawei.com> Signed-off-by: Yisen Zhuang <yisen.zhu...@huawei.com> --- drivers/net/ethernet/hisilicon/hns/hnae.h | 3 +++ drivers/net/ethernet/hisilicon/hns/

[PATCH V2 net 02/10] net: hns: fixed portid bug in sending manage pkt

2016-03-22 Thread Yisen Zhuang
, the driver should config the port id to BD descs. Signed-off-by: Sheng Li Signed-off-by: Yisen Zhuang --- drivers/net/ethernet/hisilicon/hns/hnae.h | 3 +++ drivers/net/ethernet/hisilicon/hns/hns_ae_adapt.c | 1 + drivers/net/ethernet/hisilicon/hns/hns_enet.c | 6 +- 3 files

[PATCH V2 net 05/10] net: hns: set xge statistic reg as read only

2016-03-22 Thread Yisen Zhuang
ightly. Signed-off-by: Qianqian Xie <xieqianq...@huawei.com> Signed-off-by: Yisen Zhuang <yisen.zhu...@huawei.com> --- drivers/net/ethernet/hisilicon/hns/hns_dsaf_main.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/drivers/net/ethernet/hisilicon/hns/hns_dsaf_mai

[PATCH V2 net 05/10] net: hns: set xge statistic reg as read only

2016-03-22 Thread Yisen Zhuang
Signed-off-by: Yisen Zhuang --- drivers/net/ethernet/hisilicon/hns/hns_dsaf_main.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/drivers/net/ethernet/hisilicon/hns/hns_dsaf_main.c b/drivers/net/ethernet/hisilicon/hns/hns_dsaf_main.c index 38fc5be..5c1ac9b 100644

[PATCH V2 net 08/10] net: hns: fix the bug about mtu setting

2016-03-22 Thread Yisen Zhuang
From: Kejian Yan <yankej...@huawei.com> In chip V1, the maximum mtu value is 9600. But in chip V2, it is 9728. And it is always configurates as 9600 before this patch. Signed-off-by: Kejian Yan <yankej...@huawei.com> Signed-off-by: Yisen Zhuang <yisen.zhu...@huawei.com> --- dr

[PATCH V2 net 09/10] net: hns: adds limitation for debug port mtu

2016-03-22 Thread Yisen Zhuang
From: Kejian Yan <yankej...@huawei.com> If mtu for debug port is set more than 1500, it may cause that packets are dropped by ppe. So maximum value for debug port should be 1500. Signed-off-by: Kejian Yan <yankej...@huawei.com> Signed-off-by: Yisen Zhuang <yisen.zhu...@huawei.com&

[PATCH V2 net 08/10] net: hns: fix the bug about mtu setting

2016-03-22 Thread Yisen Zhuang
From: Kejian Yan In chip V1, the maximum mtu value is 9600. But in chip V2, it is 9728. And it is always configurates as 9600 before this patch. Signed-off-by: Kejian Yan Signed-off-by: Yisen Zhuang --- drivers/net/ethernet/hisilicon/hns/hns_dsaf_mac.c | 4 +++- drivers/net/ethernet

[PATCH V2 net 09/10] net: hns: adds limitation for debug port mtu

2016-03-22 Thread Yisen Zhuang
From: Kejian Yan If mtu for debug port is set more than 1500, it may cause that packets are dropped by ppe. So maximum value for debug port should be 1500. Signed-off-by: Kejian Yan Signed-off-by: Yisen Zhuang --- change log: PATCH V2: - use tabs instead of spaces to indent the value

[PATCH V2 net 01/10] net: hns: bug fix about ping6

2016-03-22 Thread Yisen Zhuang
uawei.com> Signed-off-by: Yisen Zhuang <yisen.zhu...@huawei.com> --- change log: PATCH v2: - modifies the wrong charator "whick" to "which" in commit log - use the "eth_hdr()" help to get source mac of packets PATCH v1: - first submit Link: https://

[PATCH V2 net 04/10] net: hns: fixed the bug about GMACs mac setting

2016-03-22 Thread Yisen Zhuang
ervice ports. It obviously the condition needs to be deleted. Signed-off-by: Sheng Li <lisheng...@huawei.com> Signed-off-by: Yisen Zhuang <yisen.zhu...@huawei.com> --- drivers/net/ethernet/hisilicon/hns/hns_dsaf_gmac.c | 18 -- 1 file changed, 8 insertions(+), 10 deleti

[PATCH V2 net 07/10] net: hns: fixes a bug of RSS

2016-03-22 Thread Yisen Zhuang
width of data type when using memcpy. Signed-off-by: Kejian Yan <yankej...@huawei.com> Signed-off-by: Yisen Zhuang <yisen.zhu...@huawei.com> Reviewed-by: Andy Shevchenko <andriy.shevche...@linux.intel.com> --- drivers/net/ethernet/hisilicon/hns/hns_ae_adapt.c | 6 -- drivers/ne

[PATCH V2 net 00/10] net: hns: bugs fixed for hns

2016-03-22 Thread Yisen Zhuang
This series includes some bug fixes and updates for hns driver. >from Daode, one fix about mss. >from Kejian, one fix about ping6 issue, one fix about mac address setting, two fix for RSS setting, two fix about mtu setting. >from qianqian, fixed HNS v2 xge statistic reg issue. >from Sheng, one

[PATCH V2 net 01/10] net: hns: bug fix about ping6

2016-03-22 Thread Yisen Zhuang
From: Kejian Yan The current upstreaming code fails to ping other IPv6 net device, because the enet receives the multicast packets with the src mac addr which is the same as its mac addr. These packets need to be dropped. Signed-off-by: Kejian Yan Signed-off-by: Yisen Zhuang --- change log

[PATCH V2 net 04/10] net: hns: fixed the bug about GMACs mac setting

2016-03-22 Thread Yisen Zhuang
the condition needs to be deleted. Signed-off-by: Sheng Li Signed-off-by: Yisen Zhuang --- drivers/net/ethernet/hisilicon/hns/hns_dsaf_gmac.c | 18 -- 1 file changed, 8 insertions(+), 10 deletions(-) diff --git a/drivers/net/ethernet/hisilicon/hns/hns_dsaf_gmac.c b/drivers/net

[PATCH V2 net 07/10] net: hns: fixes a bug of RSS

2016-03-22 Thread Yisen Zhuang
memcpy. Signed-off-by: Kejian Yan Signed-off-by: Yisen Zhuang Reviewed-by: Andy Shevchenko --- drivers/net/ethernet/hisilicon/hns/hns_ae_adapt.c | 6 -- drivers/net/ethernet/hisilicon/hns/hns_ethtool.c | 18 ++ 2 files changed, 22 insertions(+), 2 deletions(-) diff --git

[PATCH V2 net 00/10] net: hns: bugs fixed for hns

2016-03-22 Thread Yisen Zhuang
This series includes some bug fixes and updates for hns driver. >from Daode, one fix about mss. >from Kejian, one fix about ping6 issue, one fix about mac address setting, two fix for RSS setting, two fix about mtu setting. >from qianqian, fixed HNS v2 xge statistic reg issue. >from Sheng, one

[PATCH V2 net 03/10] net: hns: add uc match for debug ports

2016-03-22 Thread Yisen Zhuang
local addr in mac table. And the switch is ON in initialization. Signed-off-by: Kejian Yan <yankej...@huawei.com> Signed-off-by: Peng Li <lipeng...@huawei.com> Signed-off-by: Yisen Zhuang <yisen.zhu...@huawei.com> --- change log: PATCH v2: - fix the comments like unne

[PATCH V2 net 03/10] net: hns: add uc match for debug ports

2016-03-22 Thread Yisen Zhuang
. And the switch is ON in initialization. Signed-off-by: Kejian Yan Signed-off-by: Peng Li Signed-off-by: Yisen Zhuang --- change log: PATCH v2: - fix the comments like unnecessary casts PATCH v1: - first submit Link: https://lkml.org/lkml/2016/3/21/224 --- drivers/net/ethernet/hisilicon

[PATCH V2 net 10/10] net: hns: bug fix about the overflow of mss

2016-03-22 Thread Yisen Zhuang
From: Daode Huang <huangda...@hisilicon.com> When set MTU to the minimum value 68, there are increasing number of error packets occur, which is caused by the overflowed value of mss. This patch fix the bug. Signed-off-by: Daode Huang <huangda...@hisilicon.com> Signed-off-by:

[PATCH V2 net 10/10] net: hns: bug fix about the overflow of mss

2016-03-22 Thread Yisen Zhuang
From: Daode Huang When set MTU to the minimum value 68, there are increasing number of error packets occur, which is caused by the overflowed value of mss. This patch fix the bug. Signed-off-by: Daode Huang Signed-off-by: Yisen Zhuang --- drivers/net/ethernet/hisilicon/hns/hns_enet.c | 17

[PATCH V2 net 06/10] net: hns: fix return value of the function about rss

2016-03-22 Thread Yisen Zhuang
From: Kejian Yan <yankej...@huawei.com> Both .get_rxfh and .set_rxfh are always return 0, it should return result from hardware when getting or setting rss. And the rss function should return the correct data type. Signed-off-by: Kejian Yan <yankej...@huawei.com> Signed-off-by:

[PATCH V2 net 06/10] net: hns: fix return value of the function about rss

2016-03-22 Thread Yisen Zhuang
From: Kejian Yan Both .get_rxfh and .set_rxfh are always return 0, it should return result from hardware when getting or setting rss. And the rss function should return the correct data type. Signed-off-by: Kejian Yan Signed-off-by: Yisen Zhuang --- change log: PATCH V2: - fix the wrong

Re: [PATCH net 09/10] net: hns: adds limitation for debug port mtu

2016-03-21 Thread Yisen Zhuang
在 2016/3/21 22:17, Sergei Shtylyov 写道: > Hello. > > On 03/21/2016 02:06 PM, Yisen Zhuang wrote: > >> From: Kejian Yan <yankej...@huawei.com> >> >> If mtu for debug port is set more than 1500, it may cause that packets >> are dropped by ppe. So m

Re: [PATCH net 09/10] net: hns: adds limitation for debug port mtu

2016-03-21 Thread Yisen Zhuang
在 2016/3/21 22:17, Sergei Shtylyov 写道: > Hello. > > On 03/21/2016 02:06 PM, Yisen Zhuang wrote: > >> From: Kejian Yan >> >> If mtu for debug port is set more than 1500, it may cause that packets >> are dropped by ppe. So maximum value for debug port should

Re: [PATCH net 06/10] net: hns: fix return value of the function about rss

2016-03-21 Thread Yisen Zhuang
在 2016/3/21 23:42, David Miller 写道: > From: Yisen Zhuang <yisen.zhu...@huawei.com> > Date: Mon, 21 Mar 2016 19:06:37 +0800 > >> diff --git a/drivers/net/ethernet/hisilicon/hns/hns_ethtool.c >> b/drivers/net/ethernet/hisilicon/hns/hns_ethtool.c >> index 3c4a3bc

Re: [PATCH net 06/10] net: hns: fix return value of the function about rss

2016-03-21 Thread Yisen Zhuang
在 2016/3/21 23:42, David Miller 写道: > From: Yisen Zhuang > Date: Mon, 21 Mar 2016 19:06:37 +0800 > >> diff --git a/drivers/net/ethernet/hisilicon/hns/hns_ethtool.c >> b/drivers/net/ethernet/hisilicon/hns/hns_ethtool.c >> index 3c4a3bc..f3a5e05 100644 >> ---

Re: [PATCH net 03/10] net: hns: add uc match for debug ports

2016-03-21 Thread Yisen Zhuang
在 2016/3/21 23:40, David Miller 写道: > From: Yisen Zhuang <yisen.zhu...@huawei.com> > Date: Mon, 21 Mar 2016 19:06:34 +0800 > >> +(void)hns_mac_set_promisc(mac_cb, (u8)!!en); > > This cast to void is unnecssary. I think hns_mac_set_promisc don't need to re

Re: [PATCH net 03/10] net: hns: add uc match for debug ports

2016-03-21 Thread Yisen Zhuang
在 2016/3/21 23:40, David Miller 写道: > From: Yisen Zhuang > Date: Mon, 21 Mar 2016 19:06:34 +0800 > >> +(void)hns_mac_set_promisc(mac_cb, (u8)!!en); > > This cast to void is unnecssary. I think hns_mac_set_promisc don't need to return a value, so i will fix it in

Re: [PATCH net 01/10] net: hns: bug fix about ping6

2016-03-21 Thread Yisen Zhuang
在 2016/3/21 23:39, David Miller 写道: > From: Yisen Zhuang <yisen.zhu...@huawei.com> > Date: Mon, 21 Mar 2016 19:06:32 +0800 > >> From: Kejian Yan <yankej...@huawei.com> >> >> The current upstreaming code fails to ping other IPv6 net device, because >

Re: [PATCH net 01/10] net: hns: bug fix about ping6

2016-03-21 Thread Yisen Zhuang
在 2016/3/21 23:39, David Miller 写道: > From: Yisen Zhuang > Date: Mon, 21 Mar 2016 19:06:32 +0800 > >> From: Kejian Yan >> >> The current upstreaming code fails to ping other IPv6 net device, because >> the enet receives the multicast pa

[PATCH net 03/10] net: hns: add uc match for debug ports

2016-03-21 Thread Yisen Zhuang
local addr in mac table. And the switch is ON in initialization. Signed-off-by: Kejian Yan <yankej...@huawei.com> Signed-off-by: Peng Li <lipeng...@huawei.com> Signed-off-by: Yisen Zhuang <yisen.zhu...@huawei.com> --- drivers/net/ethernet/hisilicon/hns/hns_ae_adapt.c | 3 +

[PATCH net 03/10] net: hns: add uc match for debug ports

2016-03-21 Thread Yisen Zhuang
. And the switch is ON in initialization. Signed-off-by: Kejian Yan Signed-off-by: Peng Li Signed-off-by: Yisen Zhuang --- drivers/net/ethernet/hisilicon/hns/hns_ae_adapt.c | 3 +++ drivers/net/ethernet/hisilicon/hns/hns_dsaf_gmac.c | 30 +- drivers/net/ethernet/hisilicon/hns

[PATCH net 00/10] net: hns: bugs fixed for hns

2016-03-21 Thread Yisen Zhuang
This series includes some bug fixes and updates for hns driver. >from Daode, one fix about mss. >from Kejian, one fix about ping6 issue, one fix about mac address setting, two fix for RSS setting, two fix about mtu setting. >from qianqian, fixed HNS v2 xge statistic reg issue. >from Sheng, one

[PATCH net 00/10] net: hns: bugs fixed for hns

2016-03-21 Thread Yisen Zhuang
This series includes some bug fixes and updates for hns driver. >from Daode, one fix about mss. >from Kejian, one fix about ping6 issue, one fix about mac address setting, two fix for RSS setting, two fix about mtu setting. >from qianqian, fixed HNS v2 xge statistic reg issue. >from Sheng, one

[PATCH net 08/10] net: hns: fix the bug about mtu setting

2016-03-21 Thread Yisen Zhuang
From: Kejian Yan <yankej...@huawei.com> In chip V1, the maximum mtu value is 9600. But in chip V2, it is 9728. And it is always configurates as 9600 before this patch. Signed-off-by: Kejian Yan <yankej...@huawei.com> Signed-off-by: Yisen Zhuang <yisen.zhu...@huawei.com> --- dr

[PATCH net 10/10] net: hns: bug fix about the overflow of mss

2016-03-21 Thread Yisen Zhuang
From: Daode Huang <huangda...@hisilicon.com> When set MTU to the minimum value 68, there are increasing number of error packets occur, which is caused by the overflowed value of mss. This patch fix the bug. Signed-off-by: Daode Huang <huangda...@hisilicon.com> Signed-off-by:

[PATCH net 01/10] net: hns: bug fix about ping6

2016-03-21 Thread Yisen Zhuang
uawei.com> Signed-off-by: Yisen Zhuang <yisen.zhu...@huawei.com> --- drivers/net/ethernet/hisilicon/hns/hns_enet.c | 9 + 1 file changed, 9 insertions(+) diff --git a/drivers/net/ethernet/hisilicon/hns/hns_enet.c b/drivers/net/ethernet/hisilicon/hns/hns_enet.c index 3f77f

[PATCH net 08/10] net: hns: fix the bug about mtu setting

2016-03-21 Thread Yisen Zhuang
From: Kejian Yan In chip V1, the maximum mtu value is 9600. But in chip V2, it is 9728. And it is always configurates as 9600 before this patch. Signed-off-by: Kejian Yan Signed-off-by: Yisen Zhuang --- drivers/net/ethernet/hisilicon/hns/hns_dsaf_mac.c | 4 +++- drivers/net/ethernet

[PATCH net 10/10] net: hns: bug fix about the overflow of mss

2016-03-21 Thread Yisen Zhuang
From: Daode Huang When set MTU to the minimum value 68, there are increasing number of error packets occur, which is caused by the overflowed value of mss. This patch fix the bug. Signed-off-by: Daode Huang Signed-off-by: Yisen Zhuang --- drivers/net/ethernet/hisilicon/hns/hns_enet.c | 17

[PATCH net 01/10] net: hns: bug fix about ping6

2016-03-21 Thread Yisen Zhuang
From: Kejian Yan The current upstreaming code fails to ping other IPv6 net device, because the enet receives the multicast packets with the src mac addr whick is the same as its mac addr. These packets need to be dropped. Signed-off-by: Kejian Yan Signed-off-by: Yisen Zhuang --- drivers/net

[PATCH net 05/10] net: hns: set xge statistic reg as read only

2016-03-21 Thread Yisen Zhuang
ightly. Signed-off-by: Qianqian Xie <xieqianq...@huawei.com> Signed-off-by: Yisen Zhuang <yisen.zhu...@huawei.com> --- drivers/net/ethernet/hisilicon/hns/hns_dsaf_main.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/drivers/net/ethernet/hisilicon/hns/hns_dsaf_mai

[PATCH net 07/10] net: hns: fixes a bug of RSS

2016-03-21 Thread Yisen Zhuang
width of data type when using memcpy. Signed-off-by: Kejian Yan <yankej...@huawei.com> Signed-off-by: Yisen Zhuang <yisen.zhu...@huawei.com> Reviewed-by: Andy Shevchenko <andriy.shevche...@linux.intel.com> --- drivers/net/ethernet/hisilicon/hns/hns_ae_adapt.c | 6 -- drivers/ne

[PATCH net 09/10] net: hns: adds limitation for debug port mtu

2016-03-21 Thread Yisen Zhuang
From: Kejian Yan <yankej...@huawei.com> If mtu for debug port is set more than 1500, it may cause that packets are dropped by ppe. So maximum value for debug port should be 1500. Signed-off-by: Kejian Yan <yankej...@huawei.com> Signed-off-by: Yisen Zhuang <yisen.zhu...@huawei.co

[PATCH net 05/10] net: hns: set xge statistic reg as read only

2016-03-21 Thread Yisen Zhuang
Signed-off-by: Yisen Zhuang --- drivers/net/ethernet/hisilicon/hns/hns_dsaf_main.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/drivers/net/ethernet/hisilicon/hns/hns_dsaf_main.c b/drivers/net/ethernet/hisilicon/hns/hns_dsaf_main.c index 38fc5be..5c1ac9b 100644

[PATCH net 07/10] net: hns: fixes a bug of RSS

2016-03-21 Thread Yisen Zhuang
memcpy. Signed-off-by: Kejian Yan Signed-off-by: Yisen Zhuang Reviewed-by: Andy Shevchenko --- drivers/net/ethernet/hisilicon/hns/hns_ae_adapt.c | 6 -- drivers/net/ethernet/hisilicon/hns/hns_ethtool.c | 18 ++ 2 files changed, 22 insertions(+), 2 deletions(-) diff --git

[PATCH net 09/10] net: hns: adds limitation for debug port mtu

2016-03-21 Thread Yisen Zhuang
From: Kejian Yan If mtu for debug port is set more than 1500, it may cause that packets are dropped by ppe. So maximum value for debug port should be 1500. Signed-off-by: Kejian Yan Signed-off-by: Yisen Zhuang --- drivers/net/ethernet/hisilicon/hns/hns_dsaf_mac.c | 3 +++ drivers/net

[PATCH net 04/10] net: hns: fixed the bug about GMACs mac setting

2016-03-21 Thread Yisen Zhuang
ervice ports. It obviously the condition needs to be deleted. Signed-off-by: Sheng Li <lisheng...@huawei.com> Signed-off-by: Yisen Zhuang <yisen.zhu...@huawei.com> --- drivers/net/ethernet/hisilicon/hns/hns_dsaf_gmac.c | 18 -- 1 file changed, 8 insertions(+), 10 deleti

[PATCH net 04/10] net: hns: fixed the bug about GMACs mac setting

2016-03-21 Thread Yisen Zhuang
the condition needs to be deleted. Signed-off-by: Sheng Li Signed-off-by: Yisen Zhuang --- drivers/net/ethernet/hisilicon/hns/hns_dsaf_gmac.c | 18 -- 1 file changed, 8 insertions(+), 10 deletions(-) diff --git a/drivers/net/ethernet/hisilicon/hns/hns_dsaf_gmac.c b/drivers/net

[PATCH net 06/10] net: hns: fix return value of the function about rss

2016-03-21 Thread Yisen Zhuang
From: Kejian Yan <yankej...@huawei.com> Both .get_rxfh and .get_rxfh are always return 0, it should return result from hardware when getting or setting rss. And the rss function should return the correct data type. Signed-off-by: Kejian Yan <yankej...@huawei.com> Signed-off-by:

[PATCH net 06/10] net: hns: fix return value of the function about rss

2016-03-21 Thread Yisen Zhuang
From: Kejian Yan Both .get_rxfh and .get_rxfh are always return 0, it should return result from hardware when getting or setting rss. And the rss function should return the correct data type. Signed-off-by: Kejian Yan Signed-off-by: Yisen Zhuang Reviewed-by: Andy Shevchenko --- drivers/net

[PATCH net 02/10] net: hns: fixed portid bug in sending manage pkt

2016-03-21 Thread Yisen Zhuang
, when sending mamagement packets, the driver should config the port id to BD descs. Signed-off-by: Sheng Li <lisheng...@huawei.com> Signed-off-by: Yisen Zhuang <yisen.zhu...@huawei.com> --- drivers/net/ethernet/hisilicon/hns/hnae.h | 3 +++ drivers/net/ethernet/hisilicon/hns/

[PATCH net 02/10] net: hns: fixed portid bug in sending manage pkt

2016-03-21 Thread Yisen Zhuang
, the driver should config the port id to BD descs. Signed-off-by: Sheng Li Signed-off-by: Yisen Zhuang --- drivers/net/ethernet/hisilicon/hns/hnae.h | 3 +++ drivers/net/ethernet/hisilicon/hns/hns_ae_adapt.c | 1 + drivers/net/ethernet/hisilicon/hns/hns_enet.c | 6 +- 3 files

Re: [PATCH] asm-generic: remove old nonatomic-io wrapper files

2016-02-29 Thread Yisen Zhuang
> drivers/dma/idma64.h| 2 +- > drivers/net/ethernet/hisilicon/hns/hns_dsaf_xgmac.c | 2 +- The HNS portion: Acked-by: Yisen Zhuang <yisen.zhu...@huawei.com> > drivers/net/ethernet/netronome/nfp/nfp_net.h| 2 +- > include/asm-generic/io-64-nonatomic-hi-lo.h

Re: [PATCH] asm-generic: remove old nonatomic-io wrapper files

2016-02-29 Thread Yisen Zhuang
| 2 +- > drivers/net/ethernet/hisilicon/hns/hns_dsaf_xgmac.c | 2 +- The HNS portion: Acked-by: Yisen Zhuang > drivers/net/ethernet/netronome/nfp/nfp_net.h| 2 +- > include/asm-generic/io-64-nonatomic-hi-lo.h | 2 -- > include/asm-generic/io-64-nonatomic-

Re: [PATCH] net: hns: avoid uninitialized variable warning:

2016-01-05 Thread Yisen Zhuang
在 2016/1/2 6:27, Arnd Bergmann 写道: > gcc fails to see that the use of the 'last_offset' variable > in hns_nic_reuse_page() is used correctly and issues a bogus > warning: > > drivers/net/ethernet/hisilicon/hns/hns_enet.c: In function > 'hns_nic_reuse_page': >

Re: [PATCH] net: hns: avoid uninitialized variable warning:

2016-01-05 Thread Yisen Zhuang
在 2016/1/2 6:27, Arnd Bergmann 写道: > gcc fails to see that the use of the 'last_offset' variable > in hns_nic_reuse_page() is used correctly and issues a bogus > warning: > > drivers/net/ethernet/hisilicon/hns/hns_enet.c: In function > 'hns_nic_reuse_page': >

<    1   2   3