mirror of
https://github.com/Telecominfraproject/OpenCellular.git
synced 2026-01-12 19:04:59 +00:00
pd: fix transmit bug, add back in retry mechanism
Fix bug in pd transmission. The retry mechanism was not working right and was causing us to not do any retries. BUG=none BRANCH=none TEST=Test with a zinger unplugged from the wall. Samus sends source cap and doesn't get a response. Verify on console printout that we retried 3 times. Change-Id: Id273bf054655c2d24a791f4eaf4cb8d87253abe2 Signed-off-by: Alec Berg <alecaberg@chromium.org> Reviewed-on: https://chromium-review.googlesource.com/210559 Reviewed-by: Vincent Palatin <vpalatin@chromium.org>
This commit is contained in:
committed by
chrome-internal-fetch
parent
d5aaf91a7a
commit
3c05559334
@@ -328,8 +328,7 @@ static int send_validate_message(int port, uint16_t header,
|
||||
|
||||
/* retry 3 times if we are not getting a valid answer */
|
||||
for (r = 0; r <= PD_RETRY_COUNT; r++) {
|
||||
int bit_len;
|
||||
uint16_t head;
|
||||
int bit_len, head;
|
||||
/* write the encoded packet in the transmission buffer */
|
||||
bit_len = prepare_message(port, header, cnt, data);
|
||||
/* Transmit the packet */
|
||||
|
||||
Reference in New Issue
Block a user