1 Star 0 Fork 76

叶青龙/dpdk

forked from src-openEuler/dpdk 
加入 Gitee
与超过 1200万 开发者一起发现、参与优秀开源项目,私有仓库也完全免费 :)
免费加入
文件
该仓库未声明开源许可证文件(LICENSE),使用请关注具体项目描述及其代码上游依赖。
克隆/下载
0301-net-hns3-fix-RTC-time-after-reset.patch 1.36 KB
一键复制 编辑 原始数据 按行查看 历史
chenjiji09 提交于 2023-06-05 14:20 . net/hns3: fix Rx ring mbuf leakage
From 974c06500687f166870e57a998fcdbb82f5d3628 Mon Sep 17 00:00:00 2001
From: Huisong Li <[email protected]>
Date: Fri, 2 Jun 2023 19:41:56 +0800
Subject: net/hns3: fix RTC time after reset
[ upstream commit 0335c1f3c43a7da75fe5e2ab7bac0422cfad99e3 ]
The enabled status of RTC time will be cleared after global
or IMP reset, which cause the local RTC time doesn't work.
So this patch fix it.
Fixes: 38b539d96eb6 ("net/hns3: support IEEE 1588 PTP")
Signed-off-by: Huisong Li <[email protected]>
Signed-off-by: Dongdong Liu <[email protected]>
---
drivers/net/hns3/hns3_ethdev.c | 10 ++++++----
1 file changed, 6 insertions(+), 4 deletions(-)
diff --git a/drivers/net/hns3/hns3_ethdev.c b/drivers/net/hns3/hns3_ethdev.c
index d6214415b7..cecf6929f7 100644
--- a/drivers/net/hns3/hns3_ethdev.c
+++ b/drivers/net/hns3/hns3_ethdev.c
@@ -4416,6 +4416,12 @@ hns3_init_hardware(struct hns3_adapter *hns)
goto err_mac_init;
}
+ ret = hns3_ptp_init(hw);
+ if (ret) {
+ PMD_INIT_LOG(ERR, "Failed to init PTP, ret = %d", ret);
+ goto err_mac_init;
+ }
+
return 0;
err_mac_init:
@@ -4577,10 +4583,6 @@ hns3_init_pf(struct rte_eth_dev *eth_dev)
goto err_intr_callback_register;
}
- ret = hns3_ptp_init(hw);
- if (ret)
- goto err_get_config;
-
/* Enable interrupt */
rte_intr_enable(pci_dev->intr_handle);
hns3_pf_enable_irq0(hw);
--
2.23.0
Loading...
马建仓 AI 助手
尝试更多
代码解读
代码找茬
代码优化
1
https://gitee.com/yeqinglong01/dpdk.git
[email protected]:yeqinglong01/dpdk.git
yeqinglong01
dpdk
dpdk
master

搜索帮助