nuageinit: support fetching configuration on multiple iface
On some environement a VM can be connected to multiple ifaces but only
one will respond to dhcp and able to fetch the metadata.
Launch the early dhclient on all available ifaces and as soon as one
dhcp has successfully configured an iface, proceed with fetching the
metadata.
MFC After: 1 week
Reported by: mateusz.klejn at ovhcloud.com
Tested by: mateusz.klejn at ovhcloud.com
Sponsored by: OVHcloud
(cherry picked from commit 90a7728cd8905cd26b90d06f7873df8bad43ae9a)
nuageinit: support fetching configuration on multiple iface
On some environement a VM can be connected to multiple ifaces but only
one will respond to dhcp and able to fetch the metadata.
Launch the early dhclient on all available ifaces and as soon as one
dhcp has successfully configured an iface, proceed with fetching the
metadata.
MFC After: 1 week
Reported by: mateusz.klejn at ovhcloud.com
Tested by: mateusz.klejn at ovhcloud.com
Sponsored by: OVHcloud
(cherry picked from commit 90a7728cd8905cd26b90d06f7873df8bad43ae9a)
touch: Fix setting time of created file if fstat() fails
Previously, if creating the file and fstat() fails, we would've ended up
calling utimensat() on that file anyways with whatever was in sb. Not
that this is an error likely to happen...
We don't check for the return value of close() as we aren't writing
anything to the file and the file is always created on success of
open().
Reviewed by: kevans
Approved by: kevans
Fixes: cb54c500d0e1 ("touch: don't leak descriptor if fstat(2) fails")
Sponsored by: Klara, Inc.
Differential Revision: https://reviews.freebsd.org/D55117
MFC after: 1 week
e1000: Fix setting the promiscuous mode
The variable reg_rctl stores the value read from reg E1000_RCTL. It
may contain bits E1000_RCTL_VFE and E1000_RCTL_CFIEN which control
VLAN hardware filter feature. The promiscuous mode implies all tagged
or untagged packets should be accepted, so the VLAN hardware filter
feature should be disabled when enabling the promiscuous mode.
Calling em_if_vlan_filter_disable() did the task, but later writing
the value of reg_rctl back to the reg E1000_RCTL may restore the
feature.
Move the calling of em_if_vlan_filter_disable() after writing the reg
to fix that.
PR: 292759
Reviewed by: kbowling
Tested by: vova at zote.me
Fixes: 2796f7cab107 e1000: Fix up HW vlan ops
MFC after: 3 days
[5 lines not shown]
e1000: Fix setting the promiscuous mode
The variable reg_rctl stores the value read from reg E1000_RCTL. It
may contain bits E1000_RCTL_VFE and E1000_RCTL_CFIEN which control
VLAN hardware filter feature. The promiscuous mode implies all tagged
or untagged packets should be accepted, so the VLAN hardware filter
feature should be disabled when enabling the promiscuous mode.
Calling em_if_vlan_filter_disable() did the task, but later writing
the value of reg_rctl back to the reg E1000_RCTL may restore the
feature.
Move the calling of em_if_vlan_filter_disable() after writing the reg
to fix that.
PR: 292759
Reviewed by: kbowling
Tested by: vova at zote.me
Fixes: 2796f7cab107 e1000: Fix up HW vlan ops
MFC after: 3 days
[4 lines not shown]
e1000: Fix setting the promiscuous mode
The variable reg_rctl stores the value read from reg E1000_RCTL. It
may contain bits E1000_RCTL_VFE and E1000_RCTL_CFIEN which control
VLAN hardware filter feature. The promiscuous mode implies all tagged
or untagged packets should be accepted, so the VLAN hardware filter
feature should be disabled when enabling the promiscuous mode.
Calling em_if_vlan_filter_disable() did the task, but later writing
the value of reg_rctl back to the reg E1000_RCTL may restore the
feature.
Move the calling of em_if_vlan_filter_disable() after writing the reg
to fix that.
PR: 292759
Reviewed by: kbowling
Tested by: vova at zote.me
Fixes: 2796f7cab107 e1000: Fix up HW vlan ops
MFC after: 3 days
[3 lines not shown]
Unbreak the build
Add the missing comma in the `device_printf` statement.
MFC after: 1 week
MFC with: 9c666de5b
Fixes: 9c666de5b ("Make message added for Darwin OSI quirk more terse")
pkg: Fix mirror type parsing and service discovery
Signed-off-by: Pavel Knoblokh <info at software-advisory.com.au>
Reviewed by: emaste, imp, kevans
Fixes: dc4581589a3 ("pkg: clean support for repositories")
Closes: https://github.com/freebsd/freebsd-src/pull/1989
bectl: Add -E flag to create an empty boot environment
Signed-off-by: Pat Maddox <pat at patmaddox.com>
Reviewed by: kevans
MFC after: 1 week
Closes: https://github.com/freebsd/freebsd-src/pull/1975
powerpc64/pmap: No need to use r0 anymore in tlbie
The only use of `tlbie %rN, 0` is now explicit and covered in the block
above. Since there's no need for an explicit `tlbie %rN, 0` now, drop
this convoluted piece and let the compiler decide.
While here, a trivial optimization of the old-style tlbie block, by
clearing tlbie_lock and returning, instead of going to the end which
checks again if the lock is needed. Since it's already known to be
needed, there's no need to check again.
builtin.1: Command list maintenance
+ link to return(1) like the other exclusive builtins
+ fix alphabetical sorting of list in rendered manual
MFC after: 3 days
tpm20: fix suspend/resume and entropy harvesting
There were a few problem here:
- TPM2_Shutdown results in a response that we need to either process
or ignore, otherwise any tpm20_write or tpm20_harvest call will
trivially hang on an `sc->pending_data_length != 0`
- We should have a matching TPM2_Startup upon resume to restore any
state that should have persisted
- We must drain the harvest task before we suspend to avoid problems
there
This commit is sufficient to avoid breaking suspend/resume.
PR: 291067
Fixes: a2d5ed9442bb ("Introduce driver for TPM 2.0 in CRB and [...]")
Fixes: 4ee7d3b0118c ("Allow using TPM as entropy source.")
Co-authored-by: markj (D53835)
Tested by: garga
Differential Revision: https://reviews.freebsd.org/D55074
OptionalObsoleteFiles: Add etc/zfs/compatibility.d
If the world is built and installed with WITHOUT_ZFS, then make
-DBATCH_DELETE_OLD_FILES delete-old-dirs will give the error:
> rmdir: /etc/zfs: Directory not empty
because /etc/zfs/compatibility.d is still there. While we're here,
clean out /usr/share/zfs as well.
Co-authored-by: kevans
Differential Revision: https://reviews.freebsd.org/D54758
Make message added for Darwin OSI quirk more terse
The verbose message was way too verbose. Make it terse.
MFC after: 1 week
MFC with: 052a791b00 ("acpi: add Darwin OSI quirk for Apple Mac hardware")
Requested by: kib
nfs: Add some support for POSIX draft ACLs
An internet draft (expected to become an RFC someday)
https://datatracker.ietf.org/doc/draft-ietf-nfsv4-posix-acls
describes an extension to NFSv4.2 to handle POSIX draft ACLs.
This is the final patch in the series that enables
the extension of NFSv4.2 to support POSIX draft ACLs.
At this time, only UFS mounted with the "acls" option
will work, and only for FreeBSD built with these patches.
Patches for client and server for the Linux kernel are
in the works. (I'll admit my next little project is
cleaning the Linux patches up for submission for upstream.)
To make these changes really useful, the FreeBSD port
of OpenZFS needs to be patched to add POSIX draft ACL
support. (Support for POSIX draft ACLs is already in
the Linux port of OpenZFS.)
[4 lines not shown]
nfs: Add some support for POSIX draft ACLs
An internet draft (expected to become an RFC someday)
https://datatracker.ietf.org/doc/draft-ietf-nfsv4-posix-acls
describes an extension to NFSv4.2 to handle POSIX draft ACLs.
This is the fifth of several patches that implement the
above draft.
This one mostly adds an extra argument to two functions
in nfscommon.ko. Unfortunately, these functions are
called in many places, so the changes are numerous, but
straightforward.
Since the internal KAPI between the NFS modules is changed
by this commit, all of nfscommon.ko, nfscl.ko and nfsd.ko
must be rebuilt from sources.
There should be no semantics change for the series at
[3 lines not shown]