1 /*
2  *  Copyright 2001-2008 Texas Instruments - http://www.ti.com/
3  *
4  *  Licensed under the Apache License, Version 2.0 (the "License");
5  *  you may not use this file except in compliance with the License.
6  *  You may obtain a copy of the License at
7  *
8  *     http://www.apache.org/licenses/LICENSE-2.0
9  *
10  *  Unless required by applicable law or agreed to in writing, software
11  *  distributed under the License is distributed on an "AS IS" BASIS,
12  *  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13  *  See the License for the specific language governing permissions and
14  *  limitations under the License.
15  */
16 
17 /*
18  *  ======== dsptrap.h ========
19  *  DSP-BIOS Bridge driver support functions for TI OMAP processors.
20  *  Purpose:
21  *      Handles interaction between user and driver layers.
22  *
23  *! Revision History
24  *! ================
25  *! 13-Feb-2001 kc: DSP/BIOS Bridge name updates.
26  *! 28-Jan-2000 rr: New define for the TI Function offset.
27  *!                 NT_CMD_FROM_OFFSET moved in from wcdioctl.h
28  *!                 It is not hard coded any more; can be used by the class
29  *!                 driver as well.
30  *! 08-Oct-1999 rr: header information changed to dbclsdrv.dll
31  *! 18-Aug-1999 rr: Created
32  */
33 
34 #ifndef DSPTRAP_
35 #define DSPTRAP_
36 
37 #include <wcdioctl.h>
38 
39 #ifndef LINUX
40 #define TI_FUNCTION_OFFSET  0x5000
41 
42 #define NT_CMD_FROM_OFFSET(x) CTL_CODE(FILE_DEVICE_UNKNOWN, \
43     (TI_FUNCTION_OFFSET + (x)), METHOD_BUFFERED, FILE_ANY_ACCESS)
44 #endif
45 
46 /* Function Prototypes */
47 extern DWORD DSPTRAP_Trap(Trapped_Args * args, int cmd);
48 
49 #endif				/* DSPTRAP_ */
50