libpfctl: decode PFR_A_AF into a u8
The kernel sends PFR_A_AF as a u32, although it is documented and
parsed as a u8, and libpfctl decoded it with snl_attr_get_uint32()
straight into the u8 pfra_af. That overwrote pfra_net, pfra_not and
pfra_fback, and left pfra_af zero on big-endian hosts.
Decode it via a temporary, and accept a u8 as well, so that the
kernel can be corrected later without breaking libpfctl.
Reviewed by: kp
Approved by: kp (mentor)
Fixes: f27e44e2e3b5 ("pf: convert DIOCRGETADDRS to netlink")
Sponsored by: Rubicon Communications, LLC ("Netgate")
Differential Revision: https://reviews.freebsd.org/D60110
net/samba424: restore missing FreeBSD fdescfs support in lib/system.c
net/samba419, net/samba420, net/samba422 and net/samba423 all carried
a patch (originally 0028-s3-lib-system-add-FreeBSD-proc_fd_pattern.patch
by Timur I. Bakeyev, adapted for Samba 4.20 by Andrea Venturoli) that
teaches sys_have_proc_fds()/sys_proc_fd_path() in source3/lib/system.c
to recognize FreeBSD's fdescfs mount as an equivalent to Linux's
/proc/self/fd. This patch was dropped when net/samba424 was created
and was never carried forward.
Without it, upstream's sys_have_proc_fds() only ever checks
"/proc/self/fd/0", which does not exist on stock FreeBSD, so
fsp->fsp_flags.have_proc_fds is always false. That flag gates the
race-free pathref-fd-to-path resolution branches in
patch-source3_modules_vfs__zfsacl.c and patch-source3_modules_vfs__freebsd.c,
so without it both modules silently fall back to a less secure,
non-race-free path-based lookup instead of the fdescfs-backed path
that samba419's r24fbb5209481 ("Use a simple approach to reconcile
O_PATH and vfs_zfsacl") was built around.
[24 lines not shown]
Revert "zpool: Add zpool status -vv error ranges"
This reverts commit e903655c50fe2e710a4cdfe6e638454012ef6324.
The commit comes from the OpenZFS merge.
OpenZFS introduced in d2f5cb3a5 two new libraries: libbtree and
librange_tree. We don't have these in our build.
To keep diffs as minimal as possible and avoid future breakages we
should import these for the FreeBSD build with bells and whistles.
After this issue is resolved, e903655c5 can be re-committed.
snd_uaudio: Read the UAC2 sample rate back after setting it
Some devices only apply a new sample rate once it has been read back,
and produce no sound at all otherwise.
PR: 294803
Reported by: tatsuki_makino at hotmail.com
Tested by: tatsuki_makino at hotmail.com
MFC after: 2 weeks
Sponsored by: The FreeBSD Foundation
Reviewed by: emaste
Differential Revision: https://reviews.freebsd.org/D59616
(cherry picked from commit 694923501f56a5d4519f548ee06db603f9486bc7)
net/samba424: fix sys_proc_fd_path() buffer type in vfs_freebsd.c
At all 5 call sites, vfs_freebsd.c declared a plain "char buf[PATH_MAX]"
and passed its address to sys_proc_fd_path(fd, &buf). Samba 4.24
changed that function's signature to
"char *sys_proc_fd_path(int fd, struct sys_proc_fd_path_buf *buf)",
so "&buf" here has type "char (*)[PATH_MAX]", not the expected
"struct sys_proc_fd_path_buf *" - a type mismatch left over from an
incomplete migration of this patch to the new API (the sibling
patch-source3_modules_vfs__zfsacl.c was already updated correctly).
Change all 5 declarations to "struct sys_proc_fd_path_buf buf;" to
match the current signature.
PR: 298884
Co-Authored-By: Claude Sonnet 5 <noreply at anthropic.com>
Approved by: samba (kiwi)
stand/powerpc/ofw: do not truncate device tree properties to 1024 bytes
When the OpenFirmware loader flattens the firmware device tree into the
FDT it hands to the kernel (usefdt=1, i.e. on every real-mode OF system
such as pSeries LPARs and QEMU pseries guests), add_node_to_fdt() clamps
every property value to 1024 bytes. Any larger property reaches the
kernel truncated.
On QEMU pseries the PCI host bridge's "interrupt-map" is 3584 bytes
(32 slots x 4 pins x 7 cells), so only the entries for slots 0-8 survive
and the entry for slot 9 is cut in the middle. A PCI device in slot 9
or above therefore gets no INTx routing (irq 0), and with INVARIANTS the
partial trailing entry trips the "ofw_bus_search_intrmap: truncated map"
assertion in ofw_bus_search_intrmap() during PCI attach, panicking the
kernel as soon as such a device is present. "ibm,drc-indexes",
"ibm,drc-names" and "ibm,drc-power-domains" are cut the same way.
Drop the clamp. fdt_setprop() already reports a property that does not
fit into the FDT buffer, so no separate limit is needed.
[4 lines not shown]
net/samba424: fix swapped paths/targetdir args in join.py provision_fill call
patch-python_samba_provision_____init____.py extends provision_fill()'s
signature to provision_fill(..., paths, targetdir, schema=None, ...),
but the DCJoinContext call site in patch-python_samba_join.py passed
the two positional arguments in the opposite order (targetdir, paths).
This silently bound paths to a plain targetdir string and targetdir to
the ProvisionPaths object, which would raise AttributeError as soon as
provision_fill() accesses paths.netlogon/paths.sysvol.
Present identically since net/samba422 (join.py was not touched at all
in net/samba419) and carried forward unnoticed through samba423 and
samba424. Only reachable via the AD DC subdomain-join code path
(DCJoinContext), not via a fresh/root-domain provision.
PR: 298883
Co-Authored-By: Claude Sonnet 5 <noreply at anthropic.com>
Aproved by: samba (kiwi)
www/mod_wsgi: Update to 6.1.0
mod_wsgi has been upgraded to major version 6 with several potentially
breaking changes. Read the release notes very carefully:
https://modwsgi.readthedocs.io/en/latest/release-notes.html
PR: 298961
Approved by: douglas at douglasthrift.net (maintainer)
net/samba424: fix dropped %%GDB_CMD%% and %%SAMBA4_CONFIG%% placeholders
patch-buildtools_scripts_abi__gen.sh hardcoded the abi_gen.sh gdb
invocation to "true" instead of the %%GDB_CMD%% placeholder that the
port's post-patch target substitutes via _GDB_CMD. This made the
Makefile's REINPLACE_CMD for %%GDB_CMD%% a dead no-op and silently
disabled real gdb-based ABI/symbol-version checking under the
DEVELOPER option, even though the devel/gdb dependency is still pulled
in for that option.
patch-dynconfig_wscript hardcoded the CONFIGFILE path to smb4.conf
instead of the %%SAMBA4_CONFIG%% placeholder, making the corresponding
REINPLACE_CMD for %%SAMBA4_CONFIG%% a dead no-op too. Harmless in
practice since _SAMBA_CONFIG already equals smb4.conf, but it silently
removes the ability to reconfigure the config file name through the
mechanism the Makefile provides for it.
Restore both placeholders so the existing substitution logic in the
Makefile actually takes effect again.
[4 lines not shown]
zfs: merge openzfs/zfs at 1f380a4f3
Notable upstream pull request merges:
#17864 e903655c5 zpool: Add zpool status -vv error ranges
#18820 -multiple zdb: account pending DDT-log frees in leak detection
#18884 -multiple zio_crypt: establish platform interface; rework common
code to use it
#19010 -multiple zfs_namecheck: reject '.' and '..' before a snapshot or
bookmark
#19031 994fb1703 Fix metaslab count assertion in metaslab_group_alloc()
for small vdevs
#19093 f5b2fc8e2 zfs_ctldir: make .zfs/snapshot/<name> btime the snapshot
creation time
#19097 2dece2a34 zstream: report invalid record context without assertions
#19102 78f49e1dd vdev_disk: simplify alignment checks for linear ABDs
#19108 -multiple Fix permanent errors misfiled into the scrub error log
#19110 fa4bc4dec spa_errlog: don't let one unresolvable entry hide the
whole error log
#19116 b6dde8a17 zio_crypt: free the key unwrap uios when decryption fails
[13 lines not shown]