Files
mop3/kernel/device/partitions.h
2026-03-12 19:23:47 +01:00

30 lines
670 B
C

#ifndef _KERNEL_DEVICE_PARTITIONS_H
#define _KERNEL_DEVICE_PARTITIONS_H
#include <aux/compiler.h>
#include <device/device.h>
#include <libk/std.h>
#include <proc/proc.h>
#include <proc/reschedule.h>
struct dos_pte {
uint8_t drive_attrs;
uint8_t chs_start_addr[3];
uint8_t part_type;
uint8_t chs_last_sect_addr[3];
uint32_t start_lba;
uint32_t sector_count;
} PACKED;
struct dos_mbr {
uint8_t boot_code[440];
uint8_t signature[4];
uint8_t resv[2];
struct dos_pte ptes[4];
uint8_t valid_sign[2];
} PACKED;
int device_probe_partitions (struct proc* proc, struct reschedule_ctx* rctx, struct device* device);
#endif // _KERNEL_DEVICE_PARTITIONS_H