blob: 8b6351fe3eced228a0fe6fcb8abbb0344427022c [file] [log] [blame]
Daniel Walkerda6df072010-04-23 16:04:20 -07001/* include/linux/msm_mdp.h
2 *
3 * Copyright (C) 2007 Google Incorporated
Padmanabhan Komandurud9f38b02012-02-02 18:57:03 +05304 * Copyright (c) 2012 Code Aurora Forum. All rights reserved.
Daniel Walkerda6df072010-04-23 16:04:20 -07005 *
6 * This software is licensed under the terms of the GNU General Public
7 * License version 2, as published by the Free Software Foundation, and
8 * may be copied, distributed, and modified under those terms.
9 *
10 * This program is distributed in the hope that it will be useful,
11 * but WITHOUT ANY WARRANTY; without even the implied warranty of
12 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
13 * GNU General Public License for more details.
14 */
15#ifndef _MSM_MDP_H_
16#define _MSM_MDP_H_
17
18#include <linux/types.h>
Bryan Huntsman3f2bc4d2011-08-16 17:27:22 -070019#include <linux/fb.h>
Daniel Walkerda6df072010-04-23 16:04:20 -070020
21#define MSMFB_IOCTL_MAGIC 'm'
22#define MSMFB_GRP_DISP _IOW(MSMFB_IOCTL_MAGIC, 1, unsigned int)
23#define MSMFB_BLIT _IOW(MSMFB_IOCTL_MAGIC, 2, unsigned int)
Bryan Huntsman3f2bc4d2011-08-16 17:27:22 -070024#define MSMFB_SUSPEND_SW_REFRESHER _IOW(MSMFB_IOCTL_MAGIC, 128, unsigned int)
25#define MSMFB_RESUME_SW_REFRESHER _IOW(MSMFB_IOCTL_MAGIC, 129, unsigned int)
26#define MSMFB_CURSOR _IOW(MSMFB_IOCTL_MAGIC, 130, struct fb_cursor)
27#define MSMFB_SET_LUT _IOW(MSMFB_IOCTL_MAGIC, 131, struct fb_cmap)
Carl Vanderlipba093a22011-11-22 13:59:59 -080028#define MSMFB_HISTOGRAM _IOWR(MSMFB_IOCTL_MAGIC, 132, struct mdp_histogram_data)
Bryan Huntsman3f2bc4d2011-08-16 17:27:22 -070029/* new ioctls's for set/get ccs matrix */
30#define MSMFB_GET_CCS_MATRIX _IOWR(MSMFB_IOCTL_MAGIC, 133, struct mdp_ccs)
31#define MSMFB_SET_CCS_MATRIX _IOW(MSMFB_IOCTL_MAGIC, 134, struct mdp_ccs)
32#define MSMFB_OVERLAY_SET _IOWR(MSMFB_IOCTL_MAGIC, 135, \
33 struct mdp_overlay)
34#define MSMFB_OVERLAY_UNSET _IOW(MSMFB_IOCTL_MAGIC, 136, unsigned int)
35#define MSMFB_OVERLAY_PLAY _IOW(MSMFB_IOCTL_MAGIC, 137, \
36 struct msmfb_overlay_data)
37#define MSMFB_GET_PAGE_PROTECTION _IOR(MSMFB_IOCTL_MAGIC, 138, \
38 struct mdp_page_protection)
39#define MSMFB_SET_PAGE_PROTECTION _IOW(MSMFB_IOCTL_MAGIC, 139, \
40 struct mdp_page_protection)
41#define MSMFB_OVERLAY_GET _IOR(MSMFB_IOCTL_MAGIC, 140, \
42 struct mdp_overlay)
43#define MSMFB_OVERLAY_PLAY_ENABLE _IOW(MSMFB_IOCTL_MAGIC, 141, unsigned int)
44#define MSMFB_OVERLAY_BLT _IOWR(MSMFB_IOCTL_MAGIC, 142, \
45 struct msmfb_overlay_blt)
46#define MSMFB_OVERLAY_BLT_OFFSET _IOW(MSMFB_IOCTL_MAGIC, 143, unsigned int)
Carl Vanderlipba093a22011-11-22 13:59:59 -080047#define MSMFB_HISTOGRAM_START _IOR(MSMFB_IOCTL_MAGIC, 144, \
48 struct mdp_histogram_start_req)
49#define MSMFB_HISTOGRAM_STOP _IOR(MSMFB_IOCTL_MAGIC, 145, unsigned int)
Bryan Huntsman3f2bc4d2011-08-16 17:27:22 -070050#define MSMFB_NOTIFY_UPDATE _IOW(MSMFB_IOCTL_MAGIC, 146, unsigned int)
51
52#define MSMFB_OVERLAY_3D _IOWR(MSMFB_IOCTL_MAGIC, 147, \
53 struct msmfb_overlay_3d)
54
kuogee hsieh405dc302011-07-21 15:06:59 -070055#define MSMFB_MIXER_INFO _IOWR(MSMFB_IOCTL_MAGIC, 148, \
56 struct msmfb_mixer_info_req)
Nagamalleswararao Ganji0737d652011-10-14 02:02:33 -070057#define MSMFB_OVERLAY_PLAY_WAIT _IOWR(MSMFB_IOCTL_MAGIC, 149, \
58 struct msmfb_overlay_data)
Vinay Kalia27020d12011-10-14 17:50:29 -070059#define MSMFB_WRITEBACK_INIT _IO(MSMFB_IOCTL_MAGIC, 150)
Vinay Kaliae1ba2702011-12-21 16:24:52 -080060#define MSMFB_WRITEBACK_START _IO(MSMFB_IOCTL_MAGIC, 151)
61#define MSMFB_WRITEBACK_STOP _IO(MSMFB_IOCTL_MAGIC, 152)
Vinay Kalia27020d12011-10-14 17:50:29 -070062#define MSMFB_WRITEBACK_QUEUE_BUFFER _IOW(MSMFB_IOCTL_MAGIC, 153, \
63 struct msmfb_data)
64#define MSMFB_WRITEBACK_DEQUEUE_BUFFER _IOW(MSMFB_IOCTL_MAGIC, 154, \
65 struct msmfb_data)
66#define MSMFB_WRITEBACK_TERMINATE _IO(MSMFB_IOCTL_MAGIC, 155)
Pravin Tamkhane02a40682011-11-29 14:17:01 -080067#define MSMFB_MDP_PP _IOWR(MSMFB_IOCTL_MAGIC, 156, struct msmfb_mdp_pp)
Vinay Kalia27020d12011-10-14 17:50:29 -070068
Bryan Huntsman3f2bc4d2011-08-16 17:27:22 -070069#define FB_TYPE_3D_PANEL 0x10101010
70#define MDP_IMGTYPE2_START 0x10000
71#define MSMFB_DRIVER_VERSION 0xF9E8D701
Daniel Walkerda6df072010-04-23 16:04:20 -070072
73enum {
Bryan Huntsman3f2bc4d2011-08-16 17:27:22 -070074 NOTIFY_UPDATE_START,
75 NOTIFY_UPDATE_STOP,
76};
77
78enum {
79 MDP_RGB_565, /* RGB 565 planer */
80 MDP_XRGB_8888, /* RGB 888 padded */
81 MDP_Y_CBCR_H2V2, /* Y and CbCr, pseudo planer w/ Cb is in MSB */
Padmanabhan Komandurud9f38b02012-02-02 18:57:03 +053082 MDP_Y_CBCR_H2V2_ADRENO,
Bryan Huntsman3f2bc4d2011-08-16 17:27:22 -070083 MDP_ARGB_8888, /* ARGB 888 */
84 MDP_RGB_888, /* RGB 888 planer */
85 MDP_Y_CRCB_H2V2, /* Y and CrCb, pseudo planer w/ Cr is in MSB */
86 MDP_YCRYCB_H2V1, /* YCrYCb interleave */
87 MDP_Y_CRCB_H2V1, /* Y and CrCb, pseduo planer w/ Cr is in MSB */
88 MDP_Y_CBCR_H2V1, /* Y and CrCb, pseduo planer w/ Cr is in MSB */
Adrian Salido-Morenoe55fa122012-05-29 15:36:08 -070089 MDP_Y_CRCB_H1V2,
90 MDP_Y_CBCR_H1V2,
Bryan Huntsman3f2bc4d2011-08-16 17:27:22 -070091 MDP_RGBA_8888, /* ARGB 888 */
92 MDP_BGRA_8888, /* ABGR 888 */
93 MDP_RGBX_8888, /* RGBX 888 */
94 MDP_Y_CRCB_H2V2_TILE, /* Y and CrCb, pseudo planer tile */
95 MDP_Y_CBCR_H2V2_TILE, /* Y and CbCr, pseudo planer tile */
96 MDP_Y_CR_CB_H2V2, /* Y, Cr and Cb, planar */
Pradeep Jilagam9b4a6be2011-10-03 17:19:20 +053097 MDP_Y_CR_CB_GH2V2, /* Y, Cr and Cb, planar aligned to Android YV12 */
Bryan Huntsman3f2bc4d2011-08-16 17:27:22 -070098 MDP_Y_CB_CR_H2V2, /* Y, Cb and Cr, planar */
99 MDP_Y_CRCB_H1V1, /* Y and CrCb, pseduo planer w/ Cr is in MSB */
100 MDP_Y_CBCR_H1V1, /* Y and CbCr, pseduo planer w/ Cb is in MSB */
Adrian Salido-Moreno2b410482011-08-15 10:40:40 -0700101 MDP_YCRCB_H1V1, /* YCrCb interleave */
102 MDP_YCBCR_H1V1, /* YCbCr interleave */
Adrian Salido-Morenoe55fa122012-05-29 15:36:08 -0700103 MDP_BGR_565, /* BGR 565 planer */
Bryan Huntsman3f2bc4d2011-08-16 17:27:22 -0700104 MDP_IMGTYPE_LIMIT,
kuogee hsieh1ce7e4c2012-01-13 14:05:54 -0800105 MDP_RGB_BORDERFILL, /* border fill pipe */
Adrian Salido-Morenoe55fa122012-05-29 15:36:08 -0700106 MDP_FB_FORMAT = MDP_IMGTYPE2_START, /* framebuffer format */
Bryan Huntsman3f2bc4d2011-08-16 17:27:22 -0700107 MDP_IMGTYPE_LIMIT2 /* Non valid image type after this enum */
Daniel Walkerda6df072010-04-23 16:04:20 -0700108};
109
110enum {
111 PMEM_IMG,
112 FB_IMG,
113};
114
Liyuan Lid9736632011-11-11 13:47:59 -0800115enum {
116 HSIC_HUE = 0,
117 HSIC_SAT,
118 HSIC_INT,
119 HSIC_CON,
120 NUM_HSIC_PARAM,
121};
122
Adrian Salido-Morenoe55fa122012-05-29 15:36:08 -0700123#define MDSS_MDP_RIGHT_MIXER 0x100
124
Bryan Huntsman3f2bc4d2011-08-16 17:27:22 -0700125/* mdp_blit_req flag values */
126#define MDP_ROT_NOP 0
127#define MDP_FLIP_LR 0x1
128#define MDP_FLIP_UD 0x2
129#define MDP_ROT_90 0x4
130#define MDP_ROT_180 (MDP_FLIP_UD|MDP_FLIP_LR)
131#define MDP_ROT_270 (MDP_ROT_90|MDP_FLIP_UD|MDP_FLIP_LR)
132#define MDP_DITHER 0x8
133#define MDP_BLUR 0x10
134#define MDP_BLEND_FG_PREMULT 0x20000
135#define MDP_DEINTERLACE 0x80000000
136#define MDP_SHARPENING 0x40000000
137#define MDP_NO_DMA_BARRIER_START 0x20000000
138#define MDP_NO_DMA_BARRIER_END 0x10000000
139#define MDP_NO_BLIT 0x08000000
140#define MDP_BLIT_WITH_DMA_BARRIERS 0x000
141#define MDP_BLIT_WITH_NO_DMA_BARRIERS \
142 (MDP_NO_DMA_BARRIER_START | MDP_NO_DMA_BARRIER_END)
143#define MDP_BLIT_SRC_GEM 0x04000000
144#define MDP_BLIT_DST_GEM 0x02000000
145#define MDP_BLIT_NON_CACHED 0x01000000
146#define MDP_OV_PIPE_SHARE 0x00800000
147#define MDP_DEINTERLACE_ODD 0x00400000
148#define MDP_OV_PLAY_NOWAIT 0x00200000
149#define MDP_SOURCE_ROTATED_90 0x00100000
Liyuan Lid9736632011-11-11 13:47:59 -0800150#define MDP_DPP_HSIC 0x00080000
Ajay Singh Parmar4c7ccb32012-02-21 12:56:04 +0530151#define MDP_BACKEND_COMPOSITION 0x00040000
Nagamalleswararao Ganji880f8472011-12-14 03:52:28 -0800152#define MDP_BORDERFILL_SUPPORTED 0x00010000
153#define MDP_SECURE_OVERLAY_SESSION 0x00008000
154#define MDP_MEMORY_ID_TYPE_FB 0x00001000
Daniel Walkerda6df072010-04-23 16:04:20 -0700155
Bryan Huntsman3f2bc4d2011-08-16 17:27:22 -0700156#define MDP_TRANSP_NOP 0xffffffff
157#define MDP_ALPHA_NOP 0xff
158
159#define MDP_FB_PAGE_PROTECTION_NONCACHED (0)
160#define MDP_FB_PAGE_PROTECTION_WRITECOMBINE (1)
161#define MDP_FB_PAGE_PROTECTION_WRITETHROUGHCACHE (2)
162#define MDP_FB_PAGE_PROTECTION_WRITEBACKCACHE (3)
163#define MDP_FB_PAGE_PROTECTION_WRITEBACKWACACHE (4)
164/* Sentinel: Don't use! */
165#define MDP_FB_PAGE_PROTECTION_INVALID (5)
166/* Count of the number of MDP_FB_PAGE_PROTECTION_... values. */
167#define MDP_NUM_FB_PAGE_PROTECTION_VALUES (5)
Daniel Walkerda6df072010-04-23 16:04:20 -0700168
169struct mdp_rect {
Bryan Huntsman3f2bc4d2011-08-16 17:27:22 -0700170 uint32_t x;
171 uint32_t y;
172 uint32_t w;
173 uint32_t h;
Daniel Walkerda6df072010-04-23 16:04:20 -0700174};
175
176struct mdp_img {
Bryan Huntsman3f2bc4d2011-08-16 17:27:22 -0700177 uint32_t width;
178 uint32_t height;
179 uint32_t format;
180 uint32_t offset;
Daniel Walkerda6df072010-04-23 16:04:20 -0700181 int memory_id; /* the file descriptor */
Bryan Huntsman3f2bc4d2011-08-16 17:27:22 -0700182 uint32_t priv;
Daniel Walkerda6df072010-04-23 16:04:20 -0700183};
184
Bryan Huntsman3f2bc4d2011-08-16 17:27:22 -0700185/*
186 * {3x3} + {3} ccs matrix
187 */
188
189#define MDP_CCS_RGB2YUV 0
190#define MDP_CCS_YUV2RGB 1
191
192#define MDP_CCS_SIZE 9
193#define MDP_BV_SIZE 3
194
195struct mdp_ccs {
196 int direction; /* MDP_CCS_RGB2YUV or YUV2RGB */
197 uint16_t ccs[MDP_CCS_SIZE]; /* 3x3 color coefficients */
198 uint16_t bv[MDP_BV_SIZE]; /* 1x3 bias vector */
199};
200
Nagamalleswararao Ganji4b991722011-01-28 13:24:34 -0800201struct mdp_csc {
202 int id;
203 uint32_t csc_mv[9];
204 uint32_t csc_pre_bv[3];
205 uint32_t csc_post_bv[3];
206 uint32_t csc_pre_lv[6];
207 uint32_t csc_post_lv[6];
208};
209
Bryan Huntsman3f2bc4d2011-08-16 17:27:22 -0700210/* The version of the mdp_blit_req structure so that
211 * user applications can selectively decide which functionality
212 * to include
213 */
214
215#define MDP_BLIT_REQ_VERSION 2
216
Daniel Walkerda6df072010-04-23 16:04:20 -0700217struct mdp_blit_req {
218 struct mdp_img src;
219 struct mdp_img dst;
220 struct mdp_rect src_rect;
221 struct mdp_rect dst_rect;
Bryan Huntsman3f2bc4d2011-08-16 17:27:22 -0700222 uint32_t alpha;
223 uint32_t transp_mask;
224 uint32_t flags;
225 int sharpening_strength; /* -127 <--> 127, default 64 */
Daniel Walkerda6df072010-04-23 16:04:20 -0700226};
227
228struct mdp_blit_req_list {
Bryan Huntsman3f2bc4d2011-08-16 17:27:22 -0700229 uint32_t count;
Daniel Walkerda6df072010-04-23 16:04:20 -0700230 struct mdp_blit_req req[];
231};
232
Bryan Huntsman3f2bc4d2011-08-16 17:27:22 -0700233#define MSMFB_DATA_VERSION 2
234
235struct msmfb_data {
236 uint32_t offset;
237 int memory_id;
238 int id;
239 uint32_t flags;
240 uint32_t priv;
Vinay Kaliae1ba2702011-12-21 16:24:52 -0800241 uint32_t iova;
Bryan Huntsman3f2bc4d2011-08-16 17:27:22 -0700242};
243
244#define MSMFB_NEW_REQUEST -1
245
246struct msmfb_overlay_data {
247 uint32_t id;
248 struct msmfb_data data;
249 uint32_t version_key;
250 struct msmfb_data plane1_data;
251 struct msmfb_data plane2_data;
252};
253
254struct msmfb_img {
255 uint32_t width;
256 uint32_t height;
257 uint32_t format;
258};
259
Vinay Kalia27020d12011-10-14 17:50:29 -0700260#define MSMFB_WRITEBACK_DEQUEUE_BLOCKING 0x1
261struct msmfb_writeback_data {
262 struct msmfb_data buf_info;
263 struct msmfb_img img;
264};
265
Bryan Huntsman3f2bc4d2011-08-16 17:27:22 -0700266struct dpp_ctrl {
267 /*
268 *'sharp_strength' has inputs = -128 <-> 127
269 * Increasingly positive values correlate with increasingly sharper
270 * picture. Increasingly negative values correlate with increasingly
271 * smoothed picture.
272 */
273 int8_t sharp_strength;
Liyuan Lid9736632011-11-11 13:47:59 -0800274 int8_t hsic_params[NUM_HSIC_PARAM];
Bryan Huntsman3f2bc4d2011-08-16 17:27:22 -0700275};
276
277struct mdp_overlay {
278 struct msmfb_img src;
279 struct mdp_rect src_rect;
280 struct mdp_rect dst_rect;
281 uint32_t z_order; /* stage number */
282 uint32_t is_fg; /* control alpha & transp */
283 uint32_t alpha;
284 uint32_t transp_mask;
285 uint32_t flags;
286 uint32_t id;
287 uint32_t user_data[8];
288 struct dpp_ctrl dpp;
289};
290
291struct msmfb_overlay_3d {
292 uint32_t is_3d;
293 uint32_t width;
294 uint32_t height;
295};
296
297
298struct msmfb_overlay_blt {
299 uint32_t enable;
300 uint32_t offset;
301 uint32_t width;
302 uint32_t height;
303 uint32_t bpp;
304};
305
306struct mdp_histogram {
307 uint32_t frame_cnt;
308 uint32_t bin_cnt;
309 uint32_t *r;
310 uint32_t *g;
311 uint32_t *b;
312};
313
Pravin Tamkhane02a40682011-11-29 14:17:01 -0800314
315/*
316
317 mdp_block_type defines the identifiers for each of pipes in MDP 4.3
318
319 MDP_BLOCK_RESERVED is provided for backward compatibility and is
320 deprecated. It corresponds to DMA_P. So MDP_BLOCK_DMA_P should be used
321 instead.
322
323*/
324
325enum {
326 MDP_BLOCK_RESERVED = 0,
327 MDP_BLOCK_OVERLAY_0,
328 MDP_BLOCK_OVERLAY_1,
329 MDP_BLOCK_VG_1,
330 MDP_BLOCK_VG_2,
331 MDP_BLOCK_RGB_1,
332 MDP_BLOCK_RGB_2,
333 MDP_BLOCK_DMA_P,
334 MDP_BLOCK_DMA_S,
335 MDP_BLOCK_DMA_E,
Pravin Tamkhaneb18c9e22012-04-13 18:29:34 -0700336 MDP_BLOCK_OVERLAY_2,
Pravin Tamkhane02a40682011-11-29 14:17:01 -0800337 MDP_BLOCK_MAX,
338};
339
Carl Vanderlipba093a22011-11-22 13:59:59 -0800340/*
341 * mdp_histogram_start_req is used to provide the parameters for
342 * histogram start request
343 */
344
345struct mdp_histogram_start_req {
346 uint32_t block;
347 uint8_t frame_cnt;
348 uint8_t bit_mask;
349 uint8_t num_bins;
350};
351
352/*
353 * mdp_histogram_data is used to return the histogram data, once
354 * the histogram is done/stopped/cance
355 */
356
357struct mdp_histogram_data {
358 uint32_t block;
359 uint8_t bin_cnt;
360 uint32_t *c0;
361 uint32_t *c1;
362 uint32_t *c2;
Carl Vanderlip7b8b6402012-03-01 10:58:03 -0800363 uint32_t *extra_info;
Carl Vanderlipba093a22011-11-22 13:59:59 -0800364};
365
Pravin Tamkhane02a40682011-11-29 14:17:01 -0800366struct mdp_pcc_coeff {
367 uint32_t c, r, g, b, rr, gg, bb, rg, gb, rb, rgb_0, rgb_1;
368};
369
370struct mdp_pcc_cfg_data {
371 uint32_t block;
372 uint32_t ops;
373 struct mdp_pcc_coeff r, g, b;
374};
375
Carl Vanderlipfa1de672011-12-05 12:37:59 -0800376#define MDP_CSC_FLAG_ENABLE 0x1
377#define MDP_CSC_FLAG_YUV_IN 0x2
378#define MDP_CSC_FLAG_YUV_OUT 0x4
379
Pravin Tamkhane02a40682011-11-29 14:17:01 -0800380struct mdp_csc_cfg {
381 /* flags for enable CSC, toggling RGB,YUV input/output */
382 uint32_t flags;
383 uint32_t csc_mv[9];
384 uint32_t csc_pre_bv[3];
385 uint32_t csc_post_bv[3];
386 uint32_t csc_pre_lv[6];
387 uint32_t csc_post_lv[6];
388};
389
390struct mdp_csc_cfg_data {
391 uint32_t block;
392 struct mdp_csc_cfg csc_data;
393};
394
395enum {
396 mdp_lut_igc,
397 mdp_lut_pgc,
398 mdp_lut_hist,
399 mdp_lut_max,
400};
401
402
403struct mdp_igc_lut_data {
404 uint32_t block;
405 uint32_t len, ops;
406 uint32_t *c0_c1_data;
407 uint32_t *c2_data;
408};
409
410struct mdp_ar_gc_lut_data {
411 uint32_t x_start;
412 uint32_t slope;
413 uint32_t offset;
414};
415
416struct mdp_pgc_lut_data {
417 uint32_t block;
418 uint32_t flags;
419 uint8_t num_r_stages;
420 uint8_t num_g_stages;
421 uint8_t num_b_stages;
422 struct mdp_ar_gc_lut_data *r_data;
423 struct mdp_ar_gc_lut_data *g_data;
424 struct mdp_ar_gc_lut_data *b_data;
425};
426
427
428struct mdp_hist_lut_data {
429 uint32_t block;
430 uint32_t ops;
431 uint32_t len;
432 uint32_t *data;
433};
434
435
436struct mdp_lut_cfg_data {
437 uint32_t lut_type;
438 union {
439 struct mdp_igc_lut_data igc_lut_data;
440 struct mdp_pgc_lut_data pgc_lut_data;
441 struct mdp_hist_lut_data hist_lut_data;
442 } data;
443};
444
Pravin Tamkhane67726da2012-04-13 11:59:11 -0700445struct mdp_qseed_cfg_data {
446 uint32_t block;
447 uint32_t table_num;
448 uint32_t ops;
449 uint32_t len;
450 uint32_t *data;
451};
452
453
Pravin Tamkhane02a40682011-11-29 14:17:01 -0800454enum {
455 mdp_op_pcc_cfg,
456 mdp_op_csc_cfg,
457 mdp_op_lut_cfg,
Pravin Tamkhane67726da2012-04-13 11:59:11 -0700458 mdp_op_qseed_cfg,
Pravin Tamkhane02a40682011-11-29 14:17:01 -0800459 mdp_op_max,
460};
461
462struct msmfb_mdp_pp {
463 uint32_t op;
464 union {
465 struct mdp_pcc_cfg_data pcc_cfg_data;
466 struct mdp_csc_cfg_data csc_cfg_data;
467 struct mdp_lut_cfg_data lut_cfg_data;
Pravin Tamkhane67726da2012-04-13 11:59:11 -0700468 struct mdp_qseed_cfg_data qseed_cfg_data;
Pravin Tamkhane02a40682011-11-29 14:17:01 -0800469 } data;
470};
471
472
Bryan Huntsman3f2bc4d2011-08-16 17:27:22 -0700473struct mdp_page_protection {
474 uint32_t page_protection;
475};
476
kuogee hsieh405dc302011-07-21 15:06:59 -0700477
478struct mdp_mixer_info {
479 int pndx;
480 int pnum;
481 int ptype;
482 int mixer_num;
483 int z_order;
484};
485
486#define MAX_PIPE_PER_MIXER 4
487
488struct msmfb_mixer_info_req {
489 int mixer_num;
490 int cnt;
491 struct mdp_mixer_info info[MAX_PIPE_PER_MIXER];
492};
493
Ravishangar Kalyanam6bc448a2012-03-14 11:31:52 -0700494enum {
495 DISPLAY_SUBSYSTEM_ID,
496 ROTATOR_SUBSYSTEM_ID,
497};
kuogee hsieh405dc302011-07-21 15:06:59 -0700498
Bryan Huntsman3f2bc4d2011-08-16 17:27:22 -0700499#ifdef __KERNEL__
500
501/* get the framebuffer physical address information */
Ravishangar Kalyanam6bc448a2012-03-14 11:31:52 -0700502int get_fb_phys_info(unsigned long *start, unsigned long *len, int fb_num,
503 int subsys_id);
Vinay Kalia27020d12011-10-14 17:50:29 -0700504struct fb_info *msm_fb_get_writeback_fb(void);
505int msm_fb_writeback_init(struct fb_info *info);
Vinay Kaliae1ba2702011-12-21 16:24:52 -0800506int msm_fb_writeback_start(struct fb_info *info);
Vinay Kalia27020d12011-10-14 17:50:29 -0700507int msm_fb_writeback_queue_buffer(struct fb_info *info,
508 struct msmfb_data *data);
509int msm_fb_writeback_dequeue_buffer(struct fb_info *info,
510 struct msmfb_data *data);
Vinay Kaliae1ba2702011-12-21 16:24:52 -0800511int msm_fb_writeback_stop(struct fb_info *info);
Vinay Kalia27020d12011-10-14 17:50:29 -0700512int msm_fb_writeback_terminate(struct fb_info *info);
Bryan Huntsman3f2bc4d2011-08-16 17:27:22 -0700513#endif
514
515#endif /*_MSM_MDP_H_*/