source: soft/giet_vm/sys/drivers.h @ 162

Last change on this file since 162 was 158, checked in by alain, 12 years ago

Introducing the giet_vm and some example applications

File size: 2.3 KB
Line 
1///////////////////////////////////////////////////////////////////////////////////
2// File     : drivers.h
3// Date     : 01/04/2012
4// Author   : alain greiner and joel porquet
5// Copyright (c) UPMC-LIP6
6///////////////////////////////////////////////////////////////////////////////////
7
8#ifndef _DRIVERS_H_
9#define _DRIVERS_H_
10
11///////////////////////////////////////////////////////////////////////////////////
12//      Global variables for interaction with ISRs
13///////////////////////////////////////////////////////////////////////////////////
14
15extern volatile unsigned int _dma_status[];
16extern volatile unsigned char _dma_busy[];
17
18extern volatile unsigned char _ioc_status;
19extern volatile unsigned char _ioc_done;
20extern volatile unsigned int _ioc_lock;
21
22extern volatile unsigned char _tty_get_buf[];
23extern volatile unsigned char _tty_get_full[];
24
25///////////////////////////////////////////////////////////////////////////////////
26// Prototypes of the drivers functions.
27///////////////////////////////////////////////////////////////////////////////////
28
29unsigned int _timer_write(unsigned int global, unsigned int reg, unsigned int value);
30unsigned int _timer_read(unsigned int global, unsigned int reg, unsigned int *buffer);
31
32unsigned int _tty_write(const char *buffer, unsigned int length);
33unsigned int _tty_read(char *buffer, unsigned int length);
34unsigned int _tty_read_irq(char *buffer, unsigned int length);
35
36unsigned int _ioc_write(unsigned int lba, const void *buffer, unsigned int count);
37unsigned int _ioc_read(unsigned int lba, void *buffer, unsigned int count);
38unsigned int _ioc_completed();
39
40unsigned int _icu_write(unsigned int register_index, unsigned int value);
41unsigned int _icu_read(unsigned int register_index, unsigned int *buffer);
42
43unsigned int _gcd_write(unsigned int register_index, unsigned int value);
44unsigned int _gcd_read(unsigned int register_index, unsigned int *buffer);
45
46unsigned int _fb_sync_write(unsigned int offset, const void *buffer, unsigned int length);
47unsigned int _fb_sync_read(unsigned int offset, const void *buffer, unsigned int length);
48unsigned int _fb_write(unsigned int offset, const void *buffer, unsigned int length);
49unsigned int _fb_read(unsigned int offset, const void *buffer, unsigned int length);
50unsigned int _fb_completed();
51
52#endif
53
Note: See TracBrowser for help on using the repository browser.