diff options
author | Damien Zammit <damien@zamaudio.com> | 2022-09-08 09:32:52 +0000 |
---|---|---|
committer | Samuel Thibault <samuel.thibault@ens-lyon.org> | 2022-09-11 21:20:53 +0200 |
commit | 22676a3a6e4d99e13ee75c1ad2f4976ae6b0ce52 (patch) | |
tree | 166b5a14fa24eb45382c8c03e83279de8007de7f /rumpdisk | |
parent | fab864748c2daf57b3fdad7382cba5f9b9d5c9d8 (diff) | |
download | hurd-22676a3a6e4d99e13ee75c1ad2f4976ae6b0ce52.tar.gz hurd-22676a3a6e4d99e13ee75c1ad2f4976ae6b0ce52.tar.bz2 hurd-22676a3a6e4d99e13ee75c1ad2f4976ae6b0ce52.zip |
machdev, pci-arbiter, rumpdisk: Fix race condition in bootstrap
This fixes a known race condition in bootstrapping by
separating the fsys_startup call from the server demuxer loop
into two separate functions that the caller can decide
when to call.
Message-Id: <20220908093229.499494-1-damien@zamaudio.com>
Diffstat (limited to 'rumpdisk')
-rw-r--r-- | rumpdisk/main.c | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/rumpdisk/main.c b/rumpdisk/main.c index 9a353541..64065c6c 100644 --- a/rumpdisk/main.c +++ b/rumpdisk/main.c @@ -141,6 +141,8 @@ main (int argc, char **argv) if (err) return err; pthread_detach (t); - machdev_trivfs_server (bootstrap); + machdev_trivfs_server_startup (bootstrap); + machdev_trivfs_server_loop (NULL); + /* Never reached */ return 0; } |