simos_interface.h
1.35 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
/*
* Copyright (C) 1996-1998 by the Board of Trustees
* of Leland Stanford Junior University.
*
* This file is part of the SimOS distribution.
* See LICENSE file for terms of the license.
*
*/
/*****************************************************************
* interface.h
*
* Author: $author$
* Date: $date$
*****************************************************************
* Simple implementation of DMA transfer:
*
* During the DMA transfer, each line generates a call to the memory system,
* either a GET (DMARead) or a GETX (DMAWrite). The line will then be owned
* owned by the requesting processor (the one that initiated the IO operation.
* Unlike calls to the memory system initiated by the CPU, the line does not
* end up in the cache hierarchy.
* *******************************************************************/
#ifndef DISKMODEL_INTERFACE
#define DISKMODEL_INTERFACE
typedef void (*dmaRoutine_t)( int len , SimTime, void (*done)(int), int);
typedef void (*doneRoutine_t) ( int );
extern void DiskModelInit(int maxNumDisk, double scaling);
extern void DiskModelRequest(int machine, int diskNum, int sector,
int nsectors, int iswrite,
dmaRoutine_t dmaRoutine,
doneRoutine_t doneRoutine , int doneArg);
extern void AdvanceTime(void);
#endif