SayoriOS  0.3.3
ata_dma.h
1 #pragma once
2 
3 #include "common.h"
4 #include "sys/status.h"
5 
6 #define ATA_DMA_MARK_END 0x8000
7 
8 typedef struct prdt {
9  uint32_t buffer_phys;
10  uint16_t transfer_size;
11  uint16_t mark_end;
12 } __attribute__((packed)) prdt_t;
13 
14 void ata_dma_init();
15 status_t ata_dma_read_sectors(uint8_t drive, uint8_t *buf, uint32_t lba, uint8_t numsects);
16 status_t ata_dma_write_sectors(uint8_t drive, uint8_t *buf, uint32_t lba, uint8_t numsects);
17 status_t ata_dma_read(uint8_t drive, char *buf, uint32_t location, uint32_t length);
18 status_t ata_dma_write(uint8_t drive, const char *buf, uint32_t location, uint32_t length);
19 status_t ata_dma_read_new(uint8_t drive, char *buf, uint32_t location, uint32_t length);
Основные определения ядра
struct registers __attribute__((packed))
Структура данных пакета от мыши
Definition: psf.h:19
Definition: ata_dma.h:8