[Yellowstone] Move to yunq definition for yellowstone server.

This commit is contained in:
Drew Galbraith 2023-10-24 18:24:26 -07:00
parent 9c9fd167cd
commit 2b27af5814
22 changed files with 696 additions and 118 deletions

View file

@ -11,7 +11,7 @@ target_include_directories(victoriafalls
target_link_libraries(victoriafalls
glacier
mammoth
yellowstone_stub
yellowstone_yunq
)
set_target_properties(victoriafalls PROPERTIES

View file

@ -1,5 +1,7 @@
#include "fs/ext2/ext2_block_reader.h"
#include "mammoth/debug.h"
glcr::ErrorOr<glcr::SharedPtr<Ext2BlockReader>> Ext2BlockReader::Init(
ScopedDenaliClient&& denali) {
// Read 1024 bytes from 1024 offset.

View file

@ -1,6 +1,6 @@
#include <mammoth/debug.h>
#include <mammoth/init.h>
#include <yellowstone_stub.h>
#include <yellowstone/yellowstone.yunq.client.h>
#include "fs/ext2/ext2_driver.h"
@ -9,8 +9,14 @@ uint64_t main(uint64_t init_cap) {
dbgln("VFs Started");
YellowstoneStub yellowstone(gInitEndpointCap);
ASSIGN_OR_RETURN(ScopedDenaliClient denali, yellowstone.GetDenali());
YellowstoneClient yellowstone(gInitEndpointCap);
Empty empty;
DenaliInfo denali_info;
RET_ERR(yellowstone.GetDenali(empty, denali_info));
dbgln("LBA (recv): %u", denali_info.lba_offset());
ScopedDenaliClient denali(
EndpointClient::AdoptEndpoint(denali_info.denali_endpoint()),
denali_info.device_id(), denali_info.lba_offset());
ASSIGN_OR_RETURN(Ext2Driver ext2, Ext2Driver::Init(glcr::Move(denali)));
ASSIGN_OR_RETURN(Inode * root, ext2.GetInode(2));