[PATCH openEuler-5.10 081/100] mlxsw: thermal: Fix out-of-bounds memory accesses