zhhyu7 opened a new pull request, #17465:
URL: https://github.com/apache/nuttx/pull/17465

   ## Summary
   1. convert Kconfig to variable, upperhalf can supports multiple working 
modes at the same time, which is specified by NIC when register, the 
multi-network card scenario will be more flexible;
   2. add direct rx mode, avoid packet processing delays caused by task 
switching, to support those applications that are extremely time-sensitive;
   3. modify txavail to be sent directly in the current thread, avoid packet 
processing delays caused by task switching too.
   
   ## Impact
   All network card drivers implemented using ```struct netdev_lowerhalf_s```.
   It is necessary to initialize appropriate rxtype and priority according to 
the business scenario during network card initialization.
   
   ## Testing
   sim:matter with ping and iperf2.
   ```
   nsh> ifconfig
   eth0 Link encap:Ethernet HWaddr 42:00:d7:82:13:6b at RUNNING mtu 1500
        inet addr:10.0.1.2 DRaddr:10.0.0.1 Mask:255.255.255.0
        inet6 addr: 3380::4000:d7ff:fe82:136b/64
        inet6 DRaddr: fe80::a096:6ff:fe65:382a
   
   lo   Link encap:Local Loopback at RUNNING mtu 1518
        inet addr:127.0.0.1 DRaddr:127.0.0.1 Mask:255.0.0.0
        inet6 addr: ::1/128
        inet6 DRaddr: ::1
   
   nsh> ping -c 5 10.0.1.1
   PING 10.0.1.1 56 bytes of data
   56 bytes from 10.0.1.1: icmp_seq=0 time=0.0 ms
   56 bytes from 10.0.1.1: icmp_seq=1 time=0.0 ms
   56 bytes from 10.0.1.1: icmp_seq=2 time=0.0 ms
   56 bytes from 10.0.1.1: icmp_seq=3 time=0.0 ms
   56 bytes from 10.0.1.1: icmp_seq=4 time=0.0 ms
   5 packets transmitted, 5 received, 0% packet loss, time 5050 ms
   rtt min/avg/max/mdev = 0.000/0.000/0.000/0.000 ms
   nsh> ipe
     iperf
     iperf2
   nsh> iperf2 -c 10.0.1.1 -i 1 -t 5
   ------------------------------------------------------------
   Client connecting to 10.0.1.1, TCP port 5001
   TCP window size: 16.0 KByte
   ------------------------------------------------------------
   [  2] local 10.0.1.2 port 17206 connected with 10.0.1.1 port 5001
   [ ID] Interval       Transfer     Bandwidth
   [  2] 0.00-1.00 sec  49.1 MBytes   412 Mbits/sec
   [  2] 1.00-2.00 sec  49.2 MBytes   412 Mbits/sec
   [  2] 2.00-3.00 sec  48.8 MBytes   409 Mbits/sec
   [  2] 3.00-4.00 sec  49.8 MBytes   418 Mbits/sec
   [  2] 4.00-5.00 sec  51.6 MBytes   433 Mbits/sec
   [  2] 0.00-5.01 sec   249 MBytes   416 Mbits/sec
   nsh> 
   nsh> iperf2 -s -i 1 
   ------------------------------------------------------------
   Server listening on TCP port 5001
   TCP window size: 16.0 KByte
   ------------------------------------------------------------
   tcpnodelay failed: Unknown error 38
   [  3] local 10.0.1.2 port 5001 connected with 10.0.1.1 port 60610
   [ ID] Interval       Transfer     Bandwidth
   [  3] 0.00-1.00 sec  44.9 MBytes   377 Mbits/sec
   [  3] 1.00-2.00 sec  43.9 MBytes   368 Mbits/sec
   [  3] 2.00-3.00 sec  49.6 MBytes   416 Mbits/sec
   [  3] 3.00-4.00 sec  47.6 MBytes   399 Mbits/sec
   [  3] 4.00-5.00 sec  48.6 MBytes   407 Mbits/sec
   [  3] 0.00-5.00 sec   235 MBytes   394 Mbits/sec
   ```
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to