Skip to content

Commit

Permalink
libavrkmpp: force use DMA32 buffer
Browse files Browse the repository at this point in the history
RGA2 does not support memory over 4GB
  • Loading branch information
jjm2473 committed Jun 15, 2023
1 parent 2fea5c6 commit 7e350f9
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion libavcodec/rkmppdec.c
Original file line number Diff line number Diff line change
Expand Up @@ -249,7 +249,7 @@ static int rkmpp_init_decoder(AVCodecContext *avctx)
goto fail;
}

ret = mpp_buffer_group_get_internal(&decoder->frame_group, MPP_BUFFER_TYPE_DRM);
ret = mpp_buffer_group_get_internal(&decoder->frame_group, MPP_BUFFER_TYPE_DRM | MPP_BUFFER_FLAGS_DMA32);
if (ret) {
av_log(avctx, AV_LOG_ERROR, "Failed to get buffer group (code = %d)\n", ret);
ret = AVERROR_UNKNOWN;
Expand Down
2 changes: 1 addition & 1 deletion libavfilter/vf_scale_rga.c
Original file line number Diff line number Diff line change
Expand Up @@ -486,7 +486,7 @@ static av_cold int scale_rga_init(AVFilterContext *avctx)
if (ret = init_dict(avctx))
return ret;

if (ret = mpp_buffer_group_get_internal(&ctx->frame_group, MPP_BUFFER_TYPE_DRM)) {
if (ret = mpp_buffer_group_get_internal(&ctx->frame_group, MPP_BUFFER_TYPE_DRM | MPP_BUFFER_FLAGS_DMA32)) {
av_log(ctx, AV_LOG_ERROR, "Failed to get buffer group (code = %d)\n", ret);
return AVERROR_UNKNOWN;
}
Expand Down

0 comments on commit 7e350f9

Please sign in to comment.