HomeFreeBSD

Do not delegate a work to geom event thread which can be done inline.

Description

Do not delegate a work to geom event thread which can be done inline.

In particular, swapongeom_ev() needed event thread context when swap
pager configuration was performed under Giant and geom asserted that
Giant is not owned. Now both of the reason went away.

On the other hand, note that swpageom_release() is called from the
bio_done context, and possible close cannot be performed inline.

Also fix some minor issues. The swapgeom() function does not use the
td argument, remove it. Recheck that the vnode passed is still VCHR
and not reclaimed after the lock.

Reviewed by: mav
Tested by: pho
Sponsored by: The FreeBSD Foundation
MFC after: 2 weeks

Details

Provenance
kibAuthored on
Reviewer
mav
Parents
rS303447: MFC r302897:
Branches
Unknown
Tags
Unknown