acadia/sys/victoriafalls/fs/ext2/ext2_driver.h
Drew Galbraith 21c1a001ea [victoriafalls] Move the block to lba translation to a small wrapper.
Abstract this away into a thin wrapper over the denali client such that
it can be called from other helper classes.
2023-07-05 23:19:25 -07:00

19 lines
407 B
C++

#pragma once
#include <denali/denali_client.h>
#include <glacier/memory/move.h>
#include "fs/ext2/ext2.h"
#include "fs/ext2/ext2_block_reader.h"
class Ext2Driver {
public:
static glcr::ErrorOr<Ext2Driver> Init(ScopedDenaliClient&& denali);
glcr::ErrorCode ProbePartition();
private:
Ext2BlockReader ext2_reader_;
Ext2Driver(Ext2BlockReader&& reader) : ext2_reader_(glcr::Move(reader)) {}
};