请教A133 G2D调用出现G2D irq pending flag timeout,G2D BITBLT Failed!
-
如题,我把G2D的调试打开,看输入输出参数都没问题,但没有接收到完成中断,请教是什么问题。下面是我的调试LOG
[ 754.288879] [G2D-g2d_bsp_bitblt] line:1970: BITBLT_flag: 0x0
[ 754.288886] [G2D-g2d_bsp_bitblt] line:1972: Input info:---------------------------------
[ 754.288890] [G2D-g2d_bsp_bitblt] line:1973: Src_fd: 6
[ 754.288895] [G2D-g2d_bsp_bitblt] line:1974: Format: 0x29
[ 754.288899] [G2D-g2d_bsp_bitblt] line:1975: BITBLT_alpha_mode: 0x0
[ 754.288904] [G2D-g2d_bsp_bitblt] line:1976: BITBLT_alpha_val: 0x0
[ 754.288908] [G2D-g2d_bsp_bitblt] line:1977: inClipRectX: 0
[ 754.288912] [G2D-g2d_bsp_bitblt] line:1978: inClipRectY: 0
[ 754.288917] [G2D-g2d_bsp_bitblt] line:1979: inClipRectW: 1920
[ 754.288921] [G2D-g2d_bsp_bitblt] line:1980: inClipRectH: 1080
[ 754.288925] [G2D-g2d_bsp_bitblt] line:1982: Output info:--------------------------------
[ 754.288930] [G2D-g2d_bsp_bitblt] line:1983: Dst_fd: 23
[ 754.288934] [G2D-g2d_bsp_bitblt] line:1984: Format: 0x3
[ 754.288938] [G2D-g2d_bsp_bitblt] line:1985: outClipRectX: 0
[ 754.288943] [G2D-g2d_bsp_bitblt] line:1986: outClipRectY: 0
[ 754.288947] [G2D-g2d_bsp_bitblt] line:1987: outClipRectW: 1920
[ 754.288951] [G2D-g2d_bsp_bitblt] line:1988: outClipRectH: 1080
[ 754.288958] [G2D-g2d_vlayer_set] line:627: VInPITCH: 1920, 1920, 0
[ 754.288964] [G2D-g2d_vlayer_set] line:629: VInAddrB: 0xf7400000, 0xf75fa400, 0xf76f7600
[ 754.288969] [G2D-g2d_vlayer_set] line:646: VInAddrA: 0xf7400000, 0xf75fa400, 0xf76f7600
[ 754.288983] [G2D-g2d_bldin_set] line:1359: BLD_CH_ISIZE W: 0x780
[ 754.288987] [G2D-g2d_bldin_set] line:1360: BLD_CH_ISIZE H: 0x438
[ 754.288991] [G2D-g2d_bldin_set] line:1367: BLD_CH_ISIZE X: 0x0
[ 754.288996] [G2D-g2d_bldin_set] line:1368: BLD_CH_ISIZE Y: 0x0
[ 754.289002] [G2D-g2d_wb_set] line:717: BLD_CH_OSIZE W: 0x780
[ 754.289006] [G2D-g2d_wb_set] line:718: BLD_CH_OSIZE H: 0x438
[ 754.289012] [G2D-g2d_wb_set] line:765: OutputPitch: 7680, 0, 0
[ 754.289017] [G2D-g2d_wb_set] line:782: WbAddr: 0xf6800000, 0xf69fa400, 0xf6bf4800
[ 754.289022] [G2D-g2d_bsp_bitblt] line:2297: INIT_MODULE: 0x80000000
[ 754.390950] G2D irq pending flag timeout
[ 754.390956] G2D BITBLT Failed! -
改为了使用物理地址,也还是一样
[ 4408.395590] [G2D-g2d_bsp_bitblt] line:1970: BITBLT_flag: 0x0
[ 4408.395597] [G2D-g2d_bsp_bitblt] line:1972: Input info:---------------------------------
[ 4408.395601] [G2D-g2d_bsp_bitblt] line:1973: Src_fd: 0
[ 4408.395605] [G2D-g2d_bsp_bitblt] line:1974: Format: 0x29
[ 4408.395609] [G2D-g2d_bsp_bitblt] line:1975: BITBLT_alpha_mode: 0x0
[ 4408.395614] [G2D-g2d_bsp_bitblt] line:1976: BITBLT_alpha_val: 0x0
[ 4408.395618] [G2D-g2d_bsp_bitblt] line:1977: inClipRectX: 0
[ 4408.395623] [G2D-g2d_bsp_bitblt] line:1978: inClipRectY: 0
[ 4408.395627] [G2D-g2d_bsp_bitblt] line:1979: inClipRectW: 1920
[ 4408.395631] [G2D-g2d_bsp_bitblt] line:1980: inClipRectH: 1080
[ 4408.395636] [G2D-g2d_bsp_bitblt] line:1982: Output info:--------------------------------
[ 4408.395640] [G2D-g2d_bsp_bitblt] line:1983: Dst_fd: 0
[ 4408.395644] [G2D-g2d_bsp_bitblt] line:1984: Format: 0x3
[ 4408.395649] [G2D-g2d_bsp_bitblt] line:1985: outClipRectX: 0
[ 4408.395653] [G2D-g2d_bsp_bitblt] line:1986: outClipRectY: 0
[ 4408.395657] [G2D-g2d_bsp_bitblt] line:1987: outClipRectW: 1920
[ 4408.395662] [G2D-g2d_bsp_bitblt] line:1988: outClipRectH: 1080
[ 4408.395669] [G2D-g2d_vlayer_set] line:627: VInPITCH: 1920, 1920, 0
[ 4408.395674] [G2D-g2d_vlayer_set] line:629: VInAddrB: 0xff400000, 0xff5fa400, 0x0
[ 4408.395679] [G2D-g2d_vlayer_set] line:646: VInAddrA: 0xff400000, 0xff5fa400, 0x0
[ 4408.395693] [G2D-g2d_bldin_set] line:1359: BLD_CH_ISIZE W: 0x780
[ 4408.395697] [G2D-g2d_bldin_set] line:1360: BLD_CH_ISIZE H: 0x438
[ 4408.395702] [G2D-g2d_bldin_set] line:1367: BLD_CH_ISIZE X: 0x0
[ 4408.395706] [G2D-g2d_bldin_set] line:1368: BLD_CH_ISIZE Y: 0x0
[ 4408.395712] [G2D-g2d_wb_set] line:717: BLD_CH_OSIZE W: 0x780
[ 4408.395717] [G2D-g2d_wb_set] line:718: BLD_CH_OSIZE H: 0x438
[ 4408.395722] [G2D-g2d_wb_set] line:765: OutputPitch: 7680, 0, 0
[ 4408.395727] [G2D-g2d_wb_set] line:782: WbAddr: 0xf9000000, 0x0, 0x0
[ 4408.395732] [G2D-g2d_bsp_bitblt] line:2297: INIT_MODULE: 0x80000000
[ 4408.496871] G2D irq pending flag timeout
[ 4408.496876] G2D BITBLT Failed!下面是我调用的代码
int g2d::NV21ToRGB(ion_mem* in, ion_mem* out)
{
int ret = 0;
g2d_blt_h blit;memset(&blit, 0, sizeof(blit)); if(g2d_fd < 0) { printf("G2D not open! \n"); return -1; } blit.flag_h = G2D_BLT_NONE_H; //纯转换 blit.src_image_h.format = G2D_FORMAT_YUV420UVC_U1V1U0V0; //NV21 blit.src_image_h.width = IMAGEWIDTH; blit.src_image_h.height = IMAGEHEIGHT; blit.src_image_h.align[0] = 0; blit.src_image_h.align[1] = 0; blit.src_image_h.clip_rect.x = 0; blit.src_image_h.clip_rect.y = 0; blit.src_image_h.clip_rect.w = IMAGEWIDTH; blit.src_image_h.clip_rect.h = IMAGEHEIGHT; blit.src_image_h.gamut = G2D_BT601; blit.src_image_h.bpremul = 0; blit.src_image_h.mode = G2D_PIXEL_ALPHA; blit.src_image_h.use_phy_addr = 1; blit.src_image_h.laddr[0] = in->phy; blit.src_image_h.laddr[1] = in->phy + IMAGEWIDTH * IMAGEHEIGHT; blit.dst_image_h.format = G2D_FORMAT_BGRA8888; blit.dst_image_h.width = IMAGEWIDTH; blit.dst_image_h.height = IMAGEHEIGHT; blit.dst_image_h.align[0] = 0; blit.dst_image_h.clip_rect.x = 0; blit.dst_image_h.clip_rect.y = 0; blit.dst_image_h.clip_rect.w = IMAGEWIDTH; blit.dst_image_h.clip_rect.h = IMAGEHEIGHT; blit.dst_image_h.gamut = G2D_BT601; blit.dst_image_h.bpremul = 0; blit.dst_image_h.mode = G2D_PIXEL_ALPHA; blit.dst_image_h.use_phy_addr = 1; blit.dst_image_h.laddr[0] = out->phy; if(ioctl(g2d_fd, G2D_CMD_BITBLT_H, (unsigned long)&blit) < 0) { printf("G2D convert failed! \n"); return -1; } return 0;
}
-
终于找到问题了,A133的G2D被精准刀法砍掉,G2D只有旋转功能,WriteBack功能也被砍掉,导致不能做RGB转YUV![9448fcc0-d8a4-4cc6-9623-79b305845553-FSLUSEV8BB~XYA$680`ERU.png
Copyright © 2024 深圳全志在线有限公司 粤ICP备2021084185号 粤公网安备44030502007680号