static int msm_fb_ioctl(struct fb_info *info, unsigned int cmd, unsigned long arg)
+-- ...
+-- switch (cmd) {
case MSMFB_OVERLAY_GET:
case MSMFB_OVERLAY_SET:
case MSMFB_OVERLAY_UNSET:
case MSMFB_OVERLAY_PLAY:
case MSMFB_OVERLAY_PLAY_ENABLE:
case MSMFB_BLIT:
case MSMFB_SET_CCS_MATRIX:
case MSMFB_GET_CCS_MATRIX:
case MSMFB_GRP_DISP:
case MSMFB_SUSPEND_SW_REFRESHER:
case MSMFB_RESUME_SW_REFRESHER:
case MSMFB_CURSOR:
case MSMFB_SET_LUT:
case MSMFB_HISTOGRAM:
case MSMFB_GET_PAGE_PROTECTION:
case MSMFB_SET_PAGE_PROTECTION:
}
+-- ...
//处理用户空间传入的request list
msm_fb_ioctl(struct fb_info *info, unsigned int cmd, unsigned long arg) //for MSMFB_BLIT ...
+-- msmfb_blit(info, argp);
+-- copy_from_user(&req_list_header, p, sizeof(req_list_header))
+-- p += sizeof(req_list_header);
+-- count = req_list_header.count;
+-- while (count > 0) {
req_list_count = count;
if (req_list_count > MAX_LIST_WINDOW)
req_list_count = MAX_LIST_WINDOW;
if (copy_from_user(&req_list, p, sizeof(struct mdp_blit_req)*req_list_count))
return -EFAULT;
msm_fb_ensure_memory_coherency_before_dma(info, req_list, req_list_count);
for (i = 0; i < req_list_count; i++) {
if (!(req_list[i].flags & MDP_NO_BLIT)) {
int ret = mdp_blit(info, &(req_list[i])); //Do the actual blit ...
if (ret)
return ret;
}
}
msm_fb_ensure_memory_coherency_after_dma(info, req_list, req_list_count);
count -= req_list_count;
p += sizeof(struct mdp_blit_req)*req_list_count;
}
int
mdp_blit(struct fb_info *info, struct mdp_blit_req *req)
+-- mdp_ppp_blit(info, req);
Qcom_lcd_driver 之二 -- IOCTL
最新推荐文章于 2023-03-20 18:03:05 发布
本文深入分析了MSM FB ioctl命令的用途和MDP blit流程实现细节,包括overlay操作、blit命令处理、内存一致性确保等关键步骤。
761

被折叠的 条评论
为什么被折叠?



