Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
2301_76519099
rt-thread
提交
154d73a4
R
rt-thread
项目概览
2301_76519099
/
rt-thread
与 Fork 源项目一致
Fork自
RT-Thread / rt-thread
通知
3
Star
1
Fork
1
代码
文件
提交
分支
Tags
贡献者
分支图
Diff
Issue
0
列表
看板
标记
里程碑
合并请求
0
DevOps
流水线
流水线任务
计划
Wiki
0
Wiki
分析
仓库
DevOps
项目成员
Pages
R
rt-thread
项目概览
项目概览
详情
发布
仓库
仓库
文件
提交
分支
标签
贡献者
分支图
比较
Issue
0
Issue
0
列表
看板
标记
里程碑
合并请求
0
合并请求
0
Pages
DevOps
DevOps
流水线
流水线任务
计划
分析
分析
仓库分析
DevOps
Wiki
0
Wiki
成员
成员
收起侧边栏
关闭侧边栏
动态
分支图
创建新Issue
流水线任务
提交
Issue看板
体验新版 GitCode,发现更多精彩内容 >>
提交
154d73a4
编写于
3月 31, 2021
作者:
L
liuxianliang
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
[fix] iperf speed test have been stable.
上级
6d89a9f1
变更
6
隐藏空白更改
内联
并排
Showing
6 changed file
with
39 addition
and
15 deletion
+39
-15
components/net/lwip-1.4.1/src/include/netif/ethernetif.h
components/net/lwip-1.4.1/src/include/netif/ethernetif.h
+1
-0
components/net/lwip-1.4.1/src/netif/ethernetif.c
components/net/lwip-1.4.1/src/netif/ethernetif.c
+12
-5
components/net/lwip-2.0.2/src/include/netif/ethernetif.h
components/net/lwip-2.0.2/src/include/netif/ethernetif.h
+1
-0
components/net/lwip-2.0.2/src/netif/ethernetif.c
components/net/lwip-2.0.2/src/netif/ethernetif.c
+12
-5
components/net/lwip-2.1.2/src/include/netif/ethernetif.h
components/net/lwip-2.1.2/src/include/netif/ethernetif.h
+1
-0
components/net/lwip-2.1.2/src/netif/ethernetif.c
components/net/lwip-2.1.2/src/netif/ethernetif.c
+12
-5
未找到文件。
components/net/lwip-1.4.1/src/include/netif/ethernetif.h
浏览文件 @
154d73a4
...
...
@@ -27,6 +27,7 @@ struct eth_device
rt_uint16_t
flags
;
rt_uint8_t
link_changed
;
rt_uint8_t
link_status
;
rt_uint8_t
rx_notice
;
/* avoid send the same mail to mailbox */
/* eth device interface */
struct
pbuf
*
(
*
eth_rx
)(
rt_device_t
dev
);
...
...
components/net/lwip-1.4.1/src/netif/ethernetif.c
浏览文件 @
154d73a4
...
...
@@ -550,10 +550,16 @@ rt_err_t eth_device_init(struct eth_device * dev, const char *name)
rt_err_t
eth_device_ready
(
struct
eth_device
*
dev
)
{
if
(
dev
->
netif
)
{
if
(
dev
->
rx_notice
==
RT_FALSE
)
{
dev
->
rx_notice
=
RT_TRUE
;
return
rt_mb_send
(
&
eth_rx_thread_mb
,
(
rt_uint32_t
)
dev
);
}
/* post message to Ethernet thread */
return
rt_mb_send
(
&
eth_rx_thread_mb
,
(
rt_uint32_t
)
dev
);
else
return
ERR_OK
;
/* netif is not initialized yet, just return. */
}
return
ERR_OK
;
/* netif is not initialized yet, just return. */
}
rt_err_t
eth_device_linkchange
(
struct
eth_device
*
dev
,
rt_bool_t
up
)
...
...
@@ -646,9 +652,10 @@ static void eth_rx_thread_entry(void* parameter)
else
netifapi_netif_set_link_down
(
device
->
netif
);
}
device
->
rx_notice
=
RT_FALSE
;
/* receive all of buffer */
do
while
(
1
)
{
if
(
device
->
eth_rx
==
RT_NULL
)
break
;
...
...
@@ -664,7 +671,7 @@ static void eth_rx_thread_entry(void* parameter)
}
}
else
break
;
}
while
(
rt_mb_recv
(
&
eth_rx_thread_mb
,
(
rt_ubase_t
*
)
&
device
,
RT_WAITING_NO
)
==
RT_EOK
);
}
}
else
{
...
...
components/net/lwip-2.0.2/src/include/netif/ethernetif.h
浏览文件 @
154d73a4
...
...
@@ -27,6 +27,7 @@ struct eth_device
rt_uint16_t
flags
;
rt_uint8_t
link_changed
;
rt_uint8_t
link_status
;
rt_uint8_t
rx_notice
;
/* avoid send the same mail to mailbox */
/* eth device interface */
struct
pbuf
*
(
*
eth_rx
)(
rt_device_t
dev
);
...
...
components/net/lwip-2.0.2/src/netif/ethernetif.c
浏览文件 @
154d73a4
...
...
@@ -599,10 +599,16 @@ void eth_device_deinit(struct eth_device *dev)
rt_err_t
eth_device_ready
(
struct
eth_device
*
dev
)
{
if
(
dev
->
netif
)
{
if
(
dev
->
rx_notice
==
RT_FALSE
)
{
dev
->
rx_notice
=
RT_TRUE
;
return
rt_mb_send
(
&
eth_rx_thread_mb
,
(
rt_uint32_t
)
dev
);
}
/* post message to Ethernet thread */
return
rt_mb_send
(
&
eth_rx_thread_mb
,
(
rt_ubase_t
)
dev
);
else
return
ERR_OK
;
/* netif is not initialized yet, just return. */
}
return
ERR_OK
;
/* netif is not initialized yet, just return. */
}
rt_err_t
eth_device_linkchange
(
struct
eth_device
*
dev
,
rt_bool_t
up
)
...
...
@@ -695,9 +701,10 @@ static void eth_rx_thread_entry(void* parameter)
else
netifapi_netif_set_link_down
(
device
->
netif
);
}
device
->
rx_notice
=
RT_FALSE
;
/* receive all of buffer */
do
while
(
1
)
{
if
(
device
->
eth_rx
==
RT_NULL
)
break
;
...
...
@@ -713,7 +720,7 @@ static void eth_rx_thread_entry(void* parameter)
}
}
else
break
;
}
while
(
rt_mb_recv
(
&
eth_rx_thread_mb
,
(
rt_ubase_t
*
)
&
device
,
RT_WAITING_NO
)
==
RT_EOK
);
}
}
else
{
...
...
components/net/lwip-2.1.2/src/include/netif/ethernetif.h
浏览文件 @
154d73a4
...
...
@@ -27,6 +27,7 @@ struct eth_device
rt_uint16_t
flags
;
rt_uint8_t
link_changed
;
rt_uint8_t
link_status
;
rt_uint8_t
rx_notice
;
/* avoid send the same mail to mailbox */
/* eth device interface */
struct
pbuf
*
(
*
eth_rx
)(
rt_device_t
dev
);
...
...
components/net/lwip-2.1.2/src/netif/ethernetif.c
浏览文件 @
154d73a4
...
...
@@ -601,10 +601,16 @@ void eth_device_deinit(struct eth_device *dev)
rt_err_t
eth_device_ready
(
struct
eth_device
*
dev
)
{
if
(
dev
->
netif
)
{
if
(
dev
->
rx_notice
==
RT_FALSE
)
{
dev
->
rx_notice
=
RT_TRUE
;
return
rt_mb_send
(
&
eth_rx_thread_mb
,
(
rt_uint32_t
)
dev
);
}
/* post message to Ethernet thread */
return
rt_mb_send
(
&
eth_rx_thread_mb
,
(
rt_uint32_t
)
dev
);
else
return
ERR_OK
;
/* netif is not initialized yet, just return. */
}
return
ERR_OK
;
/* netif is not initialized yet, just return. */
}
rt_err_t
eth_device_linkchange
(
struct
eth_device
*
dev
,
rt_bool_t
up
)
...
...
@@ -697,9 +703,10 @@ static void eth_rx_thread_entry(void* parameter)
else
netifapi_netif_set_link_down
(
device
->
netif
);
}
device
->
rx_notice
=
RT_FALSE
;
/* receive all of buffer */
do
while
(
1
)
{
if
(
device
->
eth_rx
==
RT_NULL
)
break
;
...
...
@@ -715,7 +722,7 @@ static void eth_rx_thread_entry(void* parameter)
}
}
else
break
;
}
while
(
rt_mb_recv
(
&
eth_rx_thread_mb
,
(
rt_ubase_t
*
)
&
device
,
RT_WAITING_NO
)
==
RT_EOK
);
}
}
else
{
...
...
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录