Page MenuHomeFreeBSD

vfs_mountroot: Check for root dev before waiting
ClosedPublic

Authored by cperciva on Dec 20 2021, 7:34 PM.
Tags
None
Referenced Files
Unknown Object (File)
Mon, Sep 23, 7:08 AM
Unknown Object (File)
Wed, Sep 18, 8:22 AM
Unknown Object (File)
Wed, Sep 18, 6:19 AM
Unknown Object (File)
Tue, Sep 17, 8:00 PM
Unknown Object (File)
Tue, Sep 10, 11:39 PM
Unknown Object (File)
Wed, Sep 4, 10:03 PM
Unknown Object (File)
Tue, Sep 3, 1:24 PM
Unknown Object (File)
Tue, Sep 3, 10:05 AM
Subscribers

Details

Summary

If GEOM is idle but the root device is not yet present when we enter
vfs_mountroot_wait_if_necessary, we call vfs_mountroot_wait to wait
for root holds (e.g. CAM or USB initialization). Upon returning from
vfs_mountroot_wait, we wait 100 ms at a time until the root device
shows up.

Since the root device most likely appeared during vfs_mountroot_wait

  • waiting for subsystems which may be responsible for the root

device is the whole purpose of that function -- it makes sense to
check if the device is now present rather than printing a warning
and pausing for 100 ms before checking.

Fixes: a3ba3d09c248 Make root mount wait mechanism smarter
Sponsored by: https://www.patreon.com/cperciva

Diff Detail

Repository
rS FreeBSD src repository - subversion
Lint
Lint Passed
Unit
No Test Coverage
Build Status
Buildable 43509
Build 40397: arc lint + arc unit