Björn Svensson
c4dfb94e98
Use GNUC atomics from GCC 4.9
...
GCC began to offer full support for the C11 standard starting with version 4.9,
including support for the _Atomic keyword.
https://gcc.gnu.org/gcc-4.9/changes.html
2024-10-15 12:04:54 +08:00
Björn Svensson
486200e57f
Fix issue in Freebsd when building with GCC 14.1.0
...
Since GCC 14 now implements `__has_extension()` the build started to use
Clang atomics, i.e. the `__c11_*` APIs only provided by Clang.
Fix build to use GNUC atomics and include the upstream patch:
https://reviews.freebsd.org/D16585
which enables C11 atomics when building with GCC >= 4.7.
2024-10-15 11:53:03 +08:00
fengbojiang
473c99d77e
Fix ff tools build error with gcc-13.2.0.
2024-10-12 21:09:39 +08:00
wenchengji
306b685796
Update kern_event.c
...
modify gcc build error
2024-05-30 23:37:56 +08:00
wenchengji
89ec8d70e5
Merge branch 'F-Stack:dev' into dev
2024-05-28 22:54:01 +08:00
wenchengji
880fddc324
Update kern_event.c
...
Change the code style guide.
2024-05-23 23:03:49 +08:00
wenchengji
3a242c1379
For f-stack to support QAT accelerator cards.
2024-05-23 14:52:25 +00:00
fengbojiang
5de047f19a
Fiexd some build errors of freebsd with gcc-12.2.0.
2023-10-19 15:57:24 +08:00
fengbojiang
8e683b405b
Add atomic_fcmpset_int32 and some comments.
...
Because `atomic_fcmpset_int` maybe run not correctly sometimes, and then loop long time, But no reason found yet.
2023-09-15 15:19:08 +08:00
fengbojiang
2157bebab6
Add FSTACK define in if_gre.h.
2023-08-29 16:21:37 +08:00
fengbojiang
2f169245d3
Fiexd some build errors of ipfw on ubuntu 22.04 (kernel:5.19.0-1025, gcc:11.4.0),
...
Ref #777 .
2023-08-14 20:45:10 +08:00
wenchengji
fd994c50c8
Merge branch 'F-Stack:dev' into dev
2023-03-24 18:19:20 +08:00
wenchengji
e12daec8ec
When entering the softclock function for the first time,ticks is 2147423648,cc_softticks is 0.
...
Approximately 30 seconds later, ticks and cc_softticks become equal, allowing the while loop to be exited.
2023-03-24 09:56:31 +00:00
fengbojiang
c35e5fda17
Fix Compile Error with gcc 11.3.0(in Ubuntu 22.04). Close #736 .
2023-02-16 15:14:27 +08:00
wenchengji
0f015b3f5d
when nginx use setsockopt ON_LINGER, the seq number of the RST packet is error.
...
Use tcpdump to capture packets and you will find the problem.
See:https://reviews.freebsd.org/D30036 .
2023-01-09 06:51:16 +00:00
fengbojiang
3c7b637d18
tcp: Missing mfree in rack and bbr.
...
See:https://reviews.freebsd.org/D30727 .
2023-01-06 10:35:50 +08:00
fengbojiang
a816e89636
Fix #702 F-stack rack and BBR both causes PCB memory leak.
...
Because `net.inet.tcp.hpts.skip_swi=1` takes effect after
`mi_startup()` in `ff_freebsd_init()`.
2023-01-06 04:10:02 +08:00
renzibei
fb832ef92f
delete useless comments in last commit
2022-12-01 22:12:33 +00:00
renzibei
7fe40f937e
make it compilable under O2 optimization, pass gcc check
2022-12-01 22:02:45 +00:00
fengbojiang
ff8fd2bdc7
Merge branch 'dev'
2022-09-02 16:51:22 +08:00
fengbojiang
021aaded2c
Support zero copy while call `ff_write`, you can enable it by modify ‘FF_ZC_SEND=1' in `lib/Makefile`.
...
`FF_ZC_SEND` is same as `FF_USE_PAGE_ARRAY`, it will improve performance slightly in some scenarios, need to be tested in combination with real applications.
You can enable both compilation options at the same time or separately.
2022-05-07 12:02:49 +08:00
fengbojiang
e12886c02c
Support zero copy while call `ff_write`, you can enable it by modify ‘FF_ZC_SEND=1' in `lib/Makefile`.
...
`FF_ZC_SEND` is same as `FF_USE_PAGE_ARRAY`, it will improve performance slightly in some scenarios, need to be tested in combination with real applications.
You can enable both compilation options at the same time or separately.
2022-04-15 18:00:49 +08:00
fengbojiang
7dba406844
Fix #643 . Fix a VXLAN issue. Thanks @agerguo
2022-02-26 21:28:12 +08:00
fengbojiang
da4b496cab
Netgraph and ipfw for FreeBSD 13.0.
2021-10-12 18:59:42 +08:00
fengbojiang
21cfeb4372
Support extra tcp stacks, rack and bbr.
2021-09-23 15:16:09 +08:00
fengbojiang
8fe2bf87f3
FreeBSD13 can simply work.
2021-09-18 14:50:06 +08:00
fengbojiang
63f0426fdf
fix some issues.
2021-09-16 15:30:22 +08:00
fengbojiang
e7b7fb6cc9
FreeBSD: Upgrade to FreeBSD-releng-13.0 compiled, to be tested.
2021-08-31 19:00:09 +08:00
fengbojiang(姜凤波)
cddb7cd030
Add `ff_regist_pcblddr_fun` to regist a pcb lddr function in F-Stack.
...
If There are multiple ips, and F-Stack client application can choose a source ip by yourself, instead always use the first ip.
2021-03-06 19:18:52 +08:00
fengbojiang(姜凤波)
1ddd0f0898
Add `ff_regist_pcblddr_fun` to regist a pcb lddr function in F-Stack.
...
If There are multiple ips, and F-Stack client application can choose a source ip by yourself, instead always use the first ip.
2021-03-06 19:04:46 +08:00
fengbojiang(姜凤波)
5212857100
ICMPv6 / MLDv2 out-of-bounds memory access.
...
Corresponding upstream changeset from
https://www.freebsd.org/security/advisories/FreeBSD-SA-19:19.mldv2.asc .
2019-11-22 23:03:52 +08:00
fengbojiang(姜凤波)
a823ae8156
ICMPv6 / MLDv2 out-of-bounds memory access.
...
Corresponding upstream changeset from
https://www.freebsd.org/security/advisories/FreeBSD-SA-19:19.mldv2.asc .
2019-11-22 23:03:52 +08:00
fengbojiang(姜凤波)
0e148a1207
Denial of service in listen system call.
...
Corresponding upstream changeset from
https://www.freebsd.org/security/advisories/FreeBSD-EN-18:11.listen.asc .
Refer: #329 .
2019-11-22 22:07:47 +08:00
fengbojiang(姜凤波)
6757379bb8
Denial of service in listen system call.
...
Corresponding upstream changeset from
https://www.freebsd.org/security/advisories/FreeBSD-EN-18:11.listen.asc .
Refer: #329 .
2019-11-22 22:07:47 +08:00
fengbojiang(姜凤波)
c476ff78a9
Resource exhaustion in IP fragment reassembly.
...
Corresponding upstream changeset from
https://www.freebsd.org/security/advisories/FreeBSD-SA-18:10.ip.asc .
2019-11-22 21:06:30 +08:00
fengbojiang(姜凤波)
2d72fc9054
Resource exhaustion in IP fragment reassembly.
...
Corresponding upstream changeset from
https://www.freebsd.org/security/advisories/FreeBSD-SA-18:10.ip.asc .
2019-11-22 21:06:30 +08:00
fengbojiang(姜凤波)
30c2a48ca1
Resource exhaustion in TCP reassembly.
...
Corresponding upstream changeset from
https://www.freebsd.org/security/advisories/FreeBSD-SA-18:08.tcp.asc .
2019-11-22 16:16:34 +08:00
fengbojiang(姜凤波)
a98418af32
Resource exhaustion in TCP reassembly.
...
Corresponding upstream changeset from
https://www.freebsd.org/security/advisories/FreeBSD-SA-18:08.tcp.asc .
2019-11-22 16:16:34 +08:00
fengbojiang(姜凤波)
b4eda9868a
The icmp6(4) protocol has been updated to fix ICMPv6 redirects.
...
Corresponding upstream changeset from https://svnweb.freebsd.org/base/stable/11/sys/netinet6/icmp6.c?r1=329581&r2=329580&pathrev=329581 .
2019-11-22 15:57:05 +08:00
fengbojiang(姜凤波)
007a5634b2
The icmp6(4) protocol has been updated to fix ICMPv6 redirects.
...
Corresponding upstream changeset from https://svnweb.freebsd.org/base/stable/11/sys/netinet6/icmp6.c?r1=329581&r2=329580&pathrev=329581 .
2019-11-22 15:57:05 +08:00
fengbojiang(姜凤波)
eb6df281b3
The disclosure in the TCP network stack was introduced in 11.0.
...
Corresponding upstream changeset from
https://www.freebsd.org/security/advisories/FreeBSD-EN-18:05.mem.asc .
2019-11-22 14:39:26 +08:00
fengbojiang(姜凤波)
da6a6342a9
The disclosure in the TCP network stack was introduced in 11.0.
...
Corresponding upstream changeset from
https://www.freebsd.org/security/advisories/FreeBSD-EN-18:05.mem.asc .
2019-11-22 14:39:26 +08:00
fengbojiang(姜凤波)
441d416594
Fix denial of service of ipsec.
...
Corresponding upstream changeset from
https://www.freebsd.org/security/advisories/FreeBSD-SA-18:05.ipsec.asc .
2019-11-22 12:33:19 +08:00
fengbojiang(姜凤波)
d0b1b30af0
Fix denial of service of ipsec.
...
Corresponding upstream changeset from
https://www.freebsd.org/security/advisories/FreeBSD-SA-18:05.ipsec.asc .
2019-11-22 12:33:19 +08:00
fengbojiang(姜凤波)
b6e183603d
The TCP stack has been changed to use the estimated RTT instead of timestamps for receive buffer auto resizing.
...
Corresponding upstream changeset from https://svnweb.freebsd.org/base?view=revision&revision=317368 .
2019-11-22 11:40:45 +08:00
fengbojiang(姜凤波)
04b1440d33
The TCP stack has been changed to use the estimated RTT instead of timestamps for receive buffer auto resizing.
...
Corresponding upstream changeset from https://svnweb.freebsd.org/base?view=revision&revision=317368 .
2019-11-22 11:40:45 +08:00
fengbojiang(姜凤波)
e1bffb8a14
The network stack has been modified to fix incorrect or invalid IP
...
addresses if multiple threads emit a UDP log_in_vain message
concurrently.
Corresponding upstream changeset from
https://svnweb.freebsd.org/base?view=revision&revision=313523 .
2019-11-21 16:57:10 +08:00
fengbojiang(姜凤波)
56d87bf891
The network stack has been modified to fix incorrect or invalid IP
...
addresses if multiple threads emit a UDP log_in_vain message
concurrently.
Corresponding upstream changeset from
https://svnweb.freebsd.org/base?view=revision&revision=313523 .
2019-11-21 16:57:10 +08:00
fengbojiang(姜凤波)
efd36ee293
The network stack has been updated to include ip6_tryforward(),
...
providing performance benefits as result of a reduced number of checks.
Corresponding upstream changeset from
https://svnweb.freebsd.org/base?view=revision&revision=311681 .
2019-11-21 16:42:24 +08:00
fengbojiang(姜凤波)
d6e6a7ee89
The network stack has been updated to include ip6_tryforward(),
...
providing performance benefits as result of a reduced number of checks.
Corresponding upstream changeset from
https://svnweb.freebsd.org/base?view=revision&revision=311681 .
2019-11-21 16:42:24 +08:00