drm/amdgpu: fix a compiling error in old kernels
This patch is used to fix following compiling error that occurs in some old kernels. error: ‘for’ loop initial declarations are only allowed in C99 mode for (int i = 0; i < dc->res_pool->res_cap->num_dsc; i++) { Signed-off-by: Asher Song <Asher.Song@amd.com> Reviewed-by: Guchun Chen <guchun.chen@amd.com> Reviewed-by: Christian König <christian.koenig@amd.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
This commit is contained in:
parent
940d4dd402
commit
9e447c811a
@ -1402,8 +1402,9 @@ void dcn32_update_dsc_pg(struct dc *dc,
|
||||
bool safe_to_disable)
|
||||
{
|
||||
struct dce_hwseq *hws = dc->hwseq;
|
||||
int i;
|
||||
|
||||
for (int i = 0; i < dc->res_pool->res_cap->num_dsc; i++) {
|
||||
for (i = 0; i < dc->res_pool->res_cap->num_dsc; i++) {
|
||||
struct display_stream_compressor *dsc = dc->res_pool->dscs[i];
|
||||
bool is_dsc_ungated = hws->funcs.dsc_pg_status(hws, dsc->inst);
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user