NXP-10148: cleanup/fix some sonar violations