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


Groups > linux.kernel > #1256591 > unrolled thread

[PATCH] net: hns: fixes the bug tested XGE by ethtool -p

Started byyankejian <yankejian@huawei.com>
First post2015-10-27 10:10 +0100
Last post2015-10-28 04:00 +0100
Articles 2 — 2 participants

Back to article view | Back to linux.kernel


Contents

  [PATCH] net: hns: fixes the bug tested XGE by ethtool -p yankejian <yankejian@huawei.com> - 2015-10-27 10:10 +0100
    Re: [PATCH] net: hns: fixes the bug tested XGE by ethtool -p David Miller <davem@davemloft.net> - 2015-10-28 04:00 +0100

#1256591 — [PATCH] net: hns: fixes the bug tested XGE by ethtool -p

Fromyankejian <yankejian@huawei.com>
Date2015-10-27 10:10 +0100
Subject[PATCH] net: hns: fixes the bug tested XGE by ethtool -p
Message-ID<qo8qu-3ms-9@gated-at.bofh.it>
From: Li Peng <lipeng321@huawei.com>

delete action of ETHTOOL_ID_ON/ETHTOOL_ID_OFF in XGE ethtool -p,
so Hardware control the LED state instead of software.

Signed-off-by: Li Peng <lipeng321@huawei.com>
Signed-off-by: Yisen Zhuang <yisen.zhuang@huawei.com>
Signed-off-by: yankejian <yankejian@huawei.com>
---
 drivers/net/ethernet/hisilicon/hns/hns_dsaf_misc.c | 9 +--------
 1 file changed, 1 insertion(+), 8 deletions(-)

diff --git a/drivers/net/ethernet/hisilicon/hns/hns_dsaf_misc.c b/drivers/net/ethernet/hisilicon/hns/hns_dsaf_misc.c
index d611388..523e9b8 100644
--- a/drivers/net/ethernet/hisilicon/hns/hns_dsaf_misc.c
+++ b/drivers/net/ethernet/hisilicon/hns/hns_dsaf_misc.c
@@ -64,17 +64,10 @@ int cpld_set_led_id(struct hns_mac_cb *mac_cb,
 	switch (status) {
 	case HNAE_LED_ACTIVE:
 		mac_cb->cpld_led_value = dsaf_read_b(mac_cb->cpld_vaddr);
-		return 2;
-	case HNAE_LED_ON:
 		dsaf_set_bit(mac_cb->cpld_led_value, DSAF_LED_ANCHOR_B,
 			     CPLD_LED_ON_VALUE);
 		dsaf_write_b(mac_cb->cpld_vaddr, mac_cb->cpld_led_value);
-		break;
-	case HNAE_LED_OFF:
-		dsaf_set_bit(mac_cb->cpld_led_value, DSAF_LED_ANCHOR_B,
-			     CPLD_LED_DEFAULT_VALUE);
-		dsaf_write_b(mac_cb->cpld_vaddr, mac_cb->cpld_led_value);
-		break;
+		return 2;
 	case HNAE_LED_INACTIVE:
 		dsaf_set_bit(mac_cb->cpld_led_value, DSAF_LED_ANCHOR_B,
 			     CPLD_LED_DEFAULT_VALUE);
-- 
1.9.1

--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

[toc] | [next] | [standalone]


#1257616

FromDavid Miller <davem@davemloft.net>
Date2015-10-28 04:00 +0100
Message-ID<qop7X-57O-3@gated-at.bofh.it>
In reply to#1256591
From: yankejian <yankejian@huawei.com>
Date: Tue, 27 Oct 2015 17:17:40 +0800

> From: Li Peng <lipeng321@huawei.com>
> 
> delete action of ETHTOOL_ID_ON/ETHTOOL_ID_OFF in XGE ethtool -p,
> so Hardware control the LED state instead of software.
> 
> Signed-off-by: Li Peng <lipeng321@huawei.com>
> Signed-off-by: Yisen Zhuang <yisen.zhuang@huawei.com>
> Signed-off-by: yankejian <yankejian@huawei.com>

Applied.
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

[toc] | [prev] | [standalone]


Back to top | Article view | linux.kernel


csiph-web