TacOS
0.2
|
#include <types.h>
#include <klibc/string.h>
#include <ioports.h>
#include <klog.h>
#include "floppy_motor.h"
#include "floppy_utils.h"
#include "floppy_interrupt.h"
#include "floppy_dma.h"
Macros | |
#define | floppy_dmalen 0x4800 |
#define | floppy_head2_start floppy_dmalen/2 |
Fonctions | |
void | floppy_dma_init (floppy_io io_dir) |
Initialise le dma en écriture ou en lecture selon la valeur passée en paramètre. Plus de détails... | |
void | floppy_read_sector (int drive, int cylinder, int head, int sector, char *buffer) |
Lis un secteur via le DMA à partir d'un adressage CHS. Plus de détails... | |
void | floppy_write_sector (int drive, int cylinder, int head, int sector, char *buffer) |
Ecrit un secteur via le DMA à partir d'un adressage CHS. Plus de détails... | |
Copyright (C) 2010-2014 TacOS developers.
This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation; either version 3 of the License, or (at your option) any later version.
This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details at http://www.gnu.org/copyleft/gpl.html
You should have received a copy of the GNU General Public License along with this program; if not, see http://www.gnu.org/licenses.
Fonctions liées à l'utilisation du DMA dans le driver disquette
void floppy_dma_init | ( | floppy_io | io_dir | ) |
io_dir | Sens de la communication du DMA à initialiser |
void floppy_read_sector | ( | int | drive, |
int | cylinder, | ||
int | head, | ||
int | sector, | ||
char * | buffer | ||
) |
cylinder | Numero de drive |
cylinder | Numero de cylindre |
head | Numero de tête de lecture |
sector | Numero de secteur |
buffer | Buffer recevant les données lues |
void floppy_write_sector | ( | int | drive, |
int | cylinder, | ||
int | head, | ||
int | sector, | ||
char * | buffer | ||
) |
cylinder | Numero de drive |
cylinder | Numero de cylindre |
head | Numero de tête de lecture |
sector | Numero de secteur |
buffer | Buffer contenant les données à écrire |