-
Notifications
You must be signed in to change notification settings - Fork 3
/
Copy patharmdsp.h
60 lines (45 loc) · 1.34 KB
/
armdsp.h
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
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
#ifndef _ARMDSP_H_
#define _ARMDSP_H_
#define ARMDSP_SRAM_BASE 0x80000000
#define ARMDSP_SRAM_SIZE 0x00020000
#define ARMDSP_DRAM_BASE 0xc4000000
#define ARMDSP_DRAM_SIZE 0x04000000
/*
* communication area is first page of shared ram
*/
#define ARMDSP_COMM_PHYS ARMDSP_SRAM_BASE
#define ARMDSP_COMM_VECS 0
/* vector table size is 0x200 */
#define ARMDSP_COMM_TRGBUF 0x200
#define ARMDSP_COMM_TRGBUF_SIZE (4+8+256)
#define ARMDSP_COMM_USER 0x800
#define ARMDSP_COMM_USER_SIZE 0x800
#define ARMDSP_COMM_SIZE 0x1000
struct armdsp_trgbuf {
uint32_t owner;
uint32_t length;
uint8_t buf[ARMDSP_COMM_TRGBUF_SIZE];
};
#define ARMDSP_TRGBUF_OWNER_DSP 0
#define ARMDSP_TRGBUF_OWNER_ARM 1
struct armdsp_physio {
uint32_t physaddr;
uint32_t val;
};
#define ARMDSP_IOC_MAGIC 'a'
#define ARMDSP_IOCSTOP _IO(ARMDSP_IOC_MAGIC, 47)
#define ARMDSP_IOCSTART _IO(ARMDSP_IOC_MAGIC, 48)
#define ARMDSP_IOCWMB _IO(ARMDSP_IOC_MAGIC, 49)
#define ARMDSP_IOCRMB _IO(ARMDSP_IOC_MAGIC, 50)
#define ARMDSP_IOCREADP _IOWR(ARMDSP_IOC_MAGIC, 51, struct armdsp_physio)
#define ARMDSP_IOCWRITEP _IOW(ARMDSP_IOC_MAGIC, 52, struct armdsp_physio)
#ifndef __KERNEL__
char *armdsp_init (int cold_boot);
char *armdsp_run (char const *filename);
void armdsp_host (void);
int armdsp_verbose;
int armdsp_fd;
void *armdsp_sram;
void *armdsp_dram;
#endif /* __KERNEL__ */
#endif /* _ARMDSP_H_ */