FreeBSD/src 7622906. Makefile.inc1

pkgbase: fix kernel packing after switch ucl rework
DeltaFile
+12-11Makefile.inc1
+12-111 files

FreeBSD/src f8e46fd. Makefile.inc1, release/packages generate-ucl.sh generate-ucl.lua

pkgbase: rework certctl package to only run rehash on the main package

Rework how ucl manifest are generated leveraging ucl features and flua

now the ucl generation is done via a lua script which uses libucl to
ingest the template and use variables as defined in its command line.

the template will include only if it exist a ucl file named after the
package name which will complement the template or overwrite what was
defined in the template if defined in this specific ucl file

this allows to overwrite license, but add script only to the packages
who actually needs them.

As a results the post install scripts are now only added to the right
package and not also added to the subpackages like -man or -dev

Reviewed by:    markj
Differential Revision:  https://reviews.freebsd.org/D44374
DeltaFile
+33-27Makefile.inc1
+14-22release/packages/generate-ucl.sh
+35-0release/packages/generate-ucl.lua
+5-21release/packages/runtime.ucl
+2-19release/packages/utilities.ucl
+0-18release/packages/jail.ucl
+89-10717 files not shown
+104-28223 files

FreeBSD/src 9fd6283usr.sbin/diskinfo diskinfo.8 diskinfo.c

diskinfo(8): introduce new option -l

In modes -p or -s, add an option -l to start each line
with a device name separated with a tab. Update the manual page.
Add an example to list names with corresponding serial numbers:

diskinfo -ls /dev/da?

(cherry picked from commit e333110d1de748e50051d1305b5438d1bc54eeb4)
DeltaFile
+20-3usr.sbin/diskinfo/diskinfo.8
+12-3usr.sbin/diskinfo/diskinfo.c
+32-62 files

FreeBSD/src 947d9b0usr.sbin/diskinfo diskinfo.8 diskinfo.c

MFC: diskinfo(8): introduce new option -l

In modes -p or -s, add an option -l to start each line
with a device name separated with a tab. Update the manual page.
Add an example to list names with corresponding serial numbers:

diskinfo -ls /dev/da?

(cherry picked from commit e333110d1de748e50051d1305b5438d1bc54eeb4)
DeltaFile
+20-3usr.sbin/diskinfo/diskinfo.8
+12-3usr.sbin/diskinfo/diskinfo.c
+32-62 files

FreeBSD/src 229bdf3usr.bin/mkimg mkimg.c mkimg.1

mkimg(1): MFC: process non-seekable output gracefully

mkimg may make severe load only to fail in the end
if output is non-seekable pipe, socket or FIFO
unless output format is raw disk image.

Check it out and fail early. Make it clear in the manual.

(cherry picked from commit 7f0dc6e2cdfa0317c9917dd46e9da9d3897a8fbb)
DeltaFile
+13-1usr.bin/mkimg/mkimg.c
+2-1usr.bin/mkimg/mkimg.1
+15-22 files

FreeBSD/src c7f1512usr.bin/mkimg mkimg.c mkimg.1

MFC: mkimg(1): process non-seekable output gracefully

mkimg may make severe load only to fail in the end
if output is non-seekable pipe, socket or FIFO
unless output format is raw disk image.

Check it out and fail early. Make it clear in the manual.

(cherry picked from commit 7f0dc6e2cdfa0317c9917dd46e9da9d3897a8fbb)
DeltaFile
+13-1usr.bin/mkimg/mkimg.c
+2-1usr.bin/mkimg/mkimg.1
+15-22 files

FreeBSD/src 6561c0eusr.bin/diff diff.1

diff: Improve history section.

Reviewed by:    gbe
Differential Revision:  https://reviews.freebsd.org/D44409
DeltaFile
+8-6usr.bin/diff/diff.1
+8-61 files

FreeBSD/src 785600dusr.sbin/kldxref elf.c ef.c

kldxref: Properly handle reading strings near the end of an ELF file

If a string is at or near the end of an input file and the amount of
remaining data in the file is smaller than the maximum string size,
the pread(2) system call would return a short read which is treated as
an error.  Instead, add a new helper function for reading a string
which permits short reads so long as the data read from the file
contains a terminated string.

Reported by:    jrtc27
Reviewed by:    jrtc27
Sponsored by:   University of Cambridge, Google, Inc.
Differential Revision:  https://reviews.freebsd.org/D44419
DeltaFile
+18-0usr.sbin/kldxref/elf.c
+1-8usr.sbin/kldxref/ef.c
+1-8usr.sbin/kldxref/ef_obj.c
+4-0usr.sbin/kldxref/ef.h
+24-164 files

FreeBSD/src a8eb3b3stand/forth loader.4th

loader.4th dictthreshold too small

The dictthreshold in stand/forth/loader.4th is too small
resulting in full dictionary.

Reviewed by:    stevek, imp
Sponsored by:   Juniper Networks, Inc.
Differential Revision:  https://reviews.freebsd.org/D44414
DeltaFile
+2-2stand/forth/loader.4th
+2-21 files

FreeBSD/src 01f3abbstand/uboot Makefile

uboot/Makefile move BINDIR

Set BINDIR before we include bsd.init.mk
so we can override it via local.init.mk

Reviewed by:    imp
Sponsored by:   Juniper Networks, Inc.
Differential Revision:  https://reviews.freebsd.org/D44413
DeltaFile
+2-1stand/uboot/Makefile
+2-11 files

FreeBSD/src 8f13abbusr.sbin/nfsd nfsd.8

nfsd.8: Document ways to minimize Copy operation times

For NFSv4.2, a Copy operation can take a long time to complete.
If there is a concurrent ExchangeID or DelegReturn operation
which requires the exclusive lock on all NFSv4 state, this can
result in a stall of the nfsd server.

This patch documents ways to avoid this problem.

This is a content change.

Reviewed by:    karels, wollman, pauamma_gundo.com (manpages)
MFC after:      2 weeks
Differential Revision:  https://reviews.freebsd.org/D44395
DeltaFile
+23-1usr.sbin/nfsd/nfsd.8
+23-11 files

FreeBSD/src d413597usr.bin/calendar/calendars calendar.freebsd

add myself(oh) to the calendar

Reported by: McKusick
Approved by: Manu (mentor)
Differential Revision: https://reviews.freebsd.org/D44408
DeltaFile
+1-0usr.bin/calendar/calendars/calendar.freebsd
+1-01 files

FreeBSD/src 60bc961sys/kern kern_vnodedumper.c, sys/sys param.h kerneldump.h

kerneldump: add livedump_start_vnode(9)

livedump_start_vnode(9) is introduced such that the live minidump on the
system could take a vnode. This interface could be used to extend support
for the existing framework in downstream.

Bump __FreeBSD_version for introducing livedump_start_vnode(9).

Sponsored by:   Juniper Networks, Inc.
Reviewed by:    khng
Differential Revision:  https://reviews.freebsd.org/D43471
DeltaFile
+23-9sys/kern/kern_vnodedumper.c
+1-1sys/sys/param.h
+1-0sys/sys/kerneldump.h
+25-103 files

FreeBSD/src e34ea01sys/netinet tcp_timer.c tcp_subr.c

tcp: clear all TCP timers in tcp_timer_stop() when in callout

When a TCP callout decides to disable self, e.g. tcp_timer_2msl() calling
tcp_close(), we must also clear all other possible timers.  Otherwise,
upon return, the callout would be scheduled again in tcp_timer_enter().

Revert 57e27ff07aff, which was a temporary partial revert of otherwise
correct 62d47d73b7eb, that exposed the problem being fixed now.  Add an
extra assertion in tcp_timer_enter() to check we aren't arming callout for
a closed connection.

Reviewed by:    rscheff
DeltaFile
+4-2sys/netinet/tcp_timer.c
+1-2sys/netinet/tcp_subr.c
+5-42 files

FreeBSD/src 576fbcbusr.bin/calendar/calendars calendar.freebsd

Add myself (rcm) to the calendar.

Reminded by:    mckusick
DeltaFile
+1-0usr.bin/calendar/calendars/calendar.freebsd
+1-01 files

FreeBSD/src f50322cshare/man/man9 random.9

random(9): bump removal to FreeBSD 15.0

It has not yet been removed, and still has some in-tree consumers.

PR:             277655
Sponsored by:   The FreeBSD Foundation
DeltaFile
+2-2share/man/man9/random.9
+2-21 files

FreeBSD/src d9108adtools/build depend-cleanup.sh

lib{c,sys}: really fix incremental builds

Reported by:    andrew
Fixes:          a650ec0e55a9 lib{c,sys}: fix incremental builds
DeltaFile
+2-2tools/build/depend-cleanup.sh
+2-21 files

FreeBSD/src e29be07share/man/man4 tcp_rack.4

tcp_rack.4: Update the SEE ALSO section

Correct the surname of one of authors of RFC 8985 and add RFC 5681 and
RFC 6937 (PRR: Proportional Rate Reduction for TCP).

Reviewed by:    tuexen
MFC after:      1 week
Differential Revision:  https://reviews.freebsd.org/D44399
DeltaFile
+18-2share/man/man4/tcp_rack.4
+18-21 files

FreeBSD/src c85d75ausr.bin/calendar/calendars calendar.freebsd

Add myself (harti) to the calendar.

Reminded by:    mckusick
DeltaFile
+1-0usr.bin/calendar/calendars/calendar.freebsd
+1-01 files

FreeBSD/src 0a5f791sys/arm64/arm64 gdb_machdep.c

arm64: Return all registers to gdb when able

When the kdb thread is the current thread we read the registers from
the trap frame. As this contains all general purpose registers we can
use it to read these in the gdb stub. This allows us to include the
non-callee saved registers, e.g. function arguments.

Reviewed by:    imp
Sponsored by:   Arm Ltd
Differential Revision:  https://reviews.freebsd.org/D44360
DeltaFile
+4-0sys/arm64/arm64/gdb_machdep.c
+4-01 files

FreeBSD/src a931b85sys/dev/uart uart_cpu_acpi.c uart_cpu_acpi.h

uart: Add uart_cpu_acpi_setup to setup the uart

In preperation for adding debug port support add a generic function
to setup the uart from ACPI tables.

Reviewed by:    imp
Sponsored by:   Arm Ltd
Differential Revision:  https://reviews.freebsd.org/D44358
DeltaFile
+11-5sys/dev/uart/uart_cpu_acpi.c
+2-2sys/dev/uart/uart_cpu_acpi.h
+1-1sys/dev/uart/uart_cpu_arm64.c
+1-1sys/dev/uart/uart_cpu_x86.c
+15-94 files

FreeBSD/src 473c0b4sys/dev/uart uart_cpu_acpi.c

uart: Split out initilisation of the acpi devinfo

Split out the common parts of building the uart devinfo from ACPI
tables from the SPCR parser. This will be used when we support the DBG2
table to find the debug uart to be used by the kernel gdb stub.

Reviewed by:    imp
Sponsored by:   Arm Ltd
Differential Revision:  https://reviews.freebsd.org/D44357
DeltaFile
+72-60sys/dev/uart/uart_cpu_acpi.c
+72-601 files

FreeBSD/src 801160fsys/arm64/arm64 locore.S

arm64: Rename drop_to_el1 to enter_kernel_el

In the future we may not drop to EL1, e.g. when we support FEAT_VHE
where the kernel runs in EL2.

Reviewed by:    emaste, imp
Sponsored by:   Arm Ltd
Differential Revision:  https://reviews.freebsd.org/D43976
DeltaFile
+6-6sys/arm64/arm64/locore.S
+6-61 files

FreeBSD/src e5c1ba9sys/netlink/route route.h

netlink: fix route protocol constant values to match Linux

Although these particular constants aren't supported, the incorrect
values break bird 2.15 operation.

PR:             277618
Reported by:    Ondrej Zajicek <santiago at crfreenet.org>

(cherry picked from commit 16f8d8829472dfdf6b3b2bb21d652f0bafefccbc)
DeltaFile
+2-2sys/netlink/route/route.h
+2-21 files

FreeBSD/src d45714asys/netlink/route route.h

netlink: fix route protocol constant values to match Linux

Although these particular constants aren't supported, the incorrect
values break bird 2.15 operation.

PR:             277618
Reported by:    Ondrej Zajicek <santiago at crfreenet.org>

(cherry picked from commit 16f8d8829472dfdf6b3b2bb21d652f0bafefccbc)
DeltaFile
+2-2sys/netlink/route/route.h
+2-21 files

FreeBSD/src dd7b86esys/netinet tcp_usrreq.c tcp_output.c, sys/netinet/tcp_stacks rack.c bbr.c

tcp: remove IS_FASTOPEN() macro

The macro is more obfuscating than helping as it just checks a single flag
of t_flags.  All other t_flags bits are checked without a macro.

A bigger problem was that declaration of the macro in tcp_var.h depended
on a kernel option.  It is a bad practice to create such definitions in
installable headers.

Reviewed by:            rscheff, tuexen, kib
Differential Revision:  https://reviews.freebsd.org/D44362
DeltaFile
+18-17sys/netinet/tcp_stacks/rack.c
+13-13sys/netinet/tcp_stacks/bbr.c
+7-8sys/netinet/tcp_usrreq.c
+7-7sys/netinet/tcp_output.c
+7-7sys/netinet/tcp_input.c
+0-8sys/netinet/tcp_var.h
+52-602 files not shown
+54-628 files

FreeBSD/src 97bfe58usr.sbin/crunch/crunchgen crunchgen.c

crunchgen: slap a dependency on the generated makefile for .lo

crunchgen generates a foo.lo for each binary it will end up crunching
into the final product.  While they have a dependency on the libs that
are used to link them, nothing will force relinking if the set of libs
needed to link them is changed.  Because of this, incremental builds may
not be possible if one builds a version of, e.g., rescue/ with a broken
set of libs specified for a project -- a subsequent fix won't be rolled
in cleanly, it will require purging the rescue/ objdir.

This is a bit crude, but the foo.mk we generate doesn't actually get
regenerated all that often in practice, so a spurious relink for the
vast majority of crunched objects won't actually happen all that often.

Reviewed by:    bapt, emaste, imp

(cherry picked from commit 6e2cfb24ee87fec0f538d04cd69d76a8d58c324f)
DeltaFile
+2-2usr.sbin/crunch/crunchgen/crunchgen.c
+2-21 files

FreeBSD/src efb74e1lib/libsysdecode sysdecode_mask.3 flags.c

libsysdecode: add a decoder for pollfd events

We'll use this in another change to read pollfd arrays coming from a
successful poll(2) operation.

Reviewed by:    bapt, jhb

(cherry picked from commit bd23e71f91ceec5dfdffc28bbd0020849fdd20b4)
DeltaFile
+11-1lib/libsysdecode/sysdecode_mask.3
+8-0lib/libsysdecode/flags.c
+1-0lib/libsysdecode/mktables
+1-0lib/libsysdecode/Makefile
+1-0lib/libsysdecode/sysdecode.h
+22-15 files

FreeBSD/src 160788csys/kern sys_generic.c uipc_syscalls.c, sys/netinet sctp_syscalls.c

ktrace: log genio events on failed write

Visibility into the contents of the buffer when a write(2) has failed
can be immensely useful in debugging IPC issues -- pushing this to
discuss the idea, or maybe an alternative where we can set a flag like
KTRFAC_ERRIO to enable it.

When a genio event is potentially raised after an error, currently we'll
just free the uio and return.  However, such data can be useful when
debugging communication between processes to, e.g., understand what the
remote side should have grabbed before closing a pipe.  Tap out the
entire buffer on failure rather than simply discarding it.

Reviewed by:    kib, markj

(cherry picked from commit 47ad4f2d45e406c6316909bc12bc760b2fdd6afb)
DeltaFile
+4-2sys/netinet/sctp_syscalls.c
+2-1sys/kern/sys_generic.c
+2-1sys/kern/uipc_syscalls.c
+1-1sys/kern/kern_ktrace.c
+9-54 files

FreeBSD/src b983d4fusr.bin/kdump kdump.c

kdump: decode pollfd struct arrays coming from poll(2)

We'll handle these just as we do kevents, one per line with subsequent
lines indented sufficiently to distinguish them from the upcoming
return value.

Sample, with indentation stripped and revents changed to '...' in the
first one to keep the line length down:

CALL  poll(0x820610560,0x3,0)
STRU  struct pollfd[] = { { fd=0, events=0x1<POLLIN>, revents=0x11<...>
 { fd=1, events=0x4<POLLOUT>, revents=0x4<POLLOUT>}
 { fd=-1, events=0x4<POLLOUT>, revents=0} }
RET   poll 2

Reviewed by:    bapt, jhb

(cherry picked from commit 02c57f7b48772c5ec4e3a0a3405273b387b9bb08)
DeltaFile
+20-0usr.bin/kdump/kdump.c
+20-01 files