TacOS  0.2
 Tout Structures de données Fichiers Fonctions Variables Définitions de type Énumérations Macros
Macros | Fonctions
Référence du fichier floppy_dma.c
#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"
Graphe des dépendances par inclusion de floppy_dma.c:

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...
 

Description détaillée

Auteur
TacOS developers

LICENSE

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.

DESCRIPTION

Fonctions liées à l'utilisation du DMA dans le driver disquette

Documentation des fonctions

void floppy_dma_init ( floppy_io  io_dir)
Paramètres
io_dirSens de la communication du DMA à initialiser
void floppy_read_sector ( int  drive,
int  cylinder,
int  head,
int  sector,
char *  buffer 
)
Paramètres
cylinderNumero de drive
cylinderNumero de cylindre
headNumero de tête de lecture
sectorNumero de secteur
bufferBuffer recevant les données lues

Voici le graphe d'appel pour cette fonction :

void floppy_write_sector ( int  drive,
int  cylinder,
int  head,
int  sector,
char *  buffer 
)
Paramètres
cylinderNumero de drive
cylinderNumero de cylindre
headNumero de tête de lecture
sectorNumero de secteur
bufferBuffer contenant les données à écrire

Voici le graphe d'appel pour cette fonction :