[AMD Public Use] You are right
@Zhou1, Tao, I am preparing a separate patch to have a dedicated function to get umc channel idx Thank you, John Clements From: Zhou1, Tao <Tao.Zhou1@xxxxxxx> uint32_t channel_index = adev->umc.channel_idx_tbl[umc_inst * adev->umc.channel_inst_num + ch_inst]; The code is too long, it can be separated into two lines. With that fixed, the patch is: Reviewed-by: Tao Zhou <tao.zhou1@xxxxxxx> From: amd-gfx <amd-gfx-bounces@xxxxxxxxxxxxxxxxxxxxx> on behalf of Clements, John <John.Clements@xxxxxxx> [AMD Public Use] Hello GuChun/Tao, Thank you for your feedback, I have implemented both of your changes. Thank you, John Clements From: Chen, Guchun <Guchun.Chen@xxxxxxx>
[AMD Public Use] If we have to improve the macro definition for repetitive loops, I assume we can merge the two defines into one, like: #define LOOP_UMC_CH_INST(umc_inst) for ((umc_inst) = 0; (umc_inst) < adev->umc.umc_inst##_num; (umc_inst)++) Then when we call the double loop, it can be done like: LOOP_UMC_CH_INST(umc_inst) LOOP_UMC_CH_INST(channel_inst) {… Next we should name the macro more friendly. Regards, Guchun From: Clements, John <John.Clements@xxxxxxx>
[AMD Official Use Only - Internal Distribution Only] Resolved issue with inputting an incorrect UMC channel index into the UMC error address record. Defined macros for repetitive for loops Thank you, John Clements |
_______________________________________________ amd-gfx mailing list amd-gfx@xxxxxxxxxxxxxxxxxxxxx https://lists.freedesktop.org/mailman/listinfo/amd-gfx