FreeBSD/src 640c1eetools/build/mk OptionalObsoleteFiles.inc

Remove example tests when MK_EXAMPLES=no

This change cleans up example tests for atf, googletest, plain, and TAP
when MK_EXAMPLES=no. Not having this in results
`kyua test -k /usr/tests/share/examples/Kyuafile` being broken on a host
where the content in that directory tree is stale. I ran into that case
because at some point in time in the past I had specified
`MK_GOOGLETEST=no` one of my dev instances.

MFC after:      1 week

(cherry picked from commit cea2683bb691d6cbcfb7e342c497d018bba712c2)
DeltaFile
+26-0tools/build/mk/OptionalObsoleteFiles.inc
+26-01 files

FreeBSD/src fca1e5dtools/build/mk OptionalObsoleteFiles.inc

Remove example tests when MK_EXAMPLES=no

This change cleans up example tests for atf, googletest, plain, and TAP
when MK_EXAMPLES=no. Not having this in results
`kyua test -k /usr/tests/share/examples/Kyuafile` being broken on a host
where the content in that directory tree is stale. I ran into that case
because at some point in time in the past I had specified
`MK_GOOGLETEST=no` one of my dev instances.

MFC after:      1 week

(cherry picked from commit cea2683bb691d6cbcfb7e342c497d018bba712c2)
DeltaFile
+26-0tools/build/mk/OptionalObsoleteFiles.inc
+26-01 files

FreeBSD/src 5c361ebetc/mtree BSD.tests.dist, secure/lib/libcrypto Makefile

openssl: add a simple smoke test for the legacy provider

This change adds a simple smoke test for the legacy provider to ensure
that the provider doesn't break in the future when performing updates.

This is not a functional or system test; the OpenSSL test suite does a
much better job at doing this than we can.

MFC after:              1 week
Differential Revision:  https://reviews.freebsd.org/D53045

(cherry picked from commit 3b6442370a17c57c4c290b9a8e1e8328da820705)
DeltaFile
+40-0secure/lib/libcrypto/tests/libcrypto_test.sh
+5-0secure/lib/libcrypto/tests/Makefile
+3-0secure/lib/libcrypto/Makefile
+2-0etc/mtree/BSD.tests.dist
+50-04 files

FreeBSD/src 5111a75sys/dev/asmc asmcvar.h asmc.c

asmc: Add support for MacBookPro11,5

  Add support for the MacBookPro11,5 (Mid 2015, 15-inch with AMD Radeon R9 M370X GPU)
  to the Apple SMC driver.

  Debug testing revealed this model lacks several SMC keys present on MacBookPro11,4
  (IBLC, ICMC, IC2C), that model-specific sensor definitions.

Differential Revision:  https://reviews.freebsd.org/D54665
Reviewed by:    adrian

(cherry picked from commit c498eaa2f9090d7bdc6456181d8bf74869288bbb)
DeltaFile
+35-0sys/dev/asmc/asmcvar.h
+7-0sys/dev/asmc/asmc.c
+42-02 files

FreeBSD/src afa1058sys/dev/asmc asmc.c asmcvar.h

asmc: improve asmc_dumpall to read actual SMC key count

The asmc_dumpall debug function previously used a hardcoded loop limit
of 0x100 (256) keys with a "XXX magic number" comment.

This change improves asmc_dumpall to:

* Read the actual number of keys from the ASMC_NKEYS SMC key
* Print the key count being dumped for better debugging output
* Loop only up to the actual key count (e.g., 297 on Mac Mini 5,1)

This provides more accurate debug output and removes the magic number.

Tested on Mac Mini 5,1 (FreeBSD 16.0-CURRENT):

* Rebuild kernel with DEBUG enabled in asmc driver
* Boot with new kernel
* Verify dmesg shows "asmc_dumpall: dumping 297 keys" (or actual count)
* Verify all 297 keys are dumped

    [5 lines not shown]
DeltaFile
+17-8sys/dev/asmc/asmc.c
+1-0sys/dev/asmc/asmcvar.h
+18-82 files

LLVM/project d92011fclang/lib/Sema SemaBoundsSafety.cpp

[clang][NFC] Fix typo in SemaBoundsSafety.cpp comments (#181585)

Minor comment fix.
DeltaFile
+1-1clang/lib/Sema/SemaBoundsSafety.cpp
+1-11 files

FreeBSD/src 75045desys/dev/asmc asmcvar.h asmc.c

asmc: Add support for MacBookPro11,5

  Add support for the MacBookPro11,5 (Mid 2015, 15-inch with AMD Radeon R9 M370X GPU)
  to the Apple SMC driver.

  Debug testing revealed this model lacks several SMC keys present on MacBookPro11,4
  (IBLC, ICMC, IC2C), that model-specific sensor definitions.

Differential Revision:  https://reviews.freebsd.org/D54665
Reviewed by:    adrian

(cherry picked from commit c498eaa2f9090d7bdc6456181d8bf74869288bbb)
DeltaFile
+35-0sys/dev/asmc/asmcvar.h
+7-0sys/dev/asmc/asmc.c
+42-02 files

FreeBSD/src f0d2b37sys/dev/asmc asmc.c

asmc: add per-fan manual mode control via sysctl

Add per-fan manual mode control via dev.asmc.0.fan.N.manual sysctl.

Apple SMCs support manual fan control via the FS! SMC key,
a 16-bit bitmask where each bit controls one fan (0=auto, 1=manual).

This change adds a new sysctl per fan:
    dev.asmc.0.fan.N.manual (0=auto, 1=manual)

When set to manual mode (1), the fan runs at the speed set via
dev.asmc.0.fan.N.targetspeed instead of automatic thermal control.  When
set to auto mode (0), the SMC controls fan speed automatically.

The FS! key was already defined in asmcvar.h but not accessible.
This exposes it for debugging, testing, and advanced fan control.

Implementation uses read-modify-write to allow independent control of
each fan without affecting others.

    [6 lines not shown]
DeltaFile
+55-0sys/dev/asmc/asmc.c
+55-01 files

FreeBSD/src 26f41f8sys/dev/asmc asmc.c asmcvar.h

asmc: improve asmc_dumpall to read actual SMC key count

The asmc_dumpall debug function previously used a hardcoded loop limit
of 0x100 (256) keys with a "XXX magic number" comment.

This change improves asmc_dumpall to:

* Read the actual number of keys from the ASMC_NKEYS SMC key
* Print the key count being dumped for better debugging output
* Loop only up to the actual key count (e.g., 297 on Mac Mini 5,1)

This provides more accurate debug output and removes the magic number.

Tested on Mac Mini 5,1 (FreeBSD 16.0-CURRENT):

* Rebuild kernel with DEBUG enabled in asmc driver
* Boot with new kernel
* Verify dmesg shows "asmc_dumpall: dumping 297 keys" (or actual count)
* Verify all 297 keys are dumped

    [5 lines not shown]
DeltaFile
+17-8sys/dev/asmc/asmc.c
+1-0sys/dev/asmc/asmcvar.h
+18-82 files

FreeBSD/src e6c36b2sys/x86/conf NOTES

sys/x86/NOTES: Add vt_efifb

Contrary to what is stated in commit f224591746bd ("Add ASMC_DEBUG make
option"), the various NOTES files should list all available options.

Since vt_efifb is supported also on i386, add it back to x86/NOTES
instead of amd64/NOTES.

Fixes:          f224591746bd ("Add ASMC_DEBUG make option")
Sponsored by:   The FreeBSD Foundation

(cherry picked from commit 67599eef01f5417715f673ec81fc1467917c7a10)
DeltaFile
+1-0sys/x86/conf/NOTES
+1-01 files

FreeBSD/src 3eddfddsys/amd64/conf NOTES, sys/conf options.amd64

Add ASMC_DEBUG make option

This allows folks to enable debug statements in asmc(4) using kernel
configs via the `options ASMC_DEBUG` directive.

While here, remove a duplicate `device vt_efifb` directive in `NOTES`
as it's already handled in the `GENERIC` config

MFC after:      1 week
Differential Revision:  https://reviews.freebsd.org/D54511

(cherry picked from commit f224591746bdaf14ad5f63de4738a3146cc2f55f)
DeltaFile
+11-9sys/dev/asmc/asmc.c
+4-3sys/amd64/conf/NOTES
+3-0sys/conf/options.amd64
+1-1sys/modules/asmc/Makefile
+19-134 files

FreeBSD/src 1bebef5share/mk googletest.test.inc.mk

Bump CXXSTD to C++17 with GoogleTest tests

This change bumps the CXXSTD to C++17 with GoogleTest 1.17.0 requires
C++17 to function and 6527682ab7058e5023a was never MFCed.

This unbreaks the build on stable/14.

This is a direct commit to stable/14.

Fixes:  227baf32d ("GoogleTest: import 1.17.0")
DeltaFile
+1-1share/mk/googletest.test.inc.mk
+1-11 files

FreeBSD/src 5a9164ccontrib/googletest/googletest/src gtest.cc

gtest.cc: declare fail_if_no_test_linked flag

Clang's -Wmissing-variable-declarations flags this as an issue since the
flag is only used in `gtest.cc`. Declare the flag beforehand to ensure
that the variable scope is properly limited to `gtest.cc`.

MFC after:      1 week
MFC with:       46333229c6a0187ebf231805682ee0bceed704d1
Ref:            https://github.com/google/googletest/pull/4898

(cherry picked from commit 3926ae98adfe4b2f1dd957cab353ba7ca11ce709)
DeltaFile
+1-0contrib/googletest/googletest/src/gtest.cc
+1-01 files

FreeBSD/src 227baf3contrib/googletest/googlemock/include/gmock gmock-matchers.h, contrib/googletest/googlemock/test gmock-matchers-containers_test.cc gmock-matchers-arithmetic_test.cc

GoogleTest: import 1.17.0

The changes between the two versions can be found in this diff of the
two release tags:
https://github.com/google/googletest/compare/v1.15.2...v1.17.0

One notable change is that GoogleTest 1.17.0 now requires C++-17 to
build.

MFC after:      1 week
Merge commit '3a4c29b5bed4ea20266ad9371fbfdc6bca088f92'

(cherry picked from commit 46333229c6a0187ebf231805682ee0bceed704d1)
DeltaFile
+347-80contrib/googletest/googlemock/include/gmock/gmock-matchers.h
+317-19contrib/googletest/googlemock/test/gmock-matchers-containers_test.cc
+210-27contrib/googletest/googlemock/test/gmock-matchers-arithmetic_test.cc
+157-34contrib/googletest/googletest/src/gtest.cc
+131-5contrib/googletest/googlemock/test/gmock-matchers-comparisons_test.cc
+95-39contrib/googletest/googletest/include/gtest/gtest-param-test.h
+1,257-20455 files not shown
+2,688-92061 files

FreeBSD/src 0029027contrib/googletest/googlemock/include/gmock gmock-matchers.h, contrib/googletest/googlemock/test gmock-matchers-containers_test.cc gmock-matchers-arithmetic_test.cc

GoogleTest: import 1.17.0

The changes between the two versions can be found in this diff of the
two release tags:
https://github.com/google/googletest/compare/v1.15.2...v1.17.0

One notable change is that GoogleTest 1.17.0 now requires C++-17 to
build.

MFC after:      1 week
Merge commit '3a4c29b5bed4ea20266ad9371fbfdc6bca088f92'

(cherry picked from commit 46333229c6a0187ebf231805682ee0bceed704d1)
DeltaFile
+347-80contrib/googletest/googlemock/include/gmock/gmock-matchers.h
+317-19contrib/googletest/googlemock/test/gmock-matchers-containers_test.cc
+210-27contrib/googletest/googlemock/test/gmock-matchers-arithmetic_test.cc
+157-34contrib/googletest/googletest/src/gtest.cc
+131-5contrib/googletest/googlemock/test/gmock-matchers-comparisons_test.cc
+95-39contrib/googletest/googletest/include/gtest/gtest-param-test.h
+1,257-20455 files not shown
+2,688-92061 files

FreeBSD/src 3342ea3contrib/googletest/googletest/src gtest.cc

gtest.cc: declare fail_if_no_test_linked flag

Clang's -Wmissing-variable-declarations flags this as an issue since the
flag is only used in `gtest.cc`. Declare the flag beforehand to ensure
that the variable scope is properly limited to `gtest.cc`.

MFC after:      1 week
MFC with:       46333229c6a0187ebf231805682ee0bceed704d1
Ref:            https://github.com/google/googletest/pull/4898

(cherry picked from commit 3926ae98adfe4b2f1dd957cab353ba7ca11ce709)
DeltaFile
+1-0contrib/googletest/googletest/src/gtest.cc
+1-01 files

FreeBSD/src c9aaf20. .clang-format

clang-format: adjust to sort C++ headers per style(9)

Many standard C++ headers do not have the .h file extension: some, such as
`iostream`, lack it; others have a .hpp file extension. Moreover, some
projects (like ATF/Kyua) also contain .ipp files, which are C++ "interface"
files.

Relax the regular expression to ensure that non-traditional C "system"
headers, C++ headers, etc, with angle brackets are sorted before
"local" headers.

MFC after:      1 week
Reviewed by: markj
Differential Revision: https://reviews.freebsd.org/D54401

(cherry picked from commit ab9b04736945537743eb0624ead7a4fa4b960783)
DeltaFile
+2-2.clang-format
+2-21 files

FreeBSD/src 7111f12. .clang-format

clang-format: adjust to sort C++ headers per style(9)

Many standard C++ headers do not have the .h file extension: some, such as
`iostream`, lack it; others have a .hpp file extension. Moreover, some
projects (like ATF/Kyua) also contain .ipp files, which are C++ "interface"
files.

Relax the regular expression to ensure that non-traditional C "system"
headers, C++ headers, etc, with angle brackets are sorted before
"local" headers.

MFC after:      1 week
Reviewed by: markj
Differential Revision: https://reviews.freebsd.org/D54401

(cherry picked from commit ab9b04736945537743eb0624ead7a4fa4b960783)
DeltaFile
+2-2.clang-format
+2-21 files

FreeBSD/src 2033efetools/build/mk OptionalObsoleteFiles.inc

usr.bin/factor: remove tests when MK_GAMES=no

factor(1) is only installed when MK_GAMES != no. Ergo, remove the tests
when that's not true.

MFC after:      1 week

(cherry picked from commit 7baa76c30c833750007e8d8823c9f5d94f5b2925)
DeltaFile
+4-0tools/build/mk/OptionalObsoleteFiles.inc
+4-01 files

LLVM/project 76af740clang/include/clang/Basic DiagnosticCommentKinds.td, clang/lib/AST CommentSema.cpp

[clang][diagnostics] Refactor `warn_doc_function_method_decl_mismatch` to use enum_select (#181769)

Related: https://github.com/llvm/llvm-project/issues/123121

This patch refactors the `warn_doc_function_method_decl_mismatch`
diagnostic to use `enum_select` instead of `select`. This gets rid of
magic numbers in its caller and improves readability.
DeltaFile
+10-12clang/lib/AST/CommentSema.cpp
+3-1clang/include/clang/Basic/DiagnosticCommentKinds.td
+13-132 files

FreeBSD/src 3c69641tools/build/mk OptionalObsoleteFiles.inc

usr.bin/tftp: remove tests when MK_TFTP=no

These tests require the tftp client, which is not installed when
`MK_TFTP=no`. Remove them when that's not true.

MFC after:      1 week

(cherry picked from commit e1f36b9db9220cf51c6c3d2d2ad230fb9490bc3e)
DeltaFile
+3-0tools/build/mk/OptionalObsoleteFiles.inc
+3-01 files

FreeBSD/src 05ce2aetools/build/mk OptionalObsoleteFiles.inc

tftpd: remove tests when MK_TFTP=no

MFC after:      1 week

(cherry picked from commit 1ccee516edb681b33182f0a57531752eb98ec838)
DeltaFile
+3-0tools/build/mk/OptionalObsoleteFiles.inc
+3-01 files

FreeBSD/src 6ba1febtools/build/mk OptionalObsoleteFiles.inc

usr.bin/tftp: remove tests when MK_TFTP=no

These tests require the tftp client, which is not installed when
`MK_TFTP=no`. Remove them when that's not true.

MFC after:      1 week

(cherry picked from commit e1f36b9db9220cf51c6c3d2d2ad230fb9490bc3e)
DeltaFile
+3-0tools/build/mk/OptionalObsoleteFiles.inc
+3-01 files

FreeBSD/src 26632bctools/build/mk OptionalObsoleteFiles.inc

tftpd: remove tests when MK_TFTP=no

MFC after:      1 week

(cherry picked from commit 1ccee516edb681b33182f0a57531752eb98ec838)
DeltaFile
+3-0tools/build/mk/OptionalObsoleteFiles.inc
+3-01 files

FreeBSD/src 68fd588tools/build/mk OptionalObsoleteFiles.inc

Remove bsnmpd tests when MK_BSNMP == no

MFC after:      1 week

(cherry picked from commit 51509500acdc5d23285a962e9c55dd9e38d2b30a)
DeltaFile
+3-0tools/build/mk/OptionalObsoleteFiles.inc
+3-01 files

FreeBSD/src d6eabaetools/build/mk OptionalObsoleteFiles.inc

Remove bsnmpd tests when MK_BSNMP == no

MFC after:      1 week

(cherry picked from commit 51509500acdc5d23285a962e9c55dd9e38d2b30a)
DeltaFile
+3-0tools/build/mk/OptionalObsoleteFiles.inc
+3-01 files

FreeBSD/src 0306b70tools/build/mk OptionalObsoleteFiles.inc

usr.bin/factor: remove tests when MK_GAMES=no

factor(1) is only installed when MK_GAMES != no. Ergo, remove the tests
when that's not true.

MFC after:      1 week

(cherry picked from commit 7baa76c30c833750007e8d8823c9f5d94f5b2925)
DeltaFile
+4-0tools/build/mk/OptionalObsoleteFiles.inc
+4-01 files

FreeBSD/src 3882602libexec/tftpd/tests functional.c

tftpd tests: clean trailing whitespace

No functional change intended.

MFC after:      1 week

(cherry picked from commit fd6217075e6a5926bdc627145b38194b6c5ba8da)
DeltaFile
+9-9libexec/tftpd/tests/functional.c
+9-91 files

FreeBSD/src 968d6accontrib/netbsd-tests/sbin/newfs_msdos t_create.sh, sbin/newfs_msdos/tests Makefile

t_create.sh: use `ATF_TESTS_SH_SED` & remove local mods

This particular change replaces all local modifications to the test
script like so:
- Use `ATF_TESTS_SH_SED_test` with a sed(1) statement in the Makefile,
  instead of the equivalent local modifications.
- Remove the need for expecting the output of newfs_msdos to be empty.
  There isn't much to gain from deviating from the upstream NetBSD test--it's
  just another local modification that would need to be carried forward. If
  it's worth testing this FreeBSD-specific behavior, it should be in a
  FreeBSD-specific test.

This makes moving new modifications to the script easier moving forward.

MFC after:      1 week

(cherry picked from commit 411a566d565277e47c9644d19a5efa0fe5b00179)
DeltaFile
+2-12contrib/netbsd-tests/sbin/newfs_msdos/t_create.sh
+2-0sbin/newfs_msdos/tests/Makefile
+4-122 files

FreeBSD/src 02d896acontrib/netbsd-tests/sbin/newfs_msdos t_create.sh, sbin/newfs_msdos/tests Makefile

t_create.sh: use `ATF_TESTS_SH_SED` & remove local mods

This particular change replaces all local modifications to the test
script like so:
- Use `ATF_TESTS_SH_SED_test` with a sed(1) statement in the Makefile,
  instead of the equivalent local modifications.
- Remove the need for expecting the output of newfs_msdos to be empty.
  There isn't much to gain from deviating from the upstream NetBSD test--it's
  just another local modification that would need to be carried forward. If
  it's worth testing this FreeBSD-specific behavior, it should be in a
  FreeBSD-specific test.

This makes moving new modifications to the script easier moving forward.

MFC after:      1 week

(cherry picked from commit 411a566d565277e47c9644d19a5efa0fe5b00179)
DeltaFile
+2-12contrib/netbsd-tests/sbin/newfs_msdos/t_create.sh
+2-0sbin/newfs_msdos/tests/Makefile
+4-122 files