FreeBSD/src 16f8ea6sys/amd64/conf MINIMAL GENERIC

amd64: Remove tpm(4) from GENERIC for now

It breaks suspend/resume and no one has had time to investigate and fix
it.

PR:             291067
Reviewed by:    emaste
Fixes:          3deb21f1afd5 ("random: TPM_HARVEST should have been named RANDOM_ENABLE_TPM")
Differential Revision:  https://reviews.freebsd.org/D54587
DeltaFile
+2-1sys/amd64/conf/MINIMAL
+2-1sys/amd64/conf/GENERIC
+4-22 files

FreeBSD/src d2f1c8e. Makefile.inc1 Makefile

Makefile: Update doxygen requirements

MFC after:      3 days
Reviewed by:    imp, ziaee
Signed-off-by:  Minsoo Choo <minsoochoo0122 at proton.me>
Closes:         https://github.com/freebsd/freebsd-src/pull/1869
DeltaFile
+8-0Makefile.inc1
+2-2Makefile
+10-22 files

FreeBSD/src b72cb30sys/dev/bnxt/bnxt_en if_bnxt.c

bnxt: fix i2c read to allow access to different addresses

Allow reading of i2c addresses other than A0. A0 does provide most
information, but doesn't provide things like module temps, and optical
signal levels.

Sponsored by: Netflix
Reviewed by: sumit.saxena_broadcom.com
Differential Revision: https://reviews.freebsd.org/D54590
MFC after: 3 days
DeltaFile
+1-1sys/dev/bnxt/bnxt_en/if_bnxt.c
+1-11 files

FreeBSD/src 0df9054sys/netpfil/pf pf_nl.c

pf: handle nlattr_add_nested() failure

Sponsored by:   Rubicon Communications, LLC ("Netgate")
DeltaFile
+45-0sys/netpfil/pf/pf_nl.c
+45-01 files

FreeBSD/src bf19253sys/netpfil/pf pf_nl.c

pf: remove redundant zeroing

nlmsg_reserve_object() already zeroes the header before it gives it to
us, so there's no need to explicitly zero these fields again.

Sponsored by:   Rubicon Communications, LLC ("Netgate")
DeltaFile
+0-54sys/netpfil/pf/pf_nl.c
+0-541 files

FreeBSD/src c0df8f6sys/dev/acpica/Osd OsdSchedule.c

acpi: Make taskqueue only run on BSP

This is needed because when we add the suspend-to-idle loop, we only
want to break the BSP out of idle to process the taskqueue while keeping
all the others idled.

Currently assuming BSP to be CPU0, which may not always be the case on
non-x86.

Reviewed by:    kib
Approved by:    kib
Sponsored by:   The FreeBSD Foundation
Differential Revision:  https://reviews.freebsd.org/D54406
DeltaFile
+5-1sys/dev/acpica/Osd/OsdSchedule.c
+5-11 files

FreeBSD/src cae2809libexec/nuageinit nuageinit

nuageinit: set the hostname when user-data is missing

This address the situation reported here
https://github.com/freebsd/freebsd-src/pull/1952#issuecomment-3720210259

The user-data file was missing and the `sethostname` function is never
called. This commit adjusts slightly the logic to avoid the `exit()` call
when the `user-data` file is missing.

MFC After:      1 week
Signed-off-by: Gonéri Le Bouder <goneri at lebouder.net>
Differential Revision:  https://github.com/freebsd/freebsd-src/pull/1953
DeltaFile
+67-46libexec/nuageinit/nuageinit
+67-461 files

FreeBSD/src 65e77d3libexec/nuageinit/tests nuageinit.sh

nuageinit: fix test after recent behaviour change

with recent change nuageinit always create a "freebsd" user, if no
users are specified, which means we do need to get the rootdir in the
testsuite containing a group file otherwise pw complains and the tests
fails.
DeltaFile
+4-0libexec/nuageinit/tests/nuageinit.sh
+4-01 files

FreeBSD/src 9ae4335release/tools gce.conf

GCE: ARM64 Support: Add hw.pci.honor_msi_blacklist=0.

This is required for MSI support on GCE ARM64 instances which is
prerequisite to gve(4) not panicking at boot, and nvme(4) also has
a real sad time without interrupts. Tested on a variety of c4a VMs.

This is meant to be a temporary hack; long term fix would be to
check for the hypervisor and quirk gve(4) device with
PCI_QUIRK_ENABLE_MSI_VM.

PR:             kern/292081
MFC after:      1 week
DeltaFile
+3-0release/tools/gce.conf
+3-01 files

FreeBSD/src 709c104release/tools gce.conf

GCE: Fix growfs path

The sed command was missing the ${DESTDIR} prefix, meaning it was
attempting to modify the build host's /etc/rc.d/growfs instead of
the target image's script. Tested in an arm64 builder that builds
as non-root.

PR:             kern/292081
MFC after:      1 day
DeltaFile
+1-1release/tools/gce.conf
+1-11 files

FreeBSD/src f604d84release/tools gce.conf

GCE: Enable vtnet(4) Multiqueue.

Removes hw.vtnet.mq_disable=1.

This workaround was originally introduced nearly a decade ago to
address stability issues on KVM that have long since been resolved
in both the FreeBSD driver and the GCE hypervisor. Removing this
allows network interrupts to scale across multiple vCPUs.

Tested on n2-highcpu-16 VM with 15.0-RELEASE and confirmed multiple
queue pairs active and interrupts handling across cores.

PR:             kern/292081
MFC after:      1 day
DeltaFile
+0-1release/tools/gce.conf
+0-11 files

FreeBSD/src eb1b6ecsys/contrib/openzfs/module/icp/asm-x86_64/modes aesni-gcm-avx2-vaes.S aesni-gcm-x86_64.S

zfs: emit .note.GNU-stack section for all ELF targets

On FreeBSD, linking the zfs kernel module with binutils ld 2.44 shows
the following warning:

    ld: warning: aesni-gcm-avx2-vaes.o: missing .note.GNU-stack section implies executable stack
    ld: NOTE: This behaviour is deprecated and will be removed in a future version of the linker

Some of the `.S` files under `module/icp/asm-x86_64/modes` check whether
to emit the `.note.GNU-stack` section using:

    #if defined(__linux__) && defined(__ELF__)

We could add `&& defined(__FreeBSD__)` to the test, but since all other
`.S` files in the OpenZFS tree use:

    #ifdef __ELF__

it would seem more logical to use that instead. Any recent ELF platform

    [5 lines not shown]
DeltaFile
+1-1sys/contrib/openzfs/module/icp/asm-x86_64/modes/aesni-gcm-avx2-vaes.S
+1-1sys/contrib/openzfs/module/icp/asm-x86_64/modes/aesni-gcm-x86_64.S
+1-1sys/contrib/openzfs/module/icp/asm-x86_64/modes/ghash-x86_64.S
+3-33 files

FreeBSD/src cd1aa5ftools/cam cam_all_but_scsi.d README

tools/cam: Start to add the testing tools for CAM

Create a directory for testing tools arond CAM. These are snippets of
what will eventually be camio. At the moment, it was written using fbt
traces. This is OK, but fragile, so they need to be re-written with the
cam provider. cam_all_but_scsi.d is the first step. It shows how to do
this with the new cam dtrace provider.

Sponsored by:           Netflix
Reviewed by:            adrian
Differential Revision:  https://reviews.freebsd.org/D54472
DeltaFile
+89-0tools/cam/cam_all_but_scsi.d
+9-0tools/cam/README
+98-02 files

FreeBSD/src efb7795cddl/lib/libdtrace cam.d Makefile

dtrace: Add definitiosn for the cam dtrace provider

Sponsored by:           Netflix
Reviewed by:            adrian
Differential Revision:  https://reviews.freebsd.org/D54471
DeltaFile
+194-0cddl/lib/libdtrace/cam.d
+2-1cddl/lib/libdtrace/Makefile
+196-12 files

FreeBSD/src aaec2a9sys/cam/scsi scsi_all.c

cam: When inq data isn't valid, pass NULL

When the device isn't there, we don't have valid inq data. Pass NULL in
this case. All the routines that receive this test against NULL already.

Sponsored by:           Netflix
Reviewed by:            adrian
Differential Revision:  https://reviews.freebsd.org/D54470
DeltaFile
+8-10sys/cam/scsi/scsi_all.c
+8-101 files

FreeBSD/src 1a7151fshare/man/man4 dtrace_cam.4 Makefile, sys/cam cam_xpt.c

cam: Add probes for xpt actions

cam::xpt:action(union ccb *)
cam::xpt:done((union ccb *)
cam::xpt:async-cb(void *cbarg, uint32_t async_code, struct cam_path
        *path, void *async_arg);

Called when xpt_action(), xpt_done*() and the xpt async callbacks are
called.

Sponsored by:           Netflix
Reviewed by:            adrian
Differential Revision:  https://reviews.freebsd.org/D54469
DeltaFile
+42-0share/man/man4/dtrace_cam.4
+21-1sys/cam/cam_xpt.c
+1-0share/man/man4/Makefile
+64-13 files

FreeBSD/src ecb1f46sys/cam cam.h cam.c

cam: Start adding dtrace provider 'cam'

Start to provide robust tracing in cam now that clang has broken my
fbt-based dtrace scripts a couple of times.

Sponsored by:           Netflix
Reviewed by:            adrian
Differential Revision:  https://reviews.freebsd.org/D54468
DeltaFile
+14-0sys/cam/cam.h
+5-0sys/cam/cam.c
+19-02 files

FreeBSD/src 3989a3dstand/efi/loader bootinfo.c

loader: Only warn when we have neither FDT nor ACPI

Sponsored by:           Netflix
Reviewed by:            adrian, andrew
Differential Revision:  https://reviews.freebsd.org/D54510
DeltaFile
+2-1stand/efi/loader/bootinfo.c
+2-11 files

FreeBSD/src d82698astand/efi/loader main.c

loader.efi: Only use SPCR if enabled.

SerialPort in the SPCR is zeroed when serial redirection is disabled,
rather than the SPCR being omitted from the ACPI tables ony many
systems. Check to see that SerialPort.Address is non-zero before using.

FreeBSD would fail to boot on systems that could have a serial port
redireciton, but don't have it enabled because the loader would create a
bogus hw.uart.console. While one could unset this value to boot, you
couldn't do that automatically very easily. Instead, don't even look
at the SPCR table if the SerialPort is zero'd.

PR: 292206
MFC After: 3 days
Sponsored by: Netflix
Co-authored-by: Warner Losh <imp at FreeBSD.org>
Closes:  https://github.com/freebsd/freebsd-src/pull/1948
DeltaFile
+9-5stand/efi/loader/main.c
+9-51 files

FreeBSD/src e2bedc7tools/test/hwpmc pmctest.py

Extend the script to collect gprof data

While we're at it, switch to simple waiting from communicate() calls.
DeltaFile
+27-4tools/test/hwpmc/pmctest.py
+27-41 files

FreeBSD/src 9b5d6absys/dev/sdhci sdhci_pci.c

sdhci_pci(4): Remove incorrect __unused

The slot parameter actually is used as index into the memory resource.

Fixes:  c11bbc7d
DeltaFile
+13-13sys/dev/sdhci/sdhci_pci.c
+13-131 files

FreeBSD/src 61002e0sys/kern tty.c

tty(4): Consistently use ISO C99 bool

Fixes:  9750d9e5
DeltaFile
+1-1sys/kern/tty.c
+1-11 files

FreeBSD/src dcb8062sys/vm vm_object.h

vm_object.h: tweak OBJ_ONEMAPPING comment even more

The formulation that pages are allowed to have at most one mapping is
not quite clear.  Nothing prevents pages from having more than one
mapping, but the flag must be cleared then.

Reviewed by:    alc, markj
Sponsored by:   The FreeBSD Foundation
MFC after:      3 days
Differential revision:  https://reviews.freebsd.org/D54570
DeltaFile
+2-3sys/vm/vm_object.h
+2-31 files

FreeBSD/src 6c0bcd1sys/compat/linuxkpi/common/include/linux bitops.h

linuxkpi: Add `rol32()`

`rol64()` and `rol32()` are used by <linux/siphash.h>. The former was
added previously, before <linux/siphash.h> was added. However the latter
was not, and it broke the build on armv7.

Reported by:    adrian
Reviewed by:    adrian, rpokala
Sponsored by:   The FreeBSD Foundation
Differential Revision: https://reviews.freebsd.org/D54588
DeltaFile
+6-0sys/compat/linuxkpi/common/include/linux/bitops.h
+6-01 files

FreeBSD/src e86e4f1sys/compat/linuxkpi/common/include/linux kmsg_dump.h

linuxkpi: Add <linux/kmsg_dump.h>

This header declares register/unregister functions to allow a piece of
code to tell what function to call in case of a panic. Several panic
handlers may be registered.

The DRM generic code started to use it in Linux 6.10 as part of the
panic handler.

Reviewed by:    bz, christos
Sponsored by:   The FreeBSD Foundation
Differential Revision: https://reviews.freebsd.org/D54492
DeltaFile
+51-0sys/compat/linuxkpi/common/include/linux/kmsg_dump.h
+51-01 files

FreeBSD/src 3942e85sys/compat/linuxkpi/common/include/linux ratelimit.h

linuxkpi: Add WARN_RATELIMIT()

The i915 DRM driver started to use it in Linux 6.10.

Reviewed by:    bz, christos
Sponsored by:   The FreeBSD Foundation
Differential Revision: https://reviews.freebsd.org/D54493
DeltaFile
+7-0sys/compat/linuxkpi/common/include/linux/ratelimit.h
+7-01 files

FreeBSD/src 10c6f1fsys/compat/linuxkpi/common/include/linux cec-funcs.h cec.h, sys/compat/linuxkpi/common/include/media cec.h cec-notifier.h

linuxkpi: Replicate the chain of #include in the `cec*.h` headers

The i915 DRM driver depends on this namespace pollution to access
`debugfs_*` functions, after several explicit #include of
<linux/debugfs.h> were removed in Linux 6.10.

Reviewed by:    bz, christos
Sponsored by:   The FreeBSD Foundation
Differential Revision: https://reviews.freebsd.org/D54494
DeltaFile
+23-0sys/compat/linuxkpi/common/include/media/cec.h
+17-0sys/compat/linuxkpi/common/include/media/cec-notifier.h
+16-0sys/compat/linuxkpi/common/include/linux/cec-funcs.h
+3-0sys/compat/linuxkpi/common/include/linux/cec.h
+0-0sys/compat/linuxkpi/dummy/include/media/cec-notifier.h
+59-05 files

FreeBSD/src 514d37fsys/compat/linuxkpi/common/include/linux font.h

linuxkpi: Add <linux/font.h>

The header defines the minimum to allow the DRM generic code to build.
The only function used so far is `get_default_font()`, as part of a
DRM-specific panic handler. We do not use this panic handler on FreeBSD.

For now, it returns a NULL value. It should probably map to a vt(4)
font.

The DRM generic code started to use it in Linux 6.10 as part of the
panic handler.

Reviewed by:    bz, christos
Sponsored by:   The FreeBSD Foundation
Differential Revision: https://reviews.freebsd.org/D54491
DeltaFile
+33-0sys/compat/linuxkpi/common/include/linux/font.h
+33-01 files

FreeBSD/src ac34135sys/compat/linuxkpi/common/include/linux spinlock.h

linuxkpi: Define `raw_spinlock_t` in <linux/spinlock.h>

For now, it is synonymous to `spinlock_t`. The DRM generic code uses the
`struct raw_spinlock` and not `raw_spinlock_t`, that's why the
definition is a struct embedding a `struct mtx`, compared to
`spinlock_t` which is a simpler typedef.

The DRM generic code started to use it in Linux 6.10.

Reviewed by:    bz, christos
Sponsored by:   The FreeBSD Foundation
Differential Revision: https://reviews.freebsd.org/D54489
DeltaFile
+20-0sys/compat/linuxkpi/common/include/linux/spinlock.h
+20-01 files

FreeBSD/src 14d93f6share/man/man4 iflib.4, sys/net iflib.c

iflib: Drop tx lock when freeing mbufs using simple_transmit

Freeing completed transmit mbufs can be time consuming (due to them
being cold in cache, and due to ext free routines taking locks),
especially when we batch tx completions. If we do this when holding
the tx ring mutex, this can cause lock contention on the tx ring mutex
when using iflib_simple_transmit.

To resolve this, this patch opportunistically copies completed mbuf
pointers into a new array (ifsd_m_defer) so they can be freed after
dropping the transmit mutex. The ifsd_m_defer array is
opportunistically used, and may be NULL. If its NULL, then we free
mbufs in the old way. The ifsd_m_defer array is atomically nulled
when a thread is using it, and atomically restored when the freeing
thread is done with it. The use of atomics here avoids
acquire/release of the tx lock to restore the array after freeing
mbufs.

Since we're no longer always freeing mbufs inline, peeking into them to see if a

    [17 lines not shown]
DeltaFile
+147-35sys/net/iflib.c
+7-1share/man/man4/iflib.4
+154-362 files