mirror of
https://github.com/torvalds/linux.git
synced 2026-04-19 07:13:56 -04:00
drm/amdkfd: Fix MEC pipe interrupt enablement
for_each_inst modifies xcc_mask and therefore the loop doesn't
initialize properly interrupts on all pipes. Keep looping through xcc as
the outer loop to fix this issue.
Fixes: c4050ff1a4 ("drm/amdkfd: Use xcc mask for identifying xcc")
Signed-off-by: Lijo Lazar <lijo.lazar@amd.com>
Reviewed-by: Hawking Zhang <Hawking.Zhang@amd.com>
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
This commit is contained in:
@@ -1274,11 +1274,12 @@ static void init_interrupts(struct device_queue_manager *dqm)
|
||||
uint32_t xcc_mask = dqm->dev->xcc_mask;
|
||||
unsigned int i, xcc_id;
|
||||
|
||||
for (i = 0 ; i < get_pipes_per_mec(dqm) ; i++) {
|
||||
if (is_pipe_enabled(dqm, 0, i)) {
|
||||
for_each_inst(xcc_id, xcc_mask)
|
||||
for_each_inst(xcc_id, xcc_mask) {
|
||||
for (i = 0 ; i < get_pipes_per_mec(dqm) ; i++) {
|
||||
if (is_pipe_enabled(dqm, 0, i)) {
|
||||
dqm->dev->kfd2kgd->init_interrupts(
|
||||
dqm->dev->adev, i, xcc_id);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user