File tree Expand file tree Collapse file tree 1 file changed +6
-2
lines changed Expand file tree Collapse file tree 1 file changed +6
-2
lines changed Original file line number Diff line number Diff line change @@ -3766,12 +3766,12 @@ static int wm_adsp_buffer_populate(struct wm_adsp_compr_buf *buf)
37663766 ret = wm_adsp_buffer_read (buf , caps -> region_defs [i ].base_offset ,
37673767 & region -> base_addr );
37683768 if (ret < 0 )
3769- return ret ;
3769+ goto err ;
37703770
37713771 ret = wm_adsp_buffer_read (buf , caps -> region_defs [i ].size_offset ,
37723772 & offset );
37733773 if (ret < 0 )
3774- return ret ;
3774+ goto err ;
37753775
37763776 region -> cumulative_size = offset ;
37773777
@@ -3782,6 +3782,10 @@ static int wm_adsp_buffer_populate(struct wm_adsp_compr_buf *buf)
37823782 }
37833783
37843784 return 0 ;
3785+
3786+ err :
3787+ kfree (buf -> regions );
3788+ return ret ;
37853789}
37863790
37873791static void wm_adsp_buffer_clear (struct wm_adsp_compr_buf * buf )
You can’t perform that action at this time.
0 commit comments