[DAG] Scalarise trivial splat operations (#226257)
This fixes an issue reported on #224255, where a single active lane
masked store is converted to a v1f16 extract_subvector, which becomes a
v1f16 splat, which fails to scalarize. Add the necessary trivial
scalarisation of the splat by using the f16 input operand.
(I was originally going to fix this by generating a scalar f16 extract
directly (which would have the benefit of treating f16 as legal), but
that seems to cause a regression in 2 x86 tests).
[clang][CIR] Add tests for SVE ADDV intrinsics (#225648)
This adds CIR tests for `svaddv` (plain SVE) intrinsics following the
task description in
[223963](https://github.com/llvm/llvm-project/issues/223963).
Moves and adapts `sve-intrinsics/acle_sve_addv.c` to `sve/addv.c`.
Drop the S3 service's status code from two docstrings
A reader of a dataset property check in middleware has no use for the
code the S3 service answers a client with. Both now say what the check
is for instead.
Add bucket recovery APIs
There are various situations in which we can have orphaned
buckets. Examples include:
* bucket is deleted and admin wants to reinstate.
* the NAS is disaster recovery instance and needs to activate
buckets after switching datasets to read-write.
This is facilited by inserting a .truenas_s3/config_backup.json
file inside each bucket (daemon-owned path) and restoring the
DB row / S3 config with some user-provided overrides if required.
Two new API endpoints are added:
* sharing.s3.recoverable_buckets lists mounted datasets containing
orphaned buckets.
* sharing.s3.recover basically takes a list of datasets and rebuilds
bucket configuration from backups for them.
Fix mypy errors in the S3 bucket recovery
`bucket_dataset_properties` goes back to explicit keywords, which mypy
can check against each field's type, and the mapping a recover checks
against is read off it rather than the other way round.
The other three are a narrowing the render loop had left implicit, an
untyped NSS lookup, and OSError.errno being optional.
NAS-144067 / 26.0.0 / Fix LDAP directory service migration for multiple servers (by anodos325) (#19880)
`ldap_hostname` is comma-separated, so a configuration with more than
one LDAP server migrated into a single malformed `server_urls` entry
that SSSD discards entirely, leaving no usable server. Also normalize
the case of legacy values copied into the new table, which left
`ldap_schema` lowercased and failing validation against
Literal['RFC2307', 'RFC2307BIS'].
Supplementary migration is not being added because anyone who
encountered this issue during migration would have already cleared the
problematic LDAP config and set the correct parameters. LDAP is not
functional in a degraded state after failed migration, and migration
failure is currently user-serviceable. This commit primarily is to fix
users who are migrating from 25.04 to 26.
Original PR: https://github.com/truenas/middleware/pull/19876
Co-authored-by: Andrew Walker <andrew.walker at truenas.com>
Fix LDAP directory service migration for multiple servers
`ldap_hostname` is comma-separated, so a configuration with more than one LDAP
server migrated into a single malformed `server_urls` entry that SSSD discards
entirely, leaving no usable server. Also normalize the case of legacy values
copied into the new table, which left `ldap_schema` lowercased and failing
validation against Literal['RFC2307', 'RFC2307BIS'].
Supplementary migration is not being added because anyone who
encountered this issue during migration would have already cleared the
problematic LDAP config and set the correct parameters. LDAP is not
functional in a degraded state after failed migration, and migration
failure is currently user-serviceable. This commit primarily is to fix
users who are migrating from 25.04 to 26.
(cherry picked from commit 04508648a8b6ad119fc2acaabcabd4687f9210b4)
NAS-144067 / 27.0.0-BETA.1 / Fix LDAP directory service migration for multiple servers (#19876)
`ldap_hostname` is comma-separated, so a configuration with more than
one LDAP server migrated into a single malformed `server_urls` entry
that SSSD discards entirely, leaving no usable server. Also normalize
the case of legacy values copied into the new table, which left
`ldap_schema` lowercased and failing validation against
Literal['RFC2307', 'RFC2307BIS'].
Supplementary migration is not being added because anyone who
encountered this issue during migration would have already cleared the
problematic LDAP config and set the correct parameters. LDAP is not
functional in a degraded state after failed migration, and migration
failure is currently user-serviceable. This commit primarily is to fix
users who are migrating from 25.04 to 26.
Only reconcile license delegates whose entitlements changed
This commit adds changes to make license reconcile delegates act only when an entitlement they depend on actually changes. Previously every license upload ran every delegate, so re-uploading the same license or adding an unrelated feature would still restart ctdb and s3 and reload smb, discovery and zfs tier.
The upload now snapshots resolved entitlements before the new license is installed and hands that to the reconcile job, which diffs it against live entitlements and skips any delegate whose declared features did not change. ctdb is started when HA is gained and stopped (with its config re-rendered) when HA is lost instead of being restarted, and sync_to_peer snapshots the peer's entitlements before pushing the license so its final hook call on the peer only touches what changed.
devel/linux_libusb: Fix build and hand over to emulation@
The Linux gcc picks up ld from devel/binutils, which cannot load the
Linux LTO plugin, and linking libusb.so.3 fails. Point gcc at the
linker from the Linux base with -B.
Give maintainership to emulation@.
Sponsored by: Netzkommune GmbH
devel/linux_libusb: Fix build and hand over to emulation@
The Linux gcc picks up ld from devel/binutils, which cannot load the
Linux LTO plugin, and linking libusb.so.3 fails. Point gcc at the
linker from the Linux base with -B.
Give maintainership to emulation@.
Sponsored by: Netzkommune GmbH
contrib/flex: Guard against int overflow in sko_push().
sko_sz is an int; doubling it unchecked could overflow and produce a
huge size_t for realloc(). Bail out if it would overflow.
It's sad that the upstream project hasn't had a new release since 2017,
so we decided to directly patch the contributed source.
Bug: #3426