tb [Tue, 20 Feb 2024 14:58:16 +0000 (14:58 +0000)]
x509_asid: NULL out min/max on extract_min_max() failure
requested by/ok jsing
martijn [Tue, 20 Feb 2024 12:51:10 +0000 (12:51 +0000)]
Remove some now unused variables. Somehow missed in previous commit.
martijn [Tue, 20 Feb 2024 12:41:13 +0000 (12:41 +0000)]
strptime() only touches the fields specified in the format string,
meaning there could be garbage left in the other fields. Somehow this
only caused issues in mktime() when /etc/localtime is set to GMT.
Initialize tm to 0.
While here fix a type-O in the format string and make the invalid
strlen for LAST-UPDATED message more consistent with the other 2 error
messages.
Found by and OK sthen@
martijn [Tue, 20 Feb 2024 12:32:48 +0000 (12:32 +0000)]
trap receiver is special in that the OID is optional. Make sure that we
accept a NULL descriptor, which results in an OID length of 0.
Found by and OK sthen@
martijn [Tue, 20 Feb 2024 12:25:43 +0000 (12:25 +0000)]
Remove the packetid logic from ax.c. It's not used by snmpd and has some
serious flaws.
Issue reported and analysis by Steffen Christgau.
OK tb@
stsp [Tue, 20 Feb 2024 11:48:19 +0000 (11:48 +0000)]
implement disassociation (RUN->AUTH/INIT) in the qwx(4) driver state machine
stsp [Tue, 20 Feb 2024 11:44:15 +0000 (11:44 +0000)]
implement qwx_dp_reo_cmd_list_cleanup()
stsp [Tue, 20 Feb 2024 11:42:36 +0000 (11:42 +0000)]
fix a double-free in qwx(4) that occurred when removing a peer from firmware
It was not yet possible to hit this code path outside of an error path.
But upcoming changes would easily trigger this and crash the kernel.
claudio [Tue, 20 Feb 2024 10:37:35 +0000 (10:37 +0000)]
Include the test pattern that resulted in an infinite loop before
rmatch.c rev 1.4.
claudio [Tue, 20 Feb 2024 10:36:23 +0000 (10:36 +0000)]
Add missing check for the case where the pattern hits a barrier before
the string is consumed as well. Right now a string of 'dir1/' and a
pattern of 'dir/' will result in an infinite loop because matchsub()
would return success but then would not move forward.
Report and diff from Kyle Evans (kevans FreeBSD.org)
OK tb@
claudio [Tue, 20 Feb 2024 09:42:49 +0000 (09:42 +0000)]
Add rsync-unit
claudio [Tue, 20 Feb 2024 09:40:58 +0000 (09:40 +0000)]
Add a unit test for rsync special rmatch() function.
One pattern is currently disabled since it results in an infinite loop.
Fix for that is on the way.
jsg [Tue, 20 Feb 2024 08:06:19 +0000 (08:06 +0000)]
drm/i915/pxp/mtl: Update pxp-firmware response timeout
From Alan Previn
8ae272348153ed2fa423f739047a592d9bd55ba2 in mainline linux
Fixes a LG UltraFine 5K display not lighting up on a Comet Lake machine.
Regression reported by Kirill A. Korinsky who tracked the problem down
to a timeout in pxp.
djm [Tue, 20 Feb 2024 04:10:03 +0000 (04:10 +0000)]
don't append a gratuitous space to the end of subsystem arguments;
bz3667
stsp [Mon, 19 Feb 2024 21:23:02 +0000 (21:23 +0000)]
Make bwfm(4) work with MAC addresses set via ifconfig lladdr.
Patch by Todd Carson
Tests by Todd Carson and naddy@
ok tobhe@
gilles [Mon, 19 Feb 2024 21:00:19 +0000 (21:00 +0000)]
no need to be as strict with table formats on various match constraints,
this prevents the reuse of T_HASH tables in T_LIST contexts when the key
column actually makes sense by itself.
diff from Philipp (philipp+openbsd [at] bureaucracy [dot] de)
claudio [Mon, 19 Feb 2024 16:39:18 +0000 (16:39 +0000)]
Fix a deadlock in openrsync when big files are synced using the hash
algorithm. Make sure the sender does not run ahead of itself and end
stalling in a read from network that never shows up. Instead ensure
that all queued data is pushed out before accepting new data.
Problem found by and fix developed with Kyle Evans (kevans freebsd.org)
OK tb@ deraadt@
denis [Mon, 19 Feb 2024 16:39:03 +0000 (16:39 +0000)]
use correct rtmsg member in sizeof()
OK miod@
tb [Mon, 19 Feb 2024 15:44:10 +0000 (15:44 +0000)]
x509_asid: fix some KNF botches
When this file was brought into KNF, a few things became particularly ugly.
This makes {a,b}{,_{min,max}} have function scope in canonize/is_canonical,
which removes unfortunate line wraps and some other silliness.
ok job
tb [Mon, 19 Feb 2024 15:37:44 +0000 (15:37 +0000)]
pk7_attr.c: tidy includes
kettenis [Mon, 19 Feb 2024 14:08:58 +0000 (14:08 +0000)]
Revert the change that enabled retpoline thunks by default. The use of
retpolines makes IBT less useful and we have enabled additional mitigations
in our kernel now that should make them (mostly) unnecessary.
ok guenther@
kettenis [Mon, 19 Feb 2024 14:05:01 +0000 (14:05 +0000)]
Remove "noretpolineplt" from the list of known -z flags. Missed in the
previous commit.
ok guenther@
kn [Mon, 19 Feb 2024 13:53:03 +0000 (13:53 +0000)]
Avoid passphrase in temporary file
bioctl(8) uses readpassphrase(3) RPP_REQUITE_TTY, so always pass stdin,
but only use it over TTY with -s in unattended mode.
Prodding afresh1 sthen
"much better" sthen
job [Mon, 19 Feb 2024 10:15:35 +0000 (10:15 +0000)]
IANA assigned error 8 to draft-ietf-idr-sendholdtimer
https://www.iana.org/assignments/bgp-parameters/bgp-parameters.xhtml#bgp-parameters-3
OK claudio@
claudio [Mon, 19 Feb 2024 09:59:29 +0000 (09:59 +0000)]
In cpu_fork() do not copy the register windows stashed in the u_pcb
if the new proc has its own stack. In that case the new thread starts
with a fresh stack and there are no register windows to spill back.
This fixes the pthread issues that kurt@ was struggling with for a long
time. Depending on the scheduler a thread would stomp over another threads
stack which caused strange crashes.
Improved diff provided by miod@
OK miod@ mpi@ kurt@
dtucker [Mon, 19 Feb 2024 09:25:52 +0000 (09:25 +0000)]
Always define puttysetup function.
jsg [Mon, 19 Feb 2024 05:36:55 +0000 (05:36 +0000)]
regen
jsg [Mon, 19 Feb 2024 05:36:17 +0000 (05:36 +0000)]
add more Intel device ids
more Raptor Lake host ids from:
13th Generation Intel Core and Intel Core 14th Generation Processors
Datasheet, Volume 1 of 2, Doc. No.: 743844, Rev.: 008
700 Series eSPI ids, from:
Intel 700 Series Chipset Family Platform Controller Hub
Datasheet, Volume 1 of 2, Doc. No.: 743835, Rev.: 003
C740 Series (Emmitsburg) PCH ids. No public docs could be found,
so based on dmesg of a Sapphire Rapids machine and EmmitsburgSystem.inf
kevlo [Mon, 19 Feb 2024 03:02:15 +0000 (03:02 +0000)]
regen
kevlo [Mon, 19 Feb 2024 03:00:37 +0000 (03:00 +0000)]
add Realtek 802.11ax ids
jsg [Mon, 19 Feb 2024 01:54:46 +0000 (01:54 +0000)]
drm/amd/display: Implement bounds check for stream encoder creation in DCN301
From Srinivasan Shanmugam
cd9bd10c59e3c1446680514fd3097c5b00d3712d in linux-6.6.y/6.6.17
58fca355ad37dcb5f785d9095db5f748b79c5dc2 in mainline linux
jsg [Mon, 19 Feb 2024 01:52:20 +0000 (01:52 +0000)]
drm/amd/display: Add NULL test for 'timing generator' in 'dcn21_set_pipe()'
From Srinivasan Shanmugam
3f3c237a706580326d3b7a1b97697e5031ca4667 in linux-6.6.y/6.6.17
66951d98d9bf45ba25acf37fe0747253fafdf298 in mainline linux
jsg [Mon, 19 Feb 2024 01:50:11 +0000 (01:50 +0000)]
drm/amd/display: Fix 'panel_cntl' could be null in 'dcn21_set_backlight_level()'
From Srinivasan Shanmugam
2e150ccea13129eb048679114808eb9770443e4d in linux-6.6.y/6.6.17
e96fddb32931d007db12b1fce9b5e8e4c080401b in mainline linux
jsg [Mon, 19 Feb 2024 01:48:23 +0000 (01:48 +0000)]
drm/i915/gvt: Fix uninitialized variable in handle_mmio()
From Dan Carpenter
41d5340cb01e1b076ae4d58cb91da9552bac64c4 in linux-6.6.y/6.6.17
47caa96478b99d6d1199b89467cc3e5a6cc754ee in mainline linux
tb [Sun, 18 Feb 2024 22:17:01 +0000 (22:17 +0000)]
asn1time: remove some debugging code
miod [Sun, 18 Feb 2024 21:27:38 +0000 (21:27 +0000)]
Fix format strings in TRAPDEBUG code and unbreak 88110_syscall. NFC
anton [Sun, 18 Feb 2024 20:17:48 +0000 (20:17 +0000)]
Prevent ioctl(WSKBDIO_GETENCODINGS) NULL deference when sysctl
machdep.forceukbd is enabled without any USB keyboard being attached.
Found the hard way by sthen@; ok miod@
tb [Sun, 18 Feb 2024 17:20:51 +0000 (17:20 +0000)]
sync
tb [Sun, 18 Feb 2024 17:13:29 +0000 (17:13 +0000)]
Tweak previous
tb [Sun, 18 Feb 2024 16:56:33 +0000 (16:56 +0000)]
Adjust regress test for memset() requested by jsing on review
tb [Sun, 18 Feb 2024 16:32:29 +0000 (16:32 +0000)]
Add regress coverage for the new API
This exercises the new API, in particular with respect to overflow behavior
around the years 0/9999, which are special for GeneralizedTime/X.509.
tb [Sun, 18 Feb 2024 16:30:17 +0000 (16:30 +0000)]
Update ASN1_TIME_set(3)
Document OPENSSL_{posix_to_tm,tm_to_posix}() and fix the documentation of
OPENSSL_{gmtime,timegm}().
ok jsing
tb [Sun, 18 Feb 2024 16:28:37 +0000 (16:28 +0000)]
Add posix_time.h from BoringSSL
This is prepares to expose some internal API as OPENSSL_tm_to_posix() and
OPENSSL_posix_to_tm(). They will be used in libtls and ocspcheck(8) to get
rid of the portability nightmare that is timegm().
Also fix the location of OPENSSL_gmtime() and OPENSSL_timegm() (this API
is not yet exposed). The former is from OpenSSL and surprisingly lives in
crypto.h, not asn1.h, and the latter is BoringSSL API and lives in the new
posix_time.h.
Initial diff from beck, this pulls in further upstream work after review
feedback.
ok jsing
tb [Sun, 18 Feb 2024 15:53:54 +0000 (15:53 +0000)]
Align EVP_CIPHER_CTX_init() and _legacy_clear()
tb [Sun, 18 Feb 2024 15:47:48 +0000 (15:47 +0000)]
Hide EVP_{CIPHER,MD}_CTX_init() from internals
ok jsing
tb [Sun, 18 Feb 2024 15:45:42 +0000 (15:45 +0000)]
Use EVP_MD_CTX_legacy_clear() internally
ok jsing
tb [Sun, 18 Feb 2024 15:44:10 +0000 (15:44 +0000)]
Use EVP_CIPHER_CTX_legacy_clear() internally
ok jsing
tb [Sun, 18 Feb 2024 15:43:21 +0000 (15:43 +0000)]
Add EVP_MD_CTX_legacy_clear()
This is analogous to EVP_CIPHER_CTX_legacy_clear() and will serve as an
internal replacement for EVP_MD_CTX_init() until the conversion to heap
allocated ctx is completed. This way EVP_MD_CTX_init() can be changed to
match the OpenSSL 1.1 API.
ok jsing
tb [Sun, 18 Feb 2024 15:41:50 +0000 (15:41 +0000)]
Add EVP_CIPHER_CTX_legacy_clear()
OpenSSL 1.1 made EVP_CIPHER_CTX_init() an alias of EVP_CIPHER_CTX_reset().
In particular, it changed signature and it would no longer leak internal
state if used on an already used ctx. On the other hand, it can't be used
for ctx on the stack.
libcrypto still has a few ctx on the stack which will be converted to heap
allocated contexts at some point. Until this is completed, we will use
EVP_CIPHER_CTX_legacy_clear() internally, so that the public API can be
changed to match OpenSSL 1.1.
ok jsing
guenther [Sun, 18 Feb 2024 05:42:50 +0000 (05:42 +0000)]
Don't call cpu_ucode_apply() and cpu_tsx_disable() from cpu_attach()'s
CPU_ROLE_SP case: for cpu0 they are called earlier, from cpu_startup().
(APs call them from cpu_hatch())
ok deraadt@
cheloha [Sun, 18 Feb 2024 00:54:03 +0000 (00:54 +0000)]
dt(4): profile: remove clock interrupt staggering
Clock interrupt staggering makes profiling more expensive on average.
Remove it.
Thread: https://marc.info/?l=openbsd-tech&m=
170751016121770&w=2
ok mpi@
deraadt [Sun, 18 Feb 2024 00:02:52 +0000 (00:02 +0000)]
sync
naddy [Sat, 17 Feb 2024 23:33:52 +0000 (23:33 +0000)]
sync
naddy [Sat, 17 Feb 2024 22:33:06 +0000 (22:33 +0000)]
7.6 packages key
deraadt [Sat, 17 Feb 2024 16:28:08 +0000 (16:28 +0000)]
sync
deraadt [Sat, 17 Feb 2024 16:27:29 +0000 (16:27 +0000)]
delete old keys
deraadt [Sat, 17 Feb 2024 16:27:21 +0000 (16:27 +0000)]
add 7.6 base key, commiting myself to another 6 months
deraadt [Sat, 17 Feb 2024 16:13:24 +0000 (16:13 +0000)]
move to 7.5-beta
job [Sat, 17 Feb 2024 14:53:29 +0000 (14:53 +0000)]
Add 'Send Hold Timer expired' BGP Error code
OK deraadt@
jsing [Sat, 17 Feb 2024 14:29:07 +0000 (14:29 +0000)]
Use calloc() instead of malloc() in BIO_new().
ok tb@
kettenis [Sat, 17 Feb 2024 13:29:25 +0000 (13:29 +0000)]
Bindings for the rk3288/rk3328/rk3399 have landed in Linux and are being
adopted by U-Boot. So check for the new compatible strings. Leave the
old ones in place until we have U-Boot packages with update device trees.
ok phessler@, patrick@
kettenis [Sat, 17 Feb 2024 12:01:45 +0000 (12:01 +0000)]
Add JH7100 I2C clocks.
ok miod@, jsg@
phessler [Fri, 16 Feb 2024 22:46:07 +0000 (22:46 +0000)]
implement qwx_init_task(), which will reset the hardware when it gets
confused
OK stsp@
mglocker [Fri, 16 Feb 2024 22:30:54 +0000 (22:30 +0000)]
Re-introduce TSO support after we've implemented fixes for the two reported
issues:
1. Unaligned memory access panic on sparc64 -> Made ether_extract_headers()
memory alignment safe.
2. em(4) watchdog timeouts in conjunction with ix(4)/vlan(4) -> Fixed
RX/LRO packet size calculation used for TSO tagging in ix(4).
Extensive testing done by bluhm@ on amd64 and sparc64 based on different
chips.
Testing done on Hrvoje Popovskis ix(4)/em(4)/vlan(4) setup from where the
issue 2 was reported.
OK bluhm@
stsp [Fri, 16 Feb 2024 16:37:42 +0000 (16:37 +0000)]
improve PBL->SBL EE transition handling in preparation for qwx_init_task()
Use a custom work queue for all EE/MHI state transitions.
Running MHI state changes in the systq won't work while running the
qwx init recovery task from the same systq. The init task would wait
for a state change and time out (assuming the device had failed to load
firmware when all was well), then the MHI state change task would run.
For consistency, send wakeups for the initial PBL->SBL EE transition
from the MHI state change task rather than the interrupt handler.
This in-place wakeup was an early hack from before when state
transitions were handled properly.
tb [Fri, 16 Feb 2024 15:19:02 +0000 (15:19 +0000)]
Rename fn into fileName to avoid name clash
ok job
tb [Fri, 16 Feb 2024 15:18:08 +0000 (15:18 +0000)]
Rename fn into file to avoid clash in upcoming diff
ok job
tb [Fri, 16 Feb 2024 15:15:02 +0000 (15:15 +0000)]
Rename rsc into rsc_asn1
Should have been part of the previous commit.
ok job
tb [Fri, 16 Feb 2024 15:13:49 +0000 (15:13 +0000)]
Use _asn1 suffix for some aspa/mft/roa/rsc/tak
This would otherwie clash with an upcoming replacement of struct parse.
ok job
tb [Fri, 16 Feb 2024 14:48:47 +0000 (14:48 +0000)]
Remove struct parse from cert.c
This is one of those weird things that metastasized throughout the code
base. job is about to introduce the 9th incompatible copy of it. Enough
is enough. It doesn't help anything.
looks good to claudio
ok clang
jsing [Fri, 16 Feb 2024 14:40:18 +0000 (14:40 +0000)]
Inline and disable BIO_set().
BIO_set() is a dangerous function that cannot be used safely. Thankfully,
the only consumer is BIO_new(), hence inline the functionality and disable
the BIO_set() function (for complete removal in the near future).
ok tb@
jsing [Fri, 16 Feb 2024 14:27:43 +0000 (14:27 +0000)]
Use 'bio' more consistently for function arguments.
Rather than 'a' or 'b', use 'bio' more consistently - there are still some
more complex cases that have been left alone for now. Also use fewer
parentheses.
No change to generated assembly other than line numbers.
stsp [Fri, 16 Feb 2024 14:18:36 +0000 (14:18 +0000)]
fix qwx(4) not coming up on first try if firmware was missing from disk at boot
stsp [Fri, 16 Feb 2024 14:16:16 +0000 (14:16 +0000)]
remove high-level error messages that cause noise when qwx fw is missing
stsp [Fri, 16 Feb 2024 14:13:45 +0000 (14:13 +0000)]
prevent memory leaks from duplicate/spurious qwx(4) fw memory requests
The request_mem_indication event handler would always allocate a new
buffer to store the firmware's request, potentially leaking an already
existing copy. Ensure that this buffer is always freed, and avoid
allocating it in the first place if we're not currently expecting this
event to occur.
All this would have surfaced the previously fixed bug with the missing
wakeup much earlier. The wakeup was always missed but when the driver
retried it would find the stale buffer from the previous event and not
even enter tsleep.
tb [Fri, 16 Feb 2024 11:55:42 +0000 (11:55 +0000)]
fix whitespace
tb [Fri, 16 Feb 2024 11:46:57 +0000 (11:46 +0000)]
Zap extra ;
stsp [Fri, 16 Feb 2024 11:44:52 +0000 (11:44 +0000)]
Fix wrong ifmedia check in intel wifi drivers.
IFM_AUTO is a media sub-type, not a media mode.
Should fix issues where only a subset of channels were scanned.
Tested:
iwm 8260: millert@
iwm 8265: mglocker@
iwm 9560: gnezdo@
iwx ax200: jmc@
iwx ax210: spiros thanasoulas
iwx ax211: kn@
phessler [Fri, 16 Feb 2024 09:03:29 +0000 (09:03 +0000)]
start moving some developmental printfs to be DEBUG DPRINTFs
requested and OK by stsp@
tb [Fri, 16 Feb 2024 06:09:36 +0000 (06:09 +0000)]
Make it explicit that the EC_KEY setters don't check things
While EC_POINT_set_affine_coordinates() checks that the resulting point
is on the elliptic curve, this is only necessary, but not sufficient, to
ensure that the point can serve as a valid public key. For example, this
does not check for normalized coordinates or exclude that it is zero (the
point at infinity). Such checks, and more, are performed by the similarly
named EC_KEY_set_public_key_affine_coordinates().
This kind of makes sense from the mathematical standpoint as an elliptic
curve point isn't a priori a public key, even if you are not going to use
libcrypto for actual mathematics (or anything really) unless you like pain.
In a cryptographic library such differences are more of a hazard than a
help.
This is exacerbated by the fact that EC_KEY_set_public_key() does almost
no checking (it only checks that the point's EC_POINT method matches the
one of group set of the EC_KEY, which is far from enough). The API expects
that you call EC_KEY_check_key() on your own. This is kind of confusing
since EC_KEY_set_public_key_affine_coordinates() does that for you.
Unfortunately, adding sanity checks to EC_KEY_set_public_key() isn't easy
since it's going to penalize those who already check. Caching the result
of a check is dangerous and fragile if there are a million ways of fiddling
with an EC_KEY.
While the elliptic curve code is really bad, its documentation is worse
(another thing that applies to OpenSSL in general). Try to help that a
little bit by making it more explicit that you are supposed to call
EC_KEY_check_key() after using lower-level EC_KEY setters. Also make it
clearer that the setters copy the data, they don't take ownership (which
isn't obvious from the naming).
If OpenSSL 3 got one thing kind of right, it was to deprecate the EC_KEY
and EC_POINT APIs. But if you are going to deprecate something, you should
either be prepared to remove it or have a reasonable replacement...
Found by Guido Vranken using cryptofuzz
https://bugs.chromium.org/p/oss-fuzz/issues/detail?id=66667
ok jsing
tb [Fri, 16 Feb 2024 05:18:29 +0000 (05:18 +0000)]
Factor SKI calculation into a helper
This is a straightforward deduplication and simplification made more
obvious by prior refactoring by job.
"sure" claudio
jsg [Fri, 16 Feb 2024 01:48:06 +0000 (01:48 +0000)]
New sentence, new line. Use .Pa for /etc/login.conf.
tobhe [Thu, 15 Feb 2024 20:10:45 +0000 (20:10 +0000)]
Introduce new IMSG_CTL_PROCREADY which is used to signal that all pipes
are set up by child processes. The parent sends a ping to all children
and only starts once it has received an acknowledgement from all of them.
This fixes a race condition on process startup when the parent starts
running before all children are ready.
From markus@
tobhe [Thu, 15 Feb 2024 19:11:00 +0000 (19:11 +0000)]
Delay enabling sockets until ikev2 process is ready.
from markus@
tobhe [Thu, 15 Feb 2024 19:04:12 +0000 (19:04 +0000)]
Remove unused control_socks queue.
from markus@
tedu [Thu, 15 Feb 2024 18:57:58 +0000 (18:57 +0000)]
change permit to be more bits away from deny, because rowhammer.
not really sure why this is our problem, but the diff is small.
ok deraadt millert miod
deraadt [Thu, 15 Feb 2024 16:33:54 +0000 (16:33 +0000)]
qwx(4) works well enough to enable
ok stsp
stsp [Thu, 15 Feb 2024 16:29:45 +0000 (16:29 +0000)]
fix wrong tsleep waiting address in qwx_qmi_mem_seg_send()
Fixes spurious "qwx0: failed to send qmi memory segments: -1" error with
associated lag during 'ifconfig qwx0 down up'
stsp [Thu, 15 Feb 2024 15:53:51 +0000 (15:53 +0000)]
make qwx(4) clean up ic_bss and set link down when moving into SCAN state
This matches what iwx(4) is doing.
jmc [Thu, 15 Feb 2024 15:42:57 +0000 (15:42 +0000)]
sort sections;
jmc [Thu, 15 Feb 2024 15:42:16 +0000 (15:42 +0000)]
sort the qwx(4) entry;
stsp [Thu, 15 Feb 2024 15:40:56 +0000 (15:40 +0000)]
fix wrong ifmedia macro used to check for IFM_AUTO
ok claudio@
deraadt [Thu, 15 Feb 2024 15:08:00 +0000 (15:08 +0000)]
sync
deraadt [Thu, 15 Feb 2024 15:07:55 +0000 (15:07 +0000)]
install & Xr
stsp [Thu, 15 Feb 2024 15:05:40 +0000 (15:05 +0000)]
some qwx(4) man page tweaks by me
stsp [Thu, 15 Feb 2024 15:05:18 +0000 (15:05 +0000)]
add an initial qwx(4) man page; written by mpi@ some time ago
jan [Thu, 15 Feb 2024 13:24:45 +0000 (13:24 +0000)]
vmx(4): Add TCP/UDP Checksum Offloading for IPv4/6
ok jmatthew@, bluhm@
stsp [Thu, 15 Feb 2024 11:57:38 +0000 (11:57 +0000)]
fix datapath Rx buffer management in qwx(4)
Fixes Tx/Rx stalls where the device ran out of free Rx buffers to use.
The device consumes buffers on the Rx refill ring out of order, which
the ring management code I wrote intially would not handle properly.
Instead of using an index into the ring where we would expect to see
a free slot which was in fact occupied, keep track of free buffers via
a bitmap.
mglocker [Thu, 15 Feb 2024 10:56:53 +0000 (10:56 +0000)]
Fix bogus packet length calculation in the RX/LRO path, which can lead to
TSO tagging forwarded packets which shouldn't. This will also fix the em(4)
watchdog timeouts seen after the em(4) TSO commit.
Thanks to Hrvoje Popovski for providing the infrastructure the reproduce
the issue, and test the fix.
Discussed with bluhm@. OK claudio@
tb [Thu, 15 Feb 2024 10:34:30 +0000 (10:34 +0000)]
BIO_dump*() avoid signed integer overflow
This API returns an int encoding the number of bytes printed. Thus, a dump
of a large enough byte string can make this overflow and rely on undefined
behavior. With an indent of 64, as little as 26 MB is enough to make this
happen.
ok jsing