mirror of
https://github.com/hardkernel/linux.git
synced 2026-06-07 11:26:02 +09:00
codec_mm: clear scatter cache when codec_mm_codec_in failed
PD#158909: clear scatter cache when codec_mm_codec_in failed Change-Id: Ie3f4da06699222b6dbd8caee6982dc71288881c1 Signed-off-by: Yao.Liu <yao.liu@amlogic.com>
This commit is contained in:
@@ -572,7 +572,7 @@ struct codec_mm_s *codec_mm_alloc(const char *owner, int size,
|
||||
mem->align2n = align2n;
|
||||
mem->flags = memflags;
|
||||
ret = codec_mm_alloc_in(mgt, mem);
|
||||
if (ret == -10003 &&
|
||||
if (ret < 0 &&
|
||||
mgt->alloced_for_sc_cnt > 0 && /*have used for scatter.*/
|
||||
!(memflags & CODEC_MM_FLAGS_FOR_SCATTER)) {
|
||||
/*if not scatter, free scatter caches. */
|
||||
|
||||
Reference in New Issue
Block a user