[VictoriaFalls] Add a VFS yunq stub and register it.
This commit is contained in:
parent
f815eb5614
commit
48c7721b0f
11 changed files with 473 additions and 1 deletions
|
|
@ -4,6 +4,7 @@
|
|||
#include <yellowstone/yellowstone.yunq.client.h>
|
||||
|
||||
#include "fs/ext2/ext2_driver.h"
|
||||
#include "victoriafalls_server.h"
|
||||
|
||||
uint64_t main(uint64_t init_cap) {
|
||||
ParseInitPort(init_cap);
|
||||
|
|
@ -20,6 +21,14 @@ uint64_t main(uint64_t init_cap) {
|
|||
ASSIGN_OR_RETURN(Ext2Driver ext2, Ext2Driver::Init(glcr::Move(denali)));
|
||||
|
||||
ASSIGN_OR_RETURN(Inode * root, ext2.GetInode(2));
|
||||
|
||||
ASSIGN_OR_RETURN(auto server, VFSServer::Create());
|
||||
|
||||
RegisterEndpointRequest req;
|
||||
req.set_endpoint_name("victoriafalls");
|
||||
ASSIGN_OR_RETURN(auto client, server->CreateClient());
|
||||
req.set_endpoint_capability(client.Capability());
|
||||
check(yellowstone.RegisterEndpoint(req, empty));
|
||||
check(ext2.ProbeDirectory(root));
|
||||
|
||||
return 0;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue