lang/v8-beta: Fix calloc() returning non-zeroed memory
PartitionAlloc, which libv8.so uses to replace malloc() for the whole
process, assumes pages discarded with madvise(MADV_DONTNEED) read back
as zeros and skips zeroing them in calloc(). FreeBSD's MADV_DONTNEED
does not zero anonymous memory, so calloc() could return stale data,
corrupting V8's hash maps and crashing d8 and other libv8 consumers.
Treat BSD like Apple: report decommitted memory as not always zeroed,
and discard with MADV_FREE. www/chromium carries the same patches.
PR: 301107
lang/v8: Fix calloc() returning non-zeroed memory
PartitionAlloc, which libv8.so uses to replace malloc() for the whole
process, assumes pages discarded with madvise(MADV_DONTNEED) read back
as zeros and skips zeroing them in calloc(). FreeBSD's MADV_DONTNEED
does not zero anonymous memory, so calloc() could return stale data,
corrupting V8's hash maps and crashing d8 and other libv8 consumers.
Treat BSD like Apple: report decommitted memory as not always zeroed,
and discard with MADV_FREE. www/chromium carries the same patches.
PR: 301107
net/storj: belatedly update Storj programs to version 1.167.1
- Pass some required storj.io/common/version.build* values via
GO_LDFLAGS so storagenode can connect to satellites, sync the
clock, and the dashboard reports correct version information
- Install three new programs: jobq, jobqtool, and write-hashtbl
- Go 1.23 and later require vendored packages to be present in
modules.txt to be imported, so cache it under ${FILESDIR}
Non-M2T-friendly GitHub tag replaced with its commit hash:
open-telemetry/opentelemetry-go-contrib: v0.70.0 -> c8a87a60ba1b
Reported by: portscout
PR: 292296
Differential Revision: https://reviews.freebsd.org/D61576
devel/py-localstub: New port
localstub is a Python library and CLI for testing HTTP clients
against the behavior of a real server. It runs an asyncio HTTP
server in your test process, returns whatever responses you
configure, including error responses, slow responses, disconnects,
and records each request exactly as it arrived on the wire for
your tests to inspect.
A TLS proxy is provided so you can test your clients without
having to make any config changes, most HTTP clients support
HTTPS_PROXY and some environment variables for specifying
a CA_BUNDLE. This also lets you inspect existing HTTP clients
to see the exact bytes they are sending to servers.
Approved by: hrs (mentor)
devel/py-awscli2: New port
The AWS Command Line Interface v2 (AWS CLI) is a unified tool to
manage your AWS services from the command line.
The AWS CLI provides direct access to the public APIs of AWS
services. You can explore a service's capabilities with the AWS
CLI, and develop shell scripts to manage your resources.
In addition to the low-level, API-equivalent commands, several
AWS services provide customizations for the AWS CLI.
Customizations can include higher-level commands that simplify
using a service with a complex API.
AWS CLI v2 includes:
- Improved installation mechanism
- AWS IAM Identity Center (SSO) support
- Interactive features with auto-prompting
- Server-side auto-completion
- Built-in pagination with less
[8 lines not shown]
netmap: Clear ni_bufs_head in a new netmap_if
netmap_mem2_if_new() does not set ni_bufs_head, and the netmap_if comes
from a pool that is not zeroed, so it starts with the head of the last
extra buffer list of whoever had that netmap_if before. Only a
registration from userspace sets the field afterwards. One made by the
kernel, such as attaching a NIC to a VALE switch, keeps the old value,
and so does a registration that fails after the netmap_if was created.
netmap_mem2_if_delete() then frees that list again. When the buffer is
free this logs "ouch, double free on buffer"; when another ring has got
it in the meantime, it is freed under that ring and can be given out a
second time.
Clear the field when the netmap_if is created.
Reviewed by: vmaffione
MFC after: 2 weeks
Sponsored by: Rubicon Communications, LLC ("Netgate")
Differential Revision: https://reviews.freebsd.org/D62152
xprt_verbs.c: Don't reset the connection for all failure stats
Without this patch, rpcrdma_unmap() fails the RDMA connection
for all RPC stat returns other than RPC_SUCCESS.
This patch allows the connection to remain for certain failures:
- RPC_AUTHERR, which can happen when a Kerberos TGT expires.
- RPC_INTR, RPC_TIMEDOUT, which can happen for "intr" or "soft"
mounts.
Reported by: llm-postcr
MFC after: 1 month
Fixes: 80bee4d83637 ("nfsclrdma: Add code to support client side NFS over RDMA")
ietp(4): Expect I2C address provided by iicbus(4) to be in 8-bit format
Since rGb2dbfc7b7701 ("acpi_iicbus: shift the ACPI slave address into the
form iicbus(4) stores"), iicbus_get_addr() returns an 8-bit slave address
on acpi_iicbus(4) to match iicbus(4) and ofw_iicbus(4).
iichid(4) was updated in rGafe3bfec65da, but ietp(4) still left-shifts
iicbus_get_addr(iichid) in ietp_iic_identify(), ietp_iic_read_reg(), and
ietp_iic_write_reg() before issuing I2CRDWR transfers via iichid_ioctl().
Drop the redundant shifts so the slave address is not shifted twice.
Fixes: b2dbfc7b7701 ("acpi_iicbus: shift the ACPI slave address into the form iicbus(4) stores")
Reviewed by: wulf
Differential Revision: https://reviews.freebsd.org/D62164
xhci: read HCIVERSION as part of the first capability word
Some controllers apparently do not like accesses non-aligned to 32bits,
even when only reading 8 or 16 bits.
Commit 6d5c80aee3ae made it so we unconditionally read XHCI_HCIVERSION
with a 16bits read, which panics on my Radxa Orion O6. This gives a
SError, with the firmware reporting "IDM: USB3CH0 non-secure access".
Instead, do a 32bits read on XHCI_CAPLENGTH, which is properly aligned,
and shift it to get the value of XHCI_HCIVERSION. This is what Linux
does too.
Reviewed by: aokblast, seuros
Differential Revision: https://reviews.freebsd.org/D62132
MFC after: 3 days (with 6d5c80aee3ae, as it gets MFC'd)
devel/pyotherside-qt5: Update and switch to Qt6
While here:
- Do not install qtquicktests test binary.
- Add testing support.
- Append opengl to USE_GL.
PR: 289587
Approved by: daniel at shafer.cc (maintainer timeout, 1+ year)
acpi: Add acpi_fan
Implemet acpi fan driver for controlling fan device defined in ACPI
standard. We implement level mode and step mode currently and provides
sysctls to control it.
In level mode, we have exposes n numbers of level can be choosen. People
writes the Ctrl value to set_level node to get desired value.
In step mode, people can write abitrary value (automatically rounddown
to the multiple of step) to set_level.
The full spec is in:
https://uefi.org/htmlspecs/ACPI_Spec_6_4_html/11_Thermal_Management/fan-device.html
Reviewed by: seuros, zaiee
Tested by: rz_fabmicro.ru
Sponsored by: The FreeBSD Foundation
Differential Revision: https://reviews.freebsd.org/D55592