diff options
| author | David Anderson <dvander@google.com> | 2020-11-21 13:44:00 -0800 |
|---|---|---|
| committer | David Anderson <dvander@google.com> | 2020-11-21 17:12:23 -0800 |
| commit | 9de400a6b0a5c5db4cfd369862aeb82ab75359f9 (patch) | |
| tree | 90142d2ca06fe59f6bc0eb76a93202cf10a35818 /trusty/coverage/coverage.cpp | |
| parent | 6e7e8726d1e13821f3bfe9f13140539fb5f17ab6 (diff) | |
libsnapshot: Add a helper for waiting for device paths.
Normally, DeviceMapper::CreateDevice() handles this for us. However, it
does not work in first-stage init, because ueventd is not running.
Therefore this patch adds a way for first-stage init to set a callback
to manually regenerate and process uevents.
Additionally, even with ueventd, dm-user misc device creation needs a
WaitForFile() call, since ueventd is asynchronous.
The WaitForDevice() helper in this patch accounts for both of these
scenarios.
Bug: 173476209
Test: device boots into first-stage init after full VABC ota
Change-Id: Ib7a9bfc2a5a5095aa00b358072f9cb1743c19ab2
Diffstat (limited to 'trusty/coverage/coverage.cpp')
0 files changed, 0 insertions, 0 deletions
