]>
Commit | Line | Data |
---|---|---|
9d200153 SM |
1 | /* Copyright (c) 2009-2010, Code Aurora Forum. All rights reserved. |
2 | * | |
3 | * Redistribution and use in source and binary forms, with or without | |
4 | * modification, are permitted provided that the following conditions are | |
5 | * met: | |
6 | * * Redistributions of source code must retain the above copyright | |
7 | * notice, this list of conditions and the following disclaimer. | |
8 | * * Redistributions in binary form must reproduce the above | |
9 | * copyright notice, this list of conditions and the following | |
10 | * disclaimer in the documentation and/or other materials provided | |
11 | * with the distribution. | |
12 | * * Neither the name of Code Aurora Forum, Inc. nor the names of its | |
13 | * contributors may be used to endorse or promote products derived | |
14 | * from this software without specific prior written permission. | |
15 | * | |
16 | * THIS SOFTWARE IS PROVIDED "AS IS" AND ANY EXPRESS OR IMPLIED | |
17 | * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF | |
18 | * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT | |
19 | * ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS | |
20 | * BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR | |
21 | * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF | |
22 | * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR | |
23 | * BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, | |
24 | * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE | |
25 | * OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN | |
26 | * IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. | |
27 | * | |
28 | */ | |
29 | ||
30 | #ifndef MDP_PPP_DQ_H | |
31 | #define MDP_PPP_DQ_H | |
32 | ||
33 | #include "msm_fb_def.h" | |
34 | ||
35 | #define MDP_PPP_DEBUG_MSG MSM_FB_DEBUG | |
36 | ||
37 | /* The maximum number of <Reg,Val> pairs in an mdp_ppp_roi_cmd_set structure (a | |
38 | * node) | |
39 | */ | |
40 | #define MDP_PPP_ROI_NODE_SIZE 32 | |
41 | ||
42 | /* ROI config command (<Reg,Val> pair) for MDP PPP block */ | |
43 | struct mdp_ppp_roi_cmd { | |
44 | uint32_t reg; | |
45 | uint32_t val; | |
46 | }; | |
47 | ||
48 | /* ROI config commands for MDP PPP block are stored in a list of | |
49 | * mdp_ppp_roi_cmd_set structures (nodes). | |
50 | */ | |
51 | struct mdp_ppp_roi_cmd_set { | |
52 | struct list_head node; | |
53 | uint32_t ncmds; /* number of commands in this set (node). */ | |
54 | struct mdp_ppp_roi_cmd cmd[MDP_PPP_ROI_NODE_SIZE]; | |
55 | }; | |
56 | ||
57 | /* MDP PPP Display Job (DJob) */ | |
58 | struct mdp_ppp_djob { | |
59 | struct list_head entry; | |
60 | /* One ROI per MDP PPP DJob */ | |
61 | struct list_head roi_cmd_list; | |
62 | struct mdp_blit_req req; | |
63 | struct fb_info *info; | |
64 | struct delayed_work cleaner; | |
65 | struct file *p_src_file, *p_dst_file; | |
66 | }; | |
67 | ||
68 | extern struct completion mdp_ppp_comp; | |
69 | extern boolean mdp_ppp_waiting; | |
70 | extern unsigned long mdp_timer_duration; | |
71 | ||
72 | unsigned int mdp_ppp_async_op_get(void); | |
73 | void mdp_ppp_async_op_set(unsigned int flag); | |
74 | void msm_fb_ensure_mem_coherency_after_dma(struct fb_info *info, | |
75 | struct mdp_blit_req *req_list, int req_list_count); | |
76 | void mdp_ppp_put_img(struct file *p_src_file, struct file *p_dst_file); | |
77 | void mdp_ppp_dq_init(void); | |
78 | void mdp_ppp_outdw(uint32_t addr, uint32_t data); | |
79 | struct mdp_ppp_djob *mdp_ppp_new_djob(void); | |
80 | void mdp_ppp_clear_curr_djob(void); | |
81 | void mdp_ppp_process_curr_djob(void); | |
82 | int mdp_ppp_get_ret_code(void); | |
83 | void mdp_ppp_djob_done(void); | |
84 | void mdp_ppp_wait(void); | |
85 | ||
86 | #endif /* MDP_PPP_DQ_H */ |