]> www.pilppa.org Git - linux-2.6-omap-h63xx.git/blob - arch/arm/plat-omap/dsp/ioctl.h
ARM: OMAP: DSPGW: cleanup
[linux-2.6-omap-h63xx.git] / arch / arm / plat-omap / dsp / ioctl.h
1 /*
2  * This file is part of OMAP DSP driver (DSP Gateway version 3.3.1)
3  *
4  * Copyright (C) 2002-2006 Nokia Corporation. All rights reserved.
5  *
6  * Contact: Toshihiro Kobayashi <toshihiro.kobayashi@nokia.com>
7  *
8  * This program is free software; you can redistribute it and/or
9  * modify it under the terms of the GNU General Public License
10  * version 2 as published by the Free Software Foundation.
11  *
12  * This program is distributed in the hope that it will be useful, but
13  * WITHOUT ANY WARRANTY; without even the implied warranty of
14  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
15  * General Public License for more details.
16  *
17  * You should have received a copy of the GNU General Public License
18  * along with this program; if not, write to the Free Software
19  * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
20  * 02110-1301 USA
21  *
22  */
23
24 /*
25  * for /dev/dspctl/ctl
26  */
27 #define DSPCTL_IOCTL_RESET              1
28 #define DSPCTL_IOCTL_RUN                2
29 #define DSPCTL_IOCTL_SETRSTVECT         3
30 #ifdef CONFIG_ARCH_OMAP1
31 #define DSPCTL_IOCTL_CPU_IDLE           4
32 #define DSPCTL_IOCTL_MPUI_WORDSWAP_ON   5
33 #define DSPCTL_IOCTL_MPUI_WORDSWAP_OFF  6
34 #define DSPCTL_IOCTL_MPUI_BYTESWAP_ON   7
35 #define DSPCTL_IOCTL_MPUI_BYTESWAP_OFF  8
36 #define DSPCTL_IOCTL_GBL_IDLE           9
37 #endif /* CONFIG_ARCH_OMAP1 */
38 #define DSPCTL_IOCTL_DSPCFG             10
39 #define DSPCTL_IOCTL_DSPUNCFG           11
40 #define DSPCTL_IOCTL_TASKCNT            12
41 #define DSPCTL_IOCTL_POLL               13
42 #define DSPCTL_IOCTL_REGMEMR            40
43 #define DSPCTL_IOCTL_REGMEMW            41
44 #define DSPCTL_IOCTL_REGIOR             42
45 #define DSPCTL_IOCTL_REGIOW             43
46 #define DSPCTL_IOCTL_GETVAR             44
47 #define DSPCTL_IOCTL_SETVAR             45
48 #define DSPCTL_IOCTL_RUNLEVEL           50
49 #define DSPCTL_IOCTL_SUSPEND            51
50 #define DSPCTL_IOCTL_RESUME             52
51 #ifdef CONFIG_OMAP_DSP_FBEXPORT
52 #define DSPCTL_IOCTL_FBEN               53
53 #define DSPCTL_IOCTL_FBDIS              54
54 #endif /* CONFIG_OMAP_DSP_FBEXPORT */
55 #define DSPCTL_IOCTL_MBSEND             99
56
57 struct omap_dsp_mailbox_cmd {
58         __u16 cmd;
59         __u16 data;
60 };
61
62 struct omap_dsp_reginfo {
63         __u16 adr;
64         __u16 val;
65 };
66
67 struct omap_dsp_varinfo {
68         __u8 varid;
69         __u16 val[0];
70 };
71
72 /*
73  * for taskdev
74  * (ioctls below should be >= 0x10000)
75  */
76 #define TASK_IOCTL_BFLSH        0x10000
77 #define TASK_IOCTL_SETBSZ       0x10001
78 #define TASK_IOCTL_LOCK         0x10002
79 #define TASK_IOCTL_UNLOCK       0x10003
80 #define TASK_IOCTL_GETNAME      0x10004
81
82 /*
83  * for /dev/dspctl/mem
84  */
85 #define MEM_IOCTL_EXMAP         1
86 #define MEM_IOCTL_EXUNMAP       2
87 #define MEM_IOCTL_EXMAP_FLUSH   3
88 #define MEM_IOCTL_FBEXPORT      5
89 #ifdef CONFIG_ARCH_OMAP1
90 #define MEM_IOCTL_MMUITACK      7
91 #endif
92 #define MEM_IOCTL_MMUINIT       9
93 #define MEM_IOCTL_KMEM_RESERVE  11
94 #define MEM_IOCTL_KMEM_RELEASE  12
95
96 struct omap_dsp_mapinfo {
97         __u32 dspadr;
98         __u32 size;
99 };
100
101 /*
102  * for /dev/dspctl/twch
103  */
104 #define TWCH_IOCTL_MKDEV        1
105 #define TWCH_IOCTL_RMDEV        2
106 #define TWCH_IOCTL_TADD         11
107 #define TWCH_IOCTL_TDEL         12
108 #define TWCH_IOCTL_TKILL        13
109
110 struct omap_dsp_taddinfo {
111         __u8 minor;
112         __u32 taskadr;
113 };
114
115 #define TADD_ABORTADR   0xffffffff