zonectl: display conventional zones better during RZ
zonectl's Report Zones subcommand displays a tabular list of zones. A
conventional zone's WP column is displayed as 0xffffffffffffffff , the
literal value that the HDD reports. But that's too wide for the column,
causing the text to be misaligned. It's also not really meaningful,
because the Write Pointer isn't really defined for a Conventional zone.
Change it to "-1" to fix the text misalignment.
MFC after: 2 weeks
Sponsored by: ConnectWise
Reviewed by: fuz
Differential Revision: https://reviews.freebsd.org/D57512
boot-test.sh: Test many boot loader combinations.
This is a script that eventually will test boot with qemu all the
supproted combinations for the boot loader. There's several things that
could be done with gptboot or boot0sio (or not) that aren't tested. We
don't test the 10-odd hardware root devices we support, nor do we test
complex scenarios like RELAXED vs STRICT zfs efi booting.
However, the scenarios we do support are included here. We test aarch64,
amd64, armv7, powerpc64, powerpc64le, and riscv64 for BIOS, UEFI, and
Prep and OpenFirmware (as appropriate) crossed with CDROM, MBR and GPT
(and some hybrid) crossed with lua, 4th and simple loaders. Plus some
linuxboot and memdisk scenarios, including the recently added
compression for ram disk scenarios:
=== Results: 67 passed, 3 failed, 9 timed out (of 79) ===
The timeouts are well understood, usually failure to find the root
disk. The failures are bad console assumptions. netboot-bios fails
[39 lines not shown]
nfsd: Commit missing patches for c52bcd09c2a6
Oops, I missed the other files for the commit.
This should fix the build.
Pointy hat goes on me.
MFC after: 2 weeks
Fixes: c52bcd09c2a6 ("nfsd: Garbage collect stray NFSv4 state")
loader: Add xzfs, like gzipfs but with xz.
This is just like gzipfs or bzipfs, except done with the newer xz
program. This is off by default for the moment.
Sponsored by: Netflix
loader.efi: Add xz decompression
We can now decompress .xz compressed memory disks, like
FreeBSD-15.1-RELEASE-amd64-disc1.iso.xz
Sponsored by: Netflix
Differential Revision: https://reviews.freebsd.org/D58073
loader: Add xzfs support by defualt to BIOS and EFI loaders
For the BIOS, add xzfs support. This is a tiny increase in the loader
size, but allows us to fetch compressed files from any of the
filesystems we support, including over the network.
For EFI, also add gzipfs and bzip2fs support we well. The increment for
these files is tiny.
Sponsored by: Netflix
routing: Add test for nexthop subscription
Make sure we have reachability when one of our nexthops
gets down without deleting the route.
Differential Revision: https://reviews.freebsd.org/D57552
routing: Replace unreachable nhops in nhgrp
If a nhop gets an interface event, revalidate the nhops and
immediately try to recompile existing nexthop groups by
replacing unreachable nexthops with reachable ones.
If none are available, recompile them back to
their normal position in nexthop group slots.
Reviewed by: glebius
Discussed with: markj
Relnotes: yes
Differential Revision: https://reviews.freebsd.org/D57389
routing: Subscribe nhops to ifnet link events
Update nexthop flags with interface link status events and
instead of checking link status of interface for every packet
only check the reachability flag of the final nexthop.
Reviewed by: glebius
Discussed with: markj
Differential Revision: https://reviews.freebsd.org/D57375
nfsd: Garbage collect stray NFSv4 state
When a file is deleted on the NFS server by another client,
any NFSv4 state related to that file is left stranded.
This happens because the NFSv4 operations that free the
state use a CFH, which is set by a PutFH operation.
However, the PutFH fails with ESTALE because the file has
been deleted.
This patch adds a function called nfsrv_freestrandedstate()
that frees all the NFSv4 state related to a file and calls
this function when PutFH will be replying ESTALE.
While here, a helper function was defined to handle free'ng
of the nfslockfile structure and replaces the two places
where nearly identical code does this.
Reported by: Richard Purdie <richard.purdie at linuxfoundation.org>
Tested by: Michael Halstead <mhalstead at linuxfoundation.org>
MFC after: 2 weeks
kvm: Support non-default CPUID leaf
KVM does not always use 0x40000000 as its CPUID base. For example, QEMU
adds a 0x100 offset when nested virtualization is detected and the host
exposes Hyper-V enlightenment hints. To accommodate this behavior,
switch the detection logic to use the CPUID leaf returned by do_cpuid(),
making the implementation more flexible.
See:
https://github.com/qemu/qemu/blob/master/target/i386/kvm/kvm.c#L2300
Reviewed by: kib
MFC after: 2 weeks
Sponsored by: The FreeBSD Foundation
Differential Revision: https://reviews.freebsd.org/D58146
nfs_clstate.c: Fix CB_RECALL handling for NFSv4.1/4.2
Recent testing with a modified NFSv4.1/4.2 client that
sometimes ignored CB_RECALL callbacks, identified a few
problems when handling the unusual case of CB_RECALL not
be performed by the client.
- The csa_cachethis argument to CB_SEQUENCE was being ignored.
- The CB_SEQUENCE operation would reply NFSERR_DELAY
after the first CB_RECALL attempt, making retries
ineffective.
- The code could return NFSERR_RESOURCE, which is a
NFSv4.0 specific error code.
This patch fixes the above three problems.
The patch only affects the NFSv4.1/4.2 client when
delegations are being issued and the client somehow
fails to handle a CB_RECALL callback of a delegation,
which is an unusual case.
[2 lines not shown]
nfs_clstate.c: Fix CB_RECALL handling for NFSv4.1/4.2
Recent testing with a modified NFSv4.1/4.2 client that
sometimes ignored CB_RECALL callbacks, identified a few
problems when handling the unusual case of CB_RECALL not
be performed by the client.
- The csa_cachethis argument to CB_SEQUENCE was being ignored.
- The CB_SEQUENCE operation would reply NFSERR_DELAY
after the first CB_RECALL attempt, making retries
ineffective.
- The code could return NFSERR_RESOURCE, which is a
NFSv4.0 specific error code.
This patch fixes the above three problems.
The patch only affects the NFSv4.1/4.2 client when
delegations are being issued and the client somehow
fails to handle a CB_RECALL callback of a delegation,
which is an unusual case.
[2 lines not shown]
git-mfc: Add an ignore-list feature
Commit hashes listed in ~/.git-mfc-ignore are not listed in output of
git-mfc --dangling or --pending. This is handy for silencing output
about commits that are tagged for MFC or as fixing another commit, but
which were not MFCed for some reason or other.
Requested by: des
Reviewed by: des
Differential Revision: https://reviews.freebsd.org/D58161
git-mfc: Update exception lists
This silences warnings when running git-mfc --pending against stable/13,
14 and 15.
Reviewed by: des
Differential Revision: https://reviews.freebsd.org/D58162
hwpstate_intel(4): Introduce a CPU ID cache
To minimize the diff with hwpstate_intel(4). See previous commit there
for the rationale.
Reviewed by: aokblast
Sponsored by: The FreeBSD Foundation
hwpstate_amd(4): Restore CPU ID cache after introducing cpu_get_pcpuid()
Using cpu_get_pcpuid() directly or having a CPU ID cache does not really
make any significant difference. With cache: Less function calls, less
space on stack, but an additional allocation in the softc, who stays
permanently. Without cache: Some function calls, but one less slot in
the softc, and no data duplication (but that info never changes).
The main reason for this change is to reduce conflicts with some
work-in-progress by aokblast@.
While here, move the check that a per-CPU structure is provided by the
bus from the attach to the probe method, as it is already used by
hwpstate_probe_pstate() there.
Reviewed by: aokblast
Sponsored by: The FreeBSD Foundation
ice(4): Add support for 40G maximal PMD speed
E823 backplane devices may support 40G as maximal PMD speed.
Extend port topology reading logic to handle this case.
While at that fix indentation according to FreeBSD style(9).
Signed-off-by: Krzysztof Galazka <krzysztof.galazka at intel.com>
Tested by: gowtham.kumar.ks_intel.com
Approved by: kbowling (mentor), erj (mentor)
Sponsored by: Intel Corporation
MFC after: 1 week
Differential Revision: https://reviews.freebsd.org/D53587
(cherry picked from commit c6212b7da110d82b1d0086ec525deb216993021e)
ice(4): Fix link speed after changing cable type
When interface was connected to a link partner with a cable
type limitting maximum supported speed, e.g. SFP+ cable
in 25G port, driver incorrectly saved a supported speed
as the user configured speed. This prevented interface
from using all supported speeds after switching cable to SFP28.
Link was established at 10G as supported by previously used
SFP+ cable. Don't set user requested speed unless actually
configured by an user, to allow automatic selection of highest
available speed. Only when user sets custom config
using advertise_speed sysctl save it and try
to apply after cable is changed.
Also don't save initial supported speeds if FW supports
reporting default PHY config.
Signed-off-by: Krzysztof Galazka <krzysztof.galazka at intel.com>
[5 lines not shown]
ice(4): Add support for new E810-XXV-2 adapters
Add two new subdevice IDs for E810-XXV-2 and E810-XXV-2 for OCP 3.0.
Signed-off-by: Krzysztof Galazka <krzysztof.galazka at intel.com>
Reviewed by: kbowling, erj, mateusz.moga_intel.com
Sponsored by: Intel Corporation
Differential Revision: https://reviews.freebsd.org/D54069
(cherry picked from commit bea6f7d02dfbef8f8209f0ca5f1d76877d549f46)
ice(4): Add support for 40G maximal PMD speed
E823 backplane devices may support 40G as maximal PMD speed.
Extend port topology reading logic to handle this case.
While at that fix indentation according to FreeBSD style(9).
Signed-off-by: Krzysztof Galazka <krzysztof.galazka at intel.com>
Tested by: gowtham.kumar.ks_intel.com
Approved by: kbowling (mentor), erj (mentor)
Sponsored by: Intel Corporation
Differential Revision: https://reviews.freebsd.org/D53587
(cherry picked from commit c6212b7da110d82b1d0086ec525deb216993021e)
tools/build: Don't set RANLIB for non-FreeBSD builds
RANLIB is not used by our build, so there is no need to set it.
Reviewed by: imp
Sponsored by: The FreeBSD Foundation
Differential Revision: https://reviews.freebsd.org/D58156