FreeBSD/src cd96657 — sys/dev/amdsmu amdsmu.c

amdsmu: Print how long system spent in S0i3

It's practical to have this printed out proactively, at least while this
is still very experimental.

Sponsored by:   The FreeBSD Foundation
DeltaFile
+5-1sys/dev/amdsmu/amdsmu.c
+5-11 files

FreeBSD/src 84f790e — sys/dev/wg if_wg.c, sys/net if_gre.c if_ovpn.c

ip_encap: Recompute flowid for packets received over tunnel

Packets decapsulated by a tunnel interface carry the NIC's flowid
computed over the outer tunnel tuple, which is the same for every
flow a peer carries. Therefore mpath nhop selection places all
traffic on one path.

Add encap_set_flowid() to ip_encap.c, which rehashes a decapsulated
IP packet on its inner addresses.

The feature is off by default and is enabled with the per-vnet
net.route.hash_inbound sysctl.

Reviewed by:    gallatin
Differential Revision:  https://reviews.freebsd.org/D60552
DeltaFile
+52-0sys/netinet/ip_encap.c
+7-0sys/netinet/ip_encap.h
+3-0sys/net/if_ovpn.c
+3-0sys/net/if_geneve.c
+3-0sys/dev/wg/if_wg.c
+2-0sys/net/if_gre.c
+70-01 files not shown
+72-07 files

FreeBSD/src 90c8c8e — sys/netinet in.h

netinet: garbage collect __IPPROTO_DIVERT
DeltaFile
+0-2sys/netinet/in.h
+0-21 files

FreeBSD/src a20bbab — sys/netpfil/ipfw ip_fw_private.h

ipfw: re-arrange declarations so that they match comments

No functional change.
DeltaFile
+9-8sys/netpfil/ipfw/ip_fw_private.h
+9-81 files

FreeBSD/src 0571d8a — sys/powerpc/powerpc swtch64.S swtch32.S

powerpc: Avoid deadlock when CPUs exchange threads

The PowerPC context switch waited for the incoming thread to leave
blocked_lock before releasing the outgoing thread.  If two CPUs selected
each other's running threads concurrently, both CPUs waited for the
other to perform the release and neither could progress.  This appeared
as intermittent boot hangs under QEMU MTTCG when taskqueue threads were
bound to opposite CPUs.

8df2e5421468 ("powerpc: put the isync inside the TD_LOCK()...")
attempted to fix the same hang by moving isync into the polling loop.
That did not address the circular wait: isync cannot cause either CPU to
execute the release store after the loop.  It only added context
synchronization to failed iterations and changed timing. Move isync back
to the successful exit, which preserves acquire ordering for subsequent
context loads.

Match the ordering used by other architectures: publish the outgoing
thread's new lock before waiting for the incoming thread.  Apply the

    [20 lines not shown]
DeltaFile
+11-7sys/powerpc/powerpc/swtch64.S
+11-7sys/powerpc/powerpc/swtch32.S
+22-142 files

FreeBSD/src b6a34e8 — share/misc committers-ports.dot

committers-ports.dot: Restore ahze from alumni

Move back to the current committers section and record acm and dtxdf
as mentors.

Approved by:    dtxdf (mentor)
Differential Revision:  https://reviews.freebsd.org/D60683
DeltaFile
+4-1share/misc/committers-ports.dot
+4-11 files

FreeBSD/src 5fb07bb — lib/libthr libthr.3, lib/libthr/thread thr_init.c

libthr: Fix LIBPTHREAD_QUEUE_FIFO range

LIBPTHREAD_QUEUE_FIFO is used in bitwise offset, we set the limit to
0~31 so that it won't cause undefined behavior. Also, create a new
helper function to do getenv++strtol directly and check the boundary of
the valid value.

Reviewed by:    kib
MFC after:      2 weeks
Differential Revision: https://reviews.freebsd.org/D60487
DeltaFile
+24-9lib/libthr/thread/thr_init.c
+2-2lib/libthr/libthr.3
+26-112 files

FreeBSD/src 23626eb — sys/compat/linprocfs linprocfs.c

linux: cap mount id to INT_MAX

linux stores mount id as a int32_t, using xor would make it becomes
negative in some cases. As a result, we cap the value to INT_MAX to
prevent getting a negative value from userspace.

MFC after:      2 weeks
Differential Revision: https://reviews.freebsd.org/D59202
DeltaFile
+2-1sys/compat/linprocfs/linprocfs.c
+2-11 files

FreeBSD/src 68831d2 — sys/netpfil/pf pf_ioctl.c

pf: Register the netlink family only while the vnets are set up

pf_modevent() registers the generic netlink family at MOD_LOAD, before
vnet_pf_init() has set up the state hashes and locks the handlers use,
and pf_unload() unregisters it after vnet_pf_uninit() has torn them
down.  Sending PFNL_CMD_GETSTATES while pf loads or unloads panics in
pf_handle_getstates() on a NULL or freed V_pf_idhash.

Register the family from a SYSINIT ordered after vnet_pf_init(), and
unregister it from the matching SYSUNINIT, before vnet_pf_uninit().

Reviewed by:            kp
Fixes:                  2cef62886dc7 ("pf: convert state retrieval to netlink")
MFC after:              1 week
Sponsored by:           Rubicon Communications, LLC ("Netgate")
Differential Revision:  https://reviews.freebsd.org/D60651
DeltaFile
+20-3sys/netpfil/pf/pf_ioctl.c
+20-31 files

FreeBSD/src da4b59f — contrib/wpa/src/ap ieee802_11.c, contrib/wpa/src/common proximity_ranging.c qca-vendor.h

wpa: Update to 2.12

Fixes and new features include:

hostapd:
* support RSN overriding (e.g., WPA3-Personal Compatibility Mode)
* EHT/IEEE 802.11be/Wi-Fi 7
  - more complete support
  - fix message validation issues that could enable DoS attacks
  - fix group key rekeying
* enable SAE group 20 by default if SAE-EXT-KEY is enabled
* reject unexpected SAE password identifier to avoid DoS attack against
  a specific STA
* mandate use of SAE H2E when using password identifiers
* assign VLAN when using SAE with PMKSA caching
* support SPP A-MSDU negotiation
* support IEEE 802.11bi functionality
  - changing SAE password identifiers
  - EPPKE

    [52 lines not shown]
DeltaFile
+6,124-33contrib/wpa/src/common/qca-vendor.h
+5,003-0contrib/wpa/wpa_supplicant/nan_supplicant.c
+3,381-671contrib/wpa/src/drivers/driver_nl80211.c
+3,106-664contrib/wpa/src/ap/ieee802_11.c
+3,677-0contrib/wpa/src/nan/nan.c
+2,707-0contrib/wpa/src/common/proximity_ranging.c
+23,998-1,368330 files not shown
+89,793-24,630336 files

FreeBSD/src 8d1a813 — contrib/wpa/src/utils os_unix.c

wpa: Diff reduction with upstream

I inadvertantly added gratuitous changes to upstream. Revert the
gratuitous parts of 676041c41ba5

Suggested by: cy
Fixes: 676041c41ba5
Sponsored by: Netflix
(cherry picked from commit cab9ccf3ff8c5722dace61a814d791aeba2751c6)
DeltaFile
+2-2contrib/wpa/src/utils/os_unix.c
+2-21 files

FreeBSD/src 1efafdc — contrib/wpa/src/utils os_unix.c

WPA: Allow CLOCK_BOOTTIME and CLOCK_MONOTONIC to #define the same

Historically, these have been differnet values, and only one was defined
or they were defined as different values. Now that they are about to be
the same value, add #ifdef to cope.

Sponsored by:           Netflix
Reviewed by:            olce, val_packett.cool, adrian
Differential Revision:  https://reviews.freebsd.org/D45418

(cherry picked from commit 676041c41ba587285bb934aa2fca290ea7208038)
DeltaFile
+8-3contrib/wpa/src/utils/os_unix.c
+8-31 files

FreeBSD/src 3e4c62b — contrib/wpa/src/ap ieee802_11.c, contrib/wpa/src/common proximity_ranging.c qca-vendor.h

wpa: Update to 2.12

Fixes and new features include:

hostapd:
* support RSN overriding (e.g., WPA3-Personal Compatibility Mode)
* EHT/IEEE 802.11be/Wi-Fi 7
  - more complete support
  - fix message validation issues that could enable DoS attacks
  - fix group key rekeying
* enable SAE group 20 by default if SAE-EXT-KEY is enabled
* reject unexpected SAE password identifier to avoid DoS attack against
  a specific STA
* mandate use of SAE H2E when using password identifiers
* assign VLAN when using SAE with PMKSA caching
* support SPP A-MSDU negotiation
* support IEEE 802.11bi functionality
  - changing SAE password identifiers
  - EPPKE

    [50 lines not shown]
DeltaFile
+6,124-33contrib/wpa/src/common/qca-vendor.h
+5,003-0contrib/wpa/wpa_supplicant/nan_supplicant.c
+3,381-671contrib/wpa/src/drivers/driver_nl80211.c
+3,106-664contrib/wpa/src/ap/ieee802_11.c
+3,677-0contrib/wpa/src/nan/nan.c
+2,707-0contrib/wpa/src/common/proximity_ranging.c
+23,998-1,368330 files not shown
+89,793-24,630336 files

FreeBSD/src e6dc001 — sys/netpfil/pf pf_ioctl.c, tests/sys/netpfil/pf rules_counter.sh

pf: Do not hash pool address pointers into rule hashes

pf_hash_pool() hashes the first address of a pool as a whole struct
pf_addr_wrap, including the union that holds the kernel's pfi_dynaddr
or pfr_ktable pointer.

An interface pool such as "-> ($ext_if)" gets a new pfi_dynaddr on
every load, so with "set keepcounters" the rule never matches its
predecessor and loses its counters on every reload.  The pointers also
differ between hosts: once a filter rule in the main ruleset has an
interface or table pool, pfsync peers disagree on the ruleset checksum
and bind every synced state to the default rule.

Hash the address with that union cleared.  The rest of the address,
including the prefix length of an interface address, is hashed as
before, and the hash of a rule with a plain address pool does not
change.

Reviewed by:            kp

    [4 lines not shown]
DeltaFile
+53-0tests/sys/netpfil/pf/rules_counter.sh
+5-1sys/netpfil/pf/pf_ioctl.c
+58-12 files

FreeBSD/src a72d8b2 — tests/aslts/src/runtime/collections/complex/operand/tests/oconst oconst.asl, tests/aslts/src/runtime/collections/complex/operand/tests/olocal olocal.asl

Import ACPICA 20260930
DeltaFile
+47,291-0tests/aslts/src/runtime/collections/functional/region/regionfield.asl
+35,132-0tests/aslts/src/runtime/collections/complex/operand/tests/oconst/oconst.asl
+24,685-0tests/aslts/src/runtime/collections/complex/operand/tests/oreftopackageel/oreftopackageel.asl
+23,068-0tests/aslts/src/runtime/collections/complex/operand/tests/oreturn/oreturn.asl
+23,066-0tests/aslts/src/runtime/collections/complex/operand/tests/opackageel/opackageel.asl
+22,245-0tests/aslts/src/runtime/collections/complex/operand/tests/olocal/olocal.asl
+175,487-01,940 files not shown
+749,706-78,6211,946 files

FreeBSD/src 030e556 — sys/dev/acpica acpi_lid.c acpivar.h

acpi_lid: add an in-kernel lid state eventhandler

Lid state changes are only published to userland, via devd and evdev.
Drivers that need to react to the lid in the kernel have no hook, so
they end up installing a second ACPI_DEVICE_NOTIFY handler on the same
lid object and reimplementing the _LID evaluation.

Add acpi_lid_event, invoked from acpi_lid_status_update() alongside the
existing devd notification, carrying the new state (1 open, 0 closed).

Reviewed by:    adrian
Differential Revision:  https://reviews.freebsd.org/D60704
DeltaFile
+5-0sys/dev/acpica/acpivar.h
+3-0sys/dev/acpica/acpi_lid.c
+8-02 files

FreeBSD/src 3943973 — sys/dev/mgb if_mgb.h

mgb: increase timeout

Increase wait timeout as needed for slower systems.

It takes ~120ms on the Codasip Prime for the MGB_PHY_READY bit
to set after phy reset command issued.

Reviewed by:    emaste
Sponsored by:   EPSRC ("UKRI3001: CHERI Research Centre")
Differential Revision:  https://reviews.freebsd.org/D60706
DeltaFile
+1-1sys/dev/mgb/if_mgb.h
+1-11 files

FreeBSD/src b023724 — tools/build/cross-build/include/common/sys cdefs.h

cross-build: Define __GNUC_PREREQ__ in cdefs.h

This is required when including stdckdint.h and doesn't seem to be
provided by older clang.

Reviewed by:    emaste
Fixes:  7233893e9496 ("lib{c,openbsd}: use ckd_mul() for overflow checking in re(c)allocarray")
Differential Revision:  https://reviews.freebsd.org/D52933
(cherry picked from commit 53ab85a55408562690f58788ea8d01c18b79ef5d)
DeltaFile
+10-0tools/build/cross-build/include/common/sys/cdefs.h
+10-01 files

FreeBSD/src da8a529 — sys/dev/mgb if_mgb.h if_mgb.c

mgb: support for PCI11414.

Add support for Microchip PCI11414 Gigabit Ethernet Controller.

The PCI11414 is used on the CHERI VITA 57.1 PCIe Extension Board.

- Add PCI11414 device ID
- Add support for SGMII mode. Read the programmed strap configuration
  and enable SGMII operation when configured. Bypass the MII interface
  in SGMII mode.
- Increase the DMA descriptor ring size.

Reviewed by:    emaste
Sponsored by:   EPSRC ("UKRI3001: CHERI Research Centre")
Differential Revision:  https://reviews.freebsd.org/D60539
DeltaFile
+83-27sys/dev/mgb/if_mgb.c
+32-1sys/dev/mgb/if_mgb.h
+115-282 files

FreeBSD/src b80af97 — share/man/man4 mgb.4 Makefile, sys/modules Makefile

mgb: Build module for all archs

It is not x86-specific.

This reverts commit e0a5aa37c1ef3a22e2dc8c311e0e32ea363f7ccf.
This reverts commit 2d935a1e93af4d552db1f7218ef97e01f058c084.

Reviewed by:    kbowling
Sponsored by:   The FreeBSD Foundation
Differential Revision: https://reviews.freebsd.org/D60615
DeltaFile
+1-2sys/modules/Makefile
+1-2share/man/man4/Makefile
+1-1share/man/man4/mgb.4
+3-53 files

FreeBSD/src 33d9fbf — sys/compat/linux linux_signal.c

linuxulator: Accept 0 as signal in rt_sigqueueinfo

Linux allows 0 as a signal for rt_sigqueueinfo(2) the same as it does
for kill(2).  This is used to check for process existence and
permissions.

Allow this value through as a special case in linux_rt_siqgueueinfo the
same way as was done for linux_kill.

Before this change, lio_listio(3) would fail with EINVAL under
Linuxulator.  Now it is functional.

MFC after:      1 week
Reviewed by:    kevans
Approved by:    kevans (mentor)
Differential Revision:  https://reviews.freebsd.org/D60574
DeltaFile
+9-2sys/compat/linux/linux_signal.c
+9-21 files

FreeBSD/src a3c5773 — lib/libifconfig libifconfig_sfp.c

lib/libifconfig: Fix pointer-sign warnings

Fix all pointer-sign warnings generated when compiling libifconfig.

A couple more snuck in while the previous batch of fixes was landing.

Fixes:          963f1a5455c9 ("ifconfig: add CMIS support for 400GbE optics")
Reviewed by:    kevans
Approved by:    kevans (mentor)
Differential Revision:  https://reviews.freebsd.org/D60573
DeltaFile
+2-2lib/libifconfig/libifconfig_sfp.c
+2-21 files

FreeBSD/src 8fdf03c — share/misc committers-src.dot

committers-src: Add rmoeller mentored by kevans@

And note the commit bit return date of my previous account, freqlabs@.

Approved by:    kevans (mentor)
DeltaFile
+3-1share/misc/committers-src.dot
+3-11 files

FreeBSD/src e3d7a9b — . .mailmap

mailmap: Add mappings for rmoeller

Approved by:    kevans (mentor)
DeltaFile
+4-0.mailmap
+4-01 files

FreeBSD/src 686323c — sys/dev/rge if_rge.c

if_rge: add debugnet/netdump support

Implement the debugnet KPI in rge(4) by mirroring the re(4) pattern.
Tested with a RTL8125 2.5GbE NIC.

Approved by:    adrian
Differential Revision:  https://reviews.freebsd.org/D60135
DeltaFile
+87-0sys/dev/rge/if_rge.c
+87-01 files

FreeBSD/src ec68ff1 — sys/dev/mgb if_mgb.h if_mgb.c

mgb: support multi-segment packets in the DMA descriptor rings.

Reviewed by:    emaste
Sponsored by:   EPSRC ("UKRI3001: CHERI Research Centre")
Differential Revision:  https://reviews.freebsd.org/D60705
DeltaFile
+10-12sys/dev/mgb/if_mgb.c
+1-0sys/dev/mgb/if_mgb.h
+11-122 files

FreeBSD/src a6e1dde — sys/netpfil/pf pf.c, tests/sys/netpfil/pf icmp6.sh

pf: Do not corrupt neighbour advertisements when translating

When an ICMPv6 query or reply matches a translated state,
pf_test_state_icmp() copies the state's virtual id into icmp6_id.  Only
echo messages have an identifier there.  For all other types the
virtual id is 0 and those two bytes hold something else; in a neighbour
advertisement they hold the R, S and O flags.  The checksum was not
updated either, so icmp6_input() dropped the advertisement as a bad
checksum.

Unicast NUD probes to a link-local neighbour, such as the default
router, are sent from the link-local address.  With a nat rule that
matches it (e.g. "from any"), every advertisement answering a probe was
dropped: NUD failed, the neighbour cache entry was deleted, and traffic
to the neighbour stalled until it was resolved again.

Only rewrite the id of echo messages, as the ICMPv6 error path already
does, and update the checksum, as the IPv4 path does.


    [8 lines not shown]
DeltaFile
+73-0tests/sys/netpfil/pf/icmp6.sh
+13-1sys/netpfil/pf/pf.c
+86-12 files

FreeBSD/src 3ca4b8d — contrib/openbsm/bin/auditdistd proto_tls.c proto_socketpair.c

auditdistd: Use fixed-length protocol names

All communication between auditdistd senders and receivers and
internally between auditdistd and its worker children passes through the
same pair of send / receive functions.  The receive function uses
recv(2) with the MSG_WAITALL flag, which in theory means we should never
get a short read.  However, when handing off a socket to a worker child,
we also pass a variable-length string identifying the type of socket
we're passing, and reading this string relies on a short read.  This
used to work because the arrival of the descriptor would interrupt the
recv(2) call, but this bug was fixed when the AF_UNIX code was rewritten
a while ago and auditdistd has been broken ever since.

Fixing the length of the protocol name to four characters including the
terminating null solves the short-read bug by never requiring a short
read (nothing else in auditdistd requires one).

PR:             296107
MFC after:      1 week

    [2 lines not shown]
DeltaFile
+4-9contrib/openbsm/bin/auditdistd/proto.c
+1-1contrib/openbsm/bin/auditdistd/proto_tls.c
+1-1contrib/openbsm/bin/auditdistd/proto_socketpair.c
+1-1contrib/openbsm/bin/auditdistd/proto_impl.h
+7-124 files

FreeBSD/src 989d72f — sys/netpfil/pf pf_table.c

pf: Free a table entry that cannot be routed

pfr_insert_kentry() returned the error of pfr_route_kentry() and
leaked the entry it had created; pfr_insert_kentries() stopped at the
first entry it could not route and leaked it and the rest of the work
queue, which no caller frees.  Destroy an entry that cannot be routed
and go on with the next.

Reviewed by:            kp
MFC after:              2 weeks
Sponsored by:           Rubicon Communications, LLC ("Netgate")
Differential Revision:  https://reviews.freebsd.org/D60532
DeltaFile
+7-4sys/netpfil/pf/pf_table.c
+7-41 files

FreeBSD/src 167d356 — sys/arm64/vmm vmm_instruction_emul.c

arm64/vmm: Treat Rt=31 as xzr in reg & instr emul

For certain instructions like msr, mrs, ldr & str, Rt=31 means the
operand is the Zero register (XZR) as opposed to the SP, even though the
two share the encoding of 31 on AArch64.

This is currently ignored in register and instruction emulation, so
emulated guest operations like "msr <reg>, xzr" will set the value of
<reg> to the current value of the SP instead of to 0.

Skip set and get operations when Rt=31 to correct the behaviour.

Signed-off-by: Kajetan Puchalski <kajetan.puchalski at arm.com>
Reviewed by:    andrew
Sponsored by:   Arm Ltd
Pull Request:   https://github.com/freebsd/freebsd-src/pull/2454
DeltaFile
+25-8sys/arm64/vmm/vmm_instruction_emul.c
+25-81 files