autoconf(9): Take device references in iteration for detach.
This avoids a race with concurrent detach that can lead to tripping
KASSERT(!dv->dv_detach_done) in config_detach -> device_acquire, even
if the device_t itself remains stable while the device iteration is
ongoing (because alldev_nwrite or alldev_nread is raised).
While here, add:
- deviter_first_acquire
- deviter_next_acquire
- device_find_by_xname_acquire
- device_find_by_driver_unit_acquire
Prompted by:
PR kern/60986: fssconfig panics on bad backing store type
fss(4): Revoke vnodes when unconfiguring.
This way, if you unconfigure an fss instance and reconfigure it,
anything that had it open (e.g., a file system mounted from it) won't
suddenly start mixing old cached data with new data -- instead, new
I/O operations will fail.
Not perfect -- see comments.
Prompted by:
PR kern/60986: fssconfig panics on bad backing store type
fss(4): Use LK_SHARED, not LK_EXCLUSIVE, to read out mount point.
No need to exclude other readers.
Prompted by:
PR kern/60986: fssconfig panics on bad backing store type
fss(4): Nix needless sc == NULL conditionals.
fss_strategy and fss_ioctl can be reached only after fss_open has
returned and (now that fss_cancel exists) before fss_close has been
called (on both block _and_ all character devices that have been
opened); between (first) open and (last) close, the autoconf unit
must exist.
Prompted by:
PR kern/60986: fssconfig panics on bad backing store type
fss(4): Tighten fss_close a bit.
Clear last FSS_CDEV_OPEN/FSS_BDEV_OPEN in fss_close so we can assert
it in fss_detach, and pass DETACH_FORCE to fss_detach so it knows
when to expect the flags to be cleared.
Prompted by:
PR kern/60986: fssconfig panics on bad backing store type
fss(4): Install a cancel handler.
This way, fss_close doesn't run until all concurrent I/O operations
(read, write, ioctl, strategy) have returned. Note that this applies
independently to the bdev and the cdev, so (e.g.) fss_close may run
on the cdev while there's still an fss_strategy running in parallel.
But in that case, sc->sc_flags will have FSS_BDEV_OPEN set, so
fss_close won't try to detach it too soon.
Prompted by:
PR kern/60986: fssconfig panics on bad backing store type
fss(4): Ensure newly attached autoconf unit matches dev_t minor.
Setting cf->cf_fstate = FSTATE_STAR means autoconf(9) may select any
unit from cf->cf_unit onward, rather than only cf->cf_unit. Since
the attach is always serialized by fss_device_lock, this proably
doesn't make a difference in practice -- and we can't get rid of
fss_device_lock without a config_intern_pseudo_acquire or something
that atomically acquires the existing unit or if there is none
attaches a new one. But let's make the intent clearer in case any of
that changes.
Prompted by:
PR kern/60986: fssconfig panics on bad backing store type
fss(4): Gather module init/fini logic into one place.
Fixes some little-used error branches and avoids duplication that can
get out of sync.
PR kern/60986: fssconfig panics on bad backing store type
fss(4): Avoid races with drvctl detach.
Attach and detach by opening and closing /dev/fssN is serialized by
fss_device_lock, but concurrent `drvctl -d fssN' can cause an fss
instance to be detached and freed while fss_open or fss_close is
still trying to use it.
Prevent concurrent detach during other operations like fss_ioctl or
fss_strategy by making fss_detach fail if sc_flags shows it is held
open.
Prompted by:
PR kern/60986: fssconfig panics on bad backing store type
fss(4): Rework creation path to avoid various races.
1. Look up each vnode exactly once; the identity of the vnode may
change between lookups otherwise.
2. Don't read v_vflag or v_mount without holding the vnode lock;
otherwise they may be changed by concurrent revoke.
3. Hold vfs_busy(mp) while we don't have one of its vnode's locked
and we haven't committed the fss instance to FSS_ACTIVE (at which
point fss_unmount_hook will take care of it).
4. Set sc->sc_uflags at the same time the transition to FSS_ACTIVE,
and loosen assertion after fss_create_snapshot, to avoid a race
between FSSIOCSET and FSSIOCCLR. See comments in FSSIOCSET for
details.
XXX Should consider using namei and VOP_REMOVE instead of
do_sys_unlink to remove only the vnode that we actually looked up,
[3 lines not shown]
fss(4): Handle fss_softc_alloc failure.
Shouldn't successfully transition to FSS_ACTIVE in that case; should
instead back out and fail.
PR kern/60986: fssconfig panics on bad backing store type
fss(4): Initialize sc_state in fss_attach, not fss_open.
Access without sc_slock is forbidden.
Prompted by:
PR kern/60986: fssconfig panics on bad backing store type
fss(4): Close vn_open with vn_close, not with vrele.
Fixes
# fssconfig fss0 / /dev/ld4
...
panic: vrelel: bad ref count
(The mistake is using the block device /dev/ld4 instead of the
character device /dev/rld4, but this ought to be handled gracefully,
not by panicking.)
PR kern/60986: fssconfig panics on bad backing store type
xfile: update to 1.2.1
# changes
Maintenace release, mainly bugfixes and some minor enhancements.
Pasting with the mouse button 2 can now be set up for the file list
widget.
emwm-utils: update to 2.0
# changes
* Added optional workspace switcher widget
* Logout/Shutdown dialog can now be requested by signaling xmsm with
SIGUSR1
* workspaceBackgroundColor/Image resource was removed (handled in
EMWM v2)
* Fixed: toolboxrc parser not accepting K&R style opening
bracket placement
wm/emwm: update to 2.1
# changes (since 1.3)
Aug 15, 2026 - v2.1
- Hint values provided by clients are now validated and clamped in necessary.
- In case a font specified in resources cannot be loaded, emwm will now try
and create a fallback font.
May 14, 2026 - v2.0
- Reinstated the MWM Workspace Manager (multiple desktops) functionality.
- When resizing a client with size increment hint specified, the size shown
is now the inner client window, rather than window manager frame size.
- Added xineramaScreenFocus (keyboard|pointer|primary) option.
- Fixed: automatic icon repositioning behaving erratically sometimes.
- Fixed: StaticGravity handling for newly managed clients not ICCCM compliant.
- Fixed: clients able to replace user specified icon pixmap if they reset the
icon after their window has been managed.
- Fixed: icon labels/menus placed split across Xinerama screens.