system: Update function to calculate bytes per sample for offload

Update function to calculate bytes per sample for offload format

Change-Id: I46b78024293be959ad5d1db1f583933d2ab14576
Merge branch 'cm-11.0' of github.com:CyanogenMod/android_system_core into cm-11.0