VFS mountpoint backing device system
All checks were successful
Build documentation / build-and-deploy (push) Successful in 2m24s
All checks were successful
Build documentation / build-and-deploy (push) Successful in 2m24s
This commit is contained in:
38
kernel/device/ramdrv.h
Normal file
38
kernel/device/ramdrv.h
Normal file
@@ -0,0 +1,38 @@
|
||||
#ifndef _KERNEL_DEVICE_RAMDRV_H
|
||||
#define _KERNEL_DEVICE_RAMDRV_H
|
||||
|
||||
#include <libk/std.h>
|
||||
|
||||
struct device;
|
||||
struct device_op_ctx;
|
||||
|
||||
struct ramdrv_init {
|
||||
size_t total_size;
|
||||
size_t sector_size;
|
||||
uint8_t* buffer;
|
||||
};
|
||||
|
||||
struct ramdrv {
|
||||
size_t total_size;
|
||||
size_t sector_size;
|
||||
uint8_t* buffer;
|
||||
bool managed;
|
||||
};
|
||||
|
||||
bool ramdrv_init (struct device* device, void* arg);
|
||||
|
||||
void ramdrv_fini (struct device* device);
|
||||
|
||||
int ramdrv_read (struct device* device, struct device_op_ctx* op_ctx, void* a1, void* a2, void* a3,
|
||||
void* a4);
|
||||
|
||||
int ramdrv_get_device_type (struct device* device, struct device_op_ctx* op_ctx, void* a1, void* a2,
|
||||
void* a3, void* a4);
|
||||
|
||||
int ramdrv_get_sector_size (struct device* device, struct device_op_ctx* op_ctx, void* a1, void* a2,
|
||||
void* a3, void* a4);
|
||||
|
||||
int ramdrv_get_size (struct device* device, struct device_op_ctx* op_ctx, void* a1, void* a2,
|
||||
void* a3, void* a4);
|
||||
|
||||
#endif // _KERNEL_DEVICE_RAMDRV_H
|
||||
Reference in New Issue
Block a user