arch/arm/mach-msm/htc_battery_core: fix array out of bounds