Compute buffer sizes with 8-byte alignment.

The binder kernel drivers copies the TYPE_PTR buffer
objects into a single contiguous area in the target
process. This means that if we copy, say a hidl_vec with
9 bytes in it, the buffer following it would not be
properly aligned. Since the maximum native data size
type HIDL/hwbinder supports today is 8 bytes, we compute
the required buffer sizes with 8 byte alignments.

Bug: 31228745
Test: hidl_test
Change-Id: I26cc500690ec32ab7ae0699563af7bc4ad489334
1 file changed