RK3368 GPU version Rogue M 1.28
[firefly-linux-kernel-4.4.55.git] / drivers / gpu / rogue_m / generated / pdump_bridge / common_pdump_bridge.h
1 /*************************************************************************/ /*!
2 @File
3 @Title          Common bridge header for pdump
4 @Copyright      Copyright (c) Imagination Technologies Ltd. All Rights Reserved
5 @Description    Declares common defines and structures that are used by both
6                 the client and sever side of the bridge for pdump
7 @License        Dual MIT/GPLv2
8
9 The contents of this file are subject to the MIT license as set out below.
10
11 Permission is hereby granted, free of charge, to any person obtaining a copy
12 of this software and associated documentation files (the "Software"), to deal
13 in the Software without restriction, including without limitation the rights
14 to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
15 copies of the Software, and to permit persons to whom the Software is
16 furnished to do so, subject to the following conditions:
17
18 The above copyright notice and this permission notice shall be included in
19 all copies or substantial portions of the Software.
20
21 Alternatively, the contents of this file may be used under the terms of
22 the GNU General Public License Version 2 ("GPL") in which case the provisions
23 of GPL are applicable instead of those above.
24
25 If you wish to allow use of your version of this file only under the terms of
26 GPL, and not to allow others to use your version of this file under the terms
27 of the MIT license, indicate your decision by deleting the provisions above
28 and replace them with the notice and other provisions required by GPL as set
29 out in the file called "GPL-COPYING" included in this distribution. If you do
30 not delete the provisions above, a recipient may use your version of this file
31 under the terms of either the MIT license or GPL.
32
33 This License is also included in this distribution in the file called
34 "MIT-COPYING".
35
36 EXCEPT AS OTHERWISE STATED IN A NEGOTIATED AGREEMENT: (A) THE SOFTWARE IS
37 PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING
38 BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR
39 PURPOSE AND NONINFRINGEMENT; AND (B) IN NO EVENT SHALL THE AUTHORS OR
40 COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER
41 IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN
42 CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
43 */ /**************************************************************************/
44
45 #ifndef COMMON_PDUMP_BRIDGE_H
46 #define COMMON_PDUMP_BRIDGE_H
47
48 #include "img_types.h"
49 #include "pvrsrv_error.h"
50
51 #include "devicemem_typedefs.h"
52 #include "pdumpdefs.h"
53
54
55 #define PVRSRV_BRIDGE_PDUMP_CMD_FIRST                   0
56 #define PVRSRV_BRIDGE_PDUMP_DEVMEMPDUMPBITMAP                   PVRSRV_BRIDGE_PDUMP_CMD_FIRST+0
57 #define PVRSRV_BRIDGE_PDUMP_PVRSRVPDUMPCOMMENT                  PVRSRV_BRIDGE_PDUMP_CMD_FIRST+1
58 #define PVRSRV_BRIDGE_PDUMP_PVRSRVPDUMPSETFRAME                 PVRSRV_BRIDGE_PDUMP_CMD_FIRST+2
59 #define PVRSRV_BRIDGE_PDUMP_CMD_LAST                    (PVRSRV_BRIDGE_PDUMP_CMD_FIRST+2)
60
61
62 /*******************************************
63             DevmemPDumpBitmap          
64  *******************************************/
65
66 /* Bridge in structure for DevmemPDumpBitmap */
67 typedef struct PVRSRV_BRIDGE_IN_DEVMEMPDUMPBITMAP_TAG
68 {
69         IMG_HANDLE hDeviceNode;
70         IMG_CHAR * puiFileName;
71         IMG_UINT32 ui32FileOffset;
72         IMG_UINT32 ui32Width;
73         IMG_UINT32 ui32Height;
74         IMG_UINT32 ui32StrideInBytes;
75         IMG_DEV_VIRTADDR sDevBaseAddr;
76         IMG_HANDLE hDevmemCtx;
77         IMG_UINT32 ui32Size;
78         PDUMP_PIXEL_FORMAT ePixelFormat;
79         IMG_UINT32 ui32AddrMode;
80         IMG_UINT32 ui32PDumpFlags;
81 } __attribute__((packed)) PVRSRV_BRIDGE_IN_DEVMEMPDUMPBITMAP;
82
83
84 /* Bridge out structure for DevmemPDumpBitmap */
85 typedef struct PVRSRV_BRIDGE_OUT_DEVMEMPDUMPBITMAP_TAG
86 {
87         PVRSRV_ERROR eError;
88 } __attribute__((packed)) PVRSRV_BRIDGE_OUT_DEVMEMPDUMPBITMAP;
89
90 /*******************************************
91             PVRSRVPDumpComment          
92  *******************************************/
93
94 /* Bridge in structure for PVRSRVPDumpComment */
95 typedef struct PVRSRV_BRIDGE_IN_PVRSRVPDUMPCOMMENT_TAG
96 {
97         IMG_CHAR * puiComment;
98         IMG_UINT32 ui32Flags;
99 } __attribute__((packed)) PVRSRV_BRIDGE_IN_PVRSRVPDUMPCOMMENT;
100
101
102 /* Bridge out structure for PVRSRVPDumpComment */
103 typedef struct PVRSRV_BRIDGE_OUT_PVRSRVPDUMPCOMMENT_TAG
104 {
105         PVRSRV_ERROR eError;
106 } __attribute__((packed)) PVRSRV_BRIDGE_OUT_PVRSRVPDUMPCOMMENT;
107
108 /*******************************************
109             PVRSRVPDumpSetFrame          
110  *******************************************/
111
112 /* Bridge in structure for PVRSRVPDumpSetFrame */
113 typedef struct PVRSRV_BRIDGE_IN_PVRSRVPDUMPSETFRAME_TAG
114 {
115         IMG_UINT32 ui32Frame;
116 } __attribute__((packed)) PVRSRV_BRIDGE_IN_PVRSRVPDUMPSETFRAME;
117
118
119 /* Bridge out structure for PVRSRVPDumpSetFrame */
120 typedef struct PVRSRV_BRIDGE_OUT_PVRSRVPDUMPSETFRAME_TAG
121 {
122         PVRSRV_ERROR eError;
123 } __attribute__((packed)) PVRSRV_BRIDGE_OUT_PVRSRVPDUMPSETFRAME;
124
125 #endif /* COMMON_PDUMP_BRIDGE_H */