snd_hda: use the pin ELD to select DisplayPort audio framing
hdaa_audio_setup() reads the converter widget's ELD when choosing
between HDMI and DisplayPort audio infoframes. ELD is stored on the
output pin, so the converter has no ELD and the driver selects HDMI
framing even when the connected display uses DisplayPort.
Read the ELD from the output pin to select the correct audio framing.
The equivalent change was tested on DragonFly BSD with an Intel Kaby
Lake display-audio codec and an LG HDR 4K monitor connected over
DisplayPort. Before the change, converter node 2 had no ELD, while
output pin 5 had an 83-byte ELD identifying DisplayPort. Captured driver
commands programmed HDMI audio infoframe bytes (84 01 0a 70 01 00 00
00). After applying the change and rebooting, the commands used the
existing DisplayPort form (84 1b 44 01 00 00 00), and console tones and
desktop audio were audible.
PR: 299094
[6 lines not shown]
kern: Remove unreachable compat_freebsd8 FEATURE
COMPAT_FREEBSD8 does not exist as a kernel option, so this is dead code.
No functional change intended.
Fixes: e256f71389fb ("kernel: add missed FEATUREs compat_freebsd 8-14")
MFC after: 1 week
Sponsored by: The FreeBSD Foundation
Reviewed by: kib
Pull-Request: https://ron-dev.freebsd.org/FreeBSD/src/pulls/80
Only build secure/libexec/ssh-sk-helper if MK_USB == no
The ssh-sk-helper utility only functions if/when MK_USB == yes.
Installing it on systems where MK_USB == no doesn't make sense.
Differential Revision: https://reviews.freebsd.org/D58246
(cherry picked from commit 4db3872aabc33088cf180599c5eaa23b6f58e6d1)
Only build secure/libexec/ssh-sk-helper if MK_USB == no
The ssh-sk-helper utility only functions if/when MK_USB == yes.
Installing it on systems where MK_USB == no doesn't make sense.
Differential Revision: https://reviews.freebsd.org/D58246
(cherry picked from commit 4db3872aabc33088cf180599c5eaa23b6f58e6d1)
nfs_clrpcops.c: Fix an mbuf leak introduced by fec497b89b1a
The calls to rpc_free_rdma_reduction() were removed, but I forgot
that newnfs_request() removes the reduction mbuf from the list
upon success, so it has to be free'd separately.
This patch does that.
The patch also disables reduction after the first loop interation.
This is necessary until nfsm_build_rdma_reduction() is patched
to handle an offset within the page array.
Reported by: markj
MFC after: 1 month
Fixes: 884ee8d6c9b4 ("nfscl: Add some glue for client side NFS over RDMA")
cd9660: Fix dereferencing invalid RR outlen ptr
`ISO_RRIP_ANALYZE` is constructed in four places. Two of the
initializers set the `outlen` field while the other two,
`cd9660_rrip_analyze` and `cd9660_rrip_offset`, leave it uninitialized.
The uninitialized paths can dereference an invalid pointer on error
paths which causes a kernel panic.
To fix, I zero out `ISO_RRIP_ANALYZE` in all four places where it's
initialized and check that `outlen` is non-null on the error path
in `cd9660_rrip_loop`.
While testing the above, I encountered another kernel panic due to
mounting continuing after the error branch. Evidently, the ISO continued
mounting through the normal ISO 9660 path then triggered a panic down
the line due to a very broken file system from the ISO. To fix that, I
propagate the error from the RR path then fail in the mount path.
[11 lines not shown]
acpi: build dev/acpi_support/acpi_wmi_if.m on ARM64
Per Wikipedia, ACPI WMI support is available on all x86* platforms
and ARM platforms. Add the source to `files.arm64` so code that relies
on its headers (thunderbolt(4) for instance), can be built on ARM64.
MFC after: 1 month
Reviewed By: andrew
Differential Revision: https://reviews.freebsd.org/D55535
(cherry picked from commit 876d2b8392e6570a835a500d8fd7c4a5b0abf844)
libarchive: update documentation for suggested `git pull`
Replace git:// with https:// . The git:// protocol URL might not be
available, depending on firewall rules, as git:// is commonly blocked by
ISPs.
MFC after: 1 month
Differential Revision: https://reviews.freebsd.org/D50470
(cherry picked from commit 5c6ad1a2d175ec84e0e50621ce746c0d34fd5679)
freebsd-update: sort options alphabetically
This helps future developers when adding additional options handlers in the
surrounding blocks.
This is effectively a no-op.
MFC after: 1 month
(cherry picked from commit 0adec3d7ec96105c402ff2286e402ad63c845066)
Run `make obj` before running `make test-includes`
Before this change, `make test-includes` (run as part of buildworld)
would place test files in the current directory, which would clutter up
git clones. Run `make obj` beforehand to ensure that the files are put
in `${.OBJDIR}` instead of `${.CURDIR}`. This helps cut down on the
noise significantly when running commands like `git status`.
MFC after: 1 week
Differential Revision: https://reviews.freebsd.org/D55499
(cherry picked from commit 912864912b71951f9a636190b1dba80528f588eb)
contrib/netbsd-tests: lib/libc/c063: sync with NetBSD
This change syncs the lib/libc/c063 NetBSD tests with FreeBSD. This does
two things:
- Addresses bogus tautologically true assertions flagged by clang and gcc
with ATF 0.22+ [1].
- Brings in some new test coverage.
Obtained from: NetBSD (date tag: `20260818UTC`)
MFC after: 2 weeks
1. https://github.com/freebsd/atf/pull/72
(cherry picked from commit 8109a5c0fba0d015354a69b40e6682d5e8c0f638)
tests/sys/netinet/tcp_socket: fix build with ATF 0.22+
Confirm that creating clients/sockets was successful by testing the
result separate from the assignment and test that the return value is
not -1 instead of testing that the value returned is non-zero.
This fixes the build with [ATF 0.22+][1].
MFC after: 2 weeks
Reported by: clang (-Wparenthesis)
Reviewed by: tuexen, cc
Differential Revision: https://reviews.freebsd.org/D59284
[1]: https://github.com/freebsd/atf/pull/72
Conflicts:
tests/sys/netinet/tcp_implied_connect.c
(cherry picked from commit 4aea6ea2eb400737837ff8d22c25688f88c7966c)
contrib/atf: upgrade to 0.26
This new version gets contrib/atf in line with the published version of
the package up on [GitHub][github].
Please note that this release is a major update: it contains several
bugfixes and feature enhancements. Most were already present in the
FreeBSD src repo, but there were a large number of changes made in
addition to what was already present.
MFC after: 1 month
Merge commit '9c78088348bcf1059d82a62bb57a0746309d4312'
Conflicts:
ObsoleteFiles.inc
contrib/atf/.cirrus.yml
contrib/atf/Makefile.am
contrib/atf/Makefile.in
[53 lines not shown]
contrib/lutok: remove autotools generated files
These files provide no value in the FreeBSD tree proper and change
frequently, depending on what machine I generate the release tarball on
(and what versions of autotools are on the host). Nuke the autogenerated
files to avoid bloating commit history/the tree.
MFC after: 3 days
Requested by: Benjamin Jacobs <freebsd at dev.thsi.be>
(cherry picked from commit cfe443e1e63dd588fba7eabec553ed5e1c408d1f)
sbuf(3): clean up tests
- Update the copyright dates and add "Joao Bonifacio" to the top of
`sbuf_core_test.c`.
- Use `SPDX-Identifier` instead of longform copyright tort.
- Remove `sbuf_test_common.h`: the header was originally added to help
with the 10.x/11.x split, but is no longer needed given that those
releases have been EOLed for multiple years now.
MFC after: 1 week
(cherry picked from commit 3593be37a49e3f5268259bcc2af58cf730b08335)
sbuf(3): increase test coverage
This change adds additional explicit test coverage for the following
sbuf(3) APIs:
- sbuf_clear_flags
- sbuf_get_flags
- sbuf_set_flags
While here, add a missing `sbuf_delete` to `sbuf_drain_ret0_test`: while
it isn't strictly required (the library's state is cleaned up shortly
after the test process ends), tools such as Coverity and LSAN flag
issues with leaked memory. Adding the sbuf_delete(3) call to the test
quells that issue.
MFC after: 1 week
Reviewed-by: ngie
Pull-Request: https://github.com/freebsd/freebsd-src/pull/2367
(cherry picked from commit 642b3d965eb6ef3ecf733950e66fad565a27c967)
sbuf(3): clean up tests
- Update the copyright dates and add "Joao Bonifacio" to the top of
`sbuf_core_test.c`.
- Use `SPDX-Identifier` instead of longform copyright tort.
- Remove `sbuf_test_common.h`: the header was originally added to help
with the 10.x/11.x split, but is no longer needed given that those
releases have been EOLed for multiple years now.
MFC after: 1 week
(cherry picked from commit 3593be37a49e3f5268259bcc2af58cf730b08335)
sbuf(3): increase test coverage
This change adds additional explicit test coverage for the following
sbuf(3) APIs:
- sbuf_clear_flags
- sbuf_get_flags
- sbuf_set_flags
While here, add a missing `sbuf_delete` to `sbuf_drain_ret0_test`: while
it isn't strictly required (the library's state is cleaned up shortly
after the test process ends), tools such as Coverity and LSAN flag
issues with leaked memory. Adding the sbuf_delete(3) call to the test
quells that issue.
MFC after: 1 week
Reviewed-by: ngie
Pull-Request: https://github.com/freebsd/freebsd-src/pull/2367
(cherry picked from commit 642b3d965eb6ef3ecf733950e66fad565a27c967)
contrib/lutok: remove autotools generated files
These files provide no value in the FreeBSD tree proper and change
frequently, depending on what machine I generate the release tarball on
(and what versions of autotools are on the host). Nuke the autogenerated
files to avoid bloating commit history/the tree.
MFC after: 3 days
Requested by: Benjamin Jacobs <freebsd at dev.thsi.be>
(cherry picked from commit cfe443e1e63dd588fba7eabec553ed5e1c408d1f)
contrib/atf: upgrade to 0.26
This new version gets contrib/atf in line with the published version of
the package up on [GitHub][github].
Please note that this release is a major update: it contains several
bugfixes and feature enhancements. Most were already present in the
FreeBSD src repo, but there were a large number of changes made in
addition to what was already present.
MFC after: 1 month
Merge commit '9c78088348bcf1059d82a62bb57a0746309d4312'
(cherry picked from commit 952231086100bed7130212b5425e44ffd732913b)
[github]: https://github.com/freebsd/atf
tests/libc: only build brk_test where libc provides sbrk
Replace the exclusion list with an allowlist of the architectures
whose libc exports brk/sbrk: amd64, i386, arm and powerpc.
On aarch64, riscv and loongarch libc does not export those symbols
and the test cannot run, so do not build it there. New architectures
now default to not building the test unless brk support is added.
MFC after: 1 week
Signed-off-by: Xiaoqiang Zhao <zhaoxiaoqiang007 at gmail.com>
Reviewed by: ngie
Differential Revision: https://reviews.freebsd.org/D60357
(cherry picked from commit 8a7df6c58d549bd2eaa5cad30b2ef93c3eca3c18)