radeon/uvd: make 30M as minimum for MPEG4 dpb buffer size
authorLeo Liu <leo.liu@amd.com>
Thu, 12 Mar 2015 20:24:57 +0000 (16:24 -0400)
committerMarek Olšák <marek.olsak@amd.com>
Fri, 14 Aug 2015 13:02:30 +0000 (15:02 +0200)
Signed-off-by: Leo Liu <leo.liu@amd.com>
Reviewed-by: Christian König <christian.koenig@amd.com>
src/gallium/drivers/radeon/radeon_uvd.c

index 7b0eb1110d3d01d6ba09a0d2f8e01667ba990c53..375b5c06e125a5901db2d3b283097f00d7f21845 100644 (file)
@@ -304,6 +304,8 @@ static unsigned calc_dpb_size(struct ruvd_decoder *dec)
 
                // IT surface buffer
                dpb_size += align(width_in_mb * height_in_mb * 32, 64);
+
+               dpb_size = MAX2(dpb_size, 30 * 1024 * 1024);
                break;
 
        default: