Update sys.dirdeps.mk set default DEP_*
Even at level 0 it is handy to default DEP_*
used by Makefile.depend* to aid the first include if
in a leaf dir.
Reviewed by: stevek
sound: Remove obsolete DV_F_* flags
The ISA sound drivers that used them are retired.
Last reference of DV_F_DRQ_MASK and DV_F_DUAL_DMA:
716924cb4832ea0a440daf09913a06f3166f243e ("Retire snd_sbc ISA sound card
driver")
Last reference of DV_F_DEV_MASK and DV_F_DEV_SHIFT:
5126e5eeeb5e07ceef3c809452a8c9f508b2d4d1 ("Retire snd_mss ISA sound card
driver")
Sponsored by: The FreeBSD Foundation
MFC after: 1 week
Reviewed by: markj, emaste
Differential Revision: https://reviews.freebsd.org/D44858
sound: Get rid of snddev_info->devcount
snddev_info->devcount keeps track of the total number of channels for a
given device. However, it is redundant to have it, since it is only used
in sound_oss_sysinfo() to populate the "numaudios" field, and we also
keep track of the channel counts in the playcount, pvchancount, reccount
and rvchancount fields anyway. We can simply sum those fields together
instead of updating a separate variable upon every channel
addition/deletion.
Sponsored by: The FreeBSD Foundation
MFC after: 1 week
Reviewed by: markj
Differential Revision: https://reviews.freebsd.org/D44852
sound: Simplify unit fetching in dsp_oss_audioinfo()
"i" keeps the value of the current unit, so we do not have to call
PCMUNIT() and device_get_unit() to fetch it.
In the mixer case, I think it is more correct to do it like this, since
mixer and DSP device units have a 1-1 relationship (i.e the mixer unit
is always the same as the corresponding DSP device one) and that way we
can make it more clear.
Sponsored by: The FreeBSD Foundation
MFC after: 1 week
Reviewed by: markj
Differential Revision: https://reviews.freebsd.org/D44855
sound: Remove obsolete chn_setvolume()
It is marked as obsolete and there are no consumers of it anymore.
Sponsored by: The FreeBSD Foundation
MFC after: 1 week
Reviewed by: markj, emaste
Differential Revision: https://reviews.freebsd.org/D44853
sound: Call device_get_name() and device_get_unit() only once in mixer_init()
No functional change intended.
Sponsored by: The FreeBSD Foundation
MFC after: 1 week
Reviewed by: markj, emaste
Differential Revision: https://reviews.freebsd.org/D44840
sound: Be more verbose with virtual channel descriptions
Non-virtual channel description denote "play" or "record", so do the
same for virtual ones as well.
Sponsored by: The FreeBSD Foundation
MFC after: 1 week
Reviewed by: markj, emaste
Differential Revision: https://reviews.freebsd.org/D44839
tcp: drop data received after a FIN has been processed
RFC 9293 describes the handling of data in the CLOSE-WAIT, CLOSING,
LAST-ACK, and TIME-WAIT states:
This should not occur since a FIN has been received from the remote
side. Ignore the segment text.
Therefore, implement this handling.
Reviewed by: rrs, rscheff
MFC after: 3 days
Sponsored by: Netflix, Inc.
Differential Revision: https://reviews.freebsd.org/D44746
Fix "set but not used" for the sym driver.
Sponsored by: Rubicon Communications, LLC ("Netgate")
(cherry picked from commit 5045cb8f18f9f79354f93174ba7f9fd2f7ea6994)
fib_algo(4): Lower level of algorithm switching messages to LOG_INFO
Otherwise, with the default flm_debug_level of LOG_NOTICE, it's rather
easy to trigger debug messages such as:
[fib_algo] inet.0 (bsearch4#18) rebuild_fd_flm: switching algo to
radix4_lockless
Also, the "severity" of these events generally only justifies LOG_INFO
and not LOG_NOTICE.
Reviewed by: melifaro
(cherry picked from commit ed81a15517b8a8f587fd7282c3690513bb798242)
fib_algo(4): Lower level of algorithm switching messages to LOG_INFO
Otherwise, with the default flm_debug_level of LOG_NOTICE, it's rather
easy to trigger debug messages such as:
[fib_algo] inet.0 (bsearch4#18) rebuild_fd_flm: switching algo to
radix4_lockless
Also, the "severity" of these events generally only justifies LOG_INFO
and not LOG_NOTICE.
Reviewed by: melifaro
(cherry picked from commit ed81a15517b8a8f587fd7282c3690513bb798242)
CONTRIBUTING: request only one submission type per change
We have some instances of contributors opening a GitHub pull request and
a Phabricator review for the same change, which divides or duplicates
review effort.
Reviewed by: markj
Sponsored by: The FreeBSD Foundation
Differential Revision: https://reviews.freebsd.org/D44856
CONTRIBUTING: mention sys/crypto as another "contrib" directory
Reviewed by: imp
Sponsored by: The FreeBSD Foundation
Differential Revision: https://reviews.freebsd.org/D44857
share/mk/bsd.cpu.mk: add F16C feature for i386 and amd64 architectures
As discussed in bug 278417, some ports require the F16C instruction set
to compile, but there is no way yet to detect whether the currently
chosen CPUTYPE supports this feature.
Add the feature to the MACHINE_CPU variable, for each processor that
supports it. The list of processors was extracted from clang 18's -dM
output, filtered on the __F16C__ define.
PR: 278417
Reviewed by: brooks, emaste
MFC after: 3 days
Differential Revision: https://reviews.freebsd.org/D44848
kassert.h: update MPASS definition commentary
We now have a detailed man page describing both MPASS and KASSERT. Give
a warning that careless use of MPASS can result in inadequate assertion
messages, and point to the MPASS(9) page which describes this.
While here add a comment above the KASSERT definitions pointing to the
man page.
Suggested by: bz
Reviewed by: emaste
MFC after: 1 week
Sponsored by: The FreeBSD Foundation
Differential Revision: https://reviews.freebsd.org/D44438
(cherry picked from commit 36de8bb226671ef9fe373d8d95f77cdb76157738)
KASSERT(9): describe history of MPASS
The macro originates from BSD/OS, with a different etymology than what
is presented. Add a brief HISTORY section to capture this.
Reviewed by: emaste
MFC after: 1 week
Sponsored by: The FreeBSD Foundation
Differential Revision: https://reviews.freebsd.org/D44439
(cherry picked from commit 5d956e11ed3713ff769d51b71f7b4ee6ce0085fe)
cp: Remove useless ssize_t cast
Both wcount and wresid are ssize_t so this cast is not needed. Just
remove it so the code is easier to read.
Signed-off-by: Collin Funk <collin.funk1 at gmail.com>
Reviewed by: emaste, zlei
Pull Request: https://github.com/freebsd/freebsd-src/pull/1116
(cherry picked from commit 8b864151856fbba97fed16b1200248cf9f6f3ccf)
em.4: add interfaces to name section
Improving first-glance comprehension that this manual page applies to
igb/lem interfaces provided by the em(4) driver.
While here, tag SPDX, link the framework, and shuffle a sentence to fix
linter warning.
Co-authored-by: mhorne
Reviewed by: mhorne
MFC after: 1 week
Pull Request: https://github.com/freebsd/freebsd-src/pull/1134
(cherry picked from commit 501f7e7bf847c66e3869b533805e76897e4685b9)
simple_mfd: don't attach children twice
Trying to probe+attach the child device at the point it is added comes
before the syscon handle is set up (if relevant). It will therefore be
unavailable to the attach method which is expecting it, and the first
attempt to attach the device will fail.
Just rely on the call to bus_generic_attach() at the end of the function
to perform probe+attach of dev's children.
Reviewed by: manu
MFC after: 1 week
Sponsored by: The FreeBSD Foundation
Differential Revision: https://reviews.freebsd.org/D44268
(cherry picked from commit accda781531788a814bc438e1e96ef544c12aeaf)
clk_fixed: call clkdom_dump() for verbose boot
This is standard practice for clock drivers that register clocks
dynamically. Nothing else uses the CLK_DEBUG macro.
The result is that the name and frequency of the fixed clock is printed
for a verbose boot, which may aid in debugging.
Reviewed by: manu
MFC after: 1 week
Sponsored by: The FreeBSD Foundation
Differential Revision: https://reviews.freebsd.org/D44265
(cherry picked from commit 6e66bb9fc3d026765113fa1258cd12292da9309a)