[PATCH 6.1 205/219] platform/mellanox: mlxbf-pmc: Fix potential buffer overflows