mirror of
https://github.com/Telecominfraproject/OpenCellular.git
synced 2025-12-29 01:50:53 +00:00
usb_updater: use same endian conversion functions
This is just a clean up patch, unifying all cases where endian
conversions are used in the usb updater source code.
BRANCH=none
BUG=none
TEST=usb update of cr50 is still possible on gru (which uses the code
being changed).
Change-Id: I362e9762493854b4fdbb9ec15c2cb363003f258a
Signed-off-by: Vadim Bendebury <vbendeb@chromium.org>
Reviewed-on: https://chromium-review.googlesource.com/414443
Reviewed-by: Mary Ruthven <mruthven@chromium.org>
This commit is contained in:
committed by
chrome-bot
parent
0f23c61fac
commit
cfbdf96086
@@ -227,12 +227,12 @@ static int tpm_send_pkt(int fd, unsigned int digest, unsigned int addr,
|
||||
|
||||
len = size + sizeof(struct upgrade_pkt);
|
||||
|
||||
out->tag = __cpu_to_be16(0x8001);
|
||||
out->length = __cpu_to_be32(len);
|
||||
out->ordinal = __cpu_to_be32(EXT_CMD);
|
||||
out->subcmd = __cpu_to_be16(subcmd);
|
||||
out->tag = htobe16(0x8001);
|
||||
out->length = htobe32(len);
|
||||
out->ordinal = htobe32(EXT_CMD);
|
||||
out->subcmd = htobe16(subcmd);
|
||||
out->digest = digest;
|
||||
out->address = __cpu_to_be32(addr);
|
||||
out->address = htobe32(addr);
|
||||
memcpy(out->data, data, size);
|
||||
#ifdef DEBUG
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user