Merge "Refactor hid command, mitigate overflows"
am: 4d722cdbcd

Change-Id: I1f7d46efdcb6008dd62a3daaaed2e00f1bbc87b3