OpenBSD cvs log

created 2022-12-25T09:08:33Z
begin 2022-12-22T00:00:00Z
end 2022-12-23T00:00:00Z
path src/sys
commits 5

date 2022-12-22T04:43:52Z
author dlg
files src/sys/net/toeplitz.h log diff annotate
message provide stoeplitz_n32()

date 2022-12-22T05:59:26Z
author dlg
files src/sys/conf/files log diff annotate
message use stoeplitz to generate a hash/flowid for state keys.

the hash will be used to partition work in pf and pfsync in the
future, and right now it is used as the first comparison in the rb
tree state lookup.

using stoeplitz means that pf will hash traffic the same way that
hardware using a stoeplitz key will hash incoming traffic on rings.
stoeplitz is also used by the tcp stack to generate a flow id, which
is used to pick which transmit ring is used on nics with multiple
queues too. using the same algorithm throughout the stack encourages
affinity of packets to rings and softnet threads the whole way
through.

using the hash as the first comparison in the state rb tree comparison
should encourage faster traversal of the state tree by having all
the address/port bits summarised into the single hash value. however,
tests by hrvoje popovski don't show performance changing. on the
plus side, if this change is free from a performance point of view
then it makes the future steps more straightforward.

discussed at length at h2k22
tested by sashan@ and hrvoje popovski
ok tb@ sashan@ claudio@ jmatthew@

date 2022-12-22T05:59:27Z
author dlg
files src/sys/net/pf.c log diff annotate
src/sys/net/pfvar.h log diff annotate
src/sys/net/pfvar_priv.h log diff annotate
message use stoeplitz to generate a hash/flowid for state keys.

the hash will be used to partition work in pf and pfsync in the
future, and right now it is used as the first comparison in the rb
tree state lookup.

using stoeplitz means that pf will hash traffic the same way that
hardware using a stoeplitz key will hash incoming traffic on rings.
stoeplitz is also used by the tcp stack to generate a flow id, which
is used to pick which transmit ring is used on nics with multiple
queues too. using the same algorithm throughout the stack encourages
affinity of packets to rings and softnet threads the whole way
through.

using the hash as the first comparison in the state rb tree comparison
should encourage faster traversal of the state tree by having all
the address/port bits summarised into the single hash value. however,
tests by hrvoje popovski don't show performance changing. on the
plus side, if this change is free from a performance point of view
then it makes the future steps more straightforward.

discussed at length at h2k22
tested by sashan@ and hrvoje popovski
ok tb@ sashan@ claudio@ jmatthew@

date 2022-12-22T15:44:02Z
author kettenis
files src/sys/arch/armv7/stand/efiboot/conf.c log diff annotate
src/sys/arch/armv7/stand/efiboot/efiboot.c log diff annotate
src/sys/arch/armv7/stand/efiboot/efiboot.h log diff annotate
message Bring over various changes from the arm64 version of this code.

ok patrick@

date 2022-12-22T19:51:11Z
author cheloha
files src/sys/arch/sparc64/sparc64/clock.c log diff annotate
src/sys/arch/sparc64/sparc64/locore.s log diff annotate
message sparc64: move retry logic out of stickcmpr_set()

In some cases, stickcmpr_set() fails to ensure that %STICK_CMPR leads
%STICK before returning to the caller. Rewriting the retry logic in C
trivially fixes the issue. So move the retry logic out into a new
function, stick_rearm().

Issue discovered by miod@, fix tested by miod@.

Link: https://marc.info/?l=openbsd-tech&m=167122933414238&w=2

ok kettenis@