bios/boot: update comments.

This commit is contained in:
Florent Kermarrec 2020-03-25 09:21:28 +01:00
parent 1746b57a1b
commit 8f2e36927d
1 changed files with 3 additions and 5 deletions

View File

@ -122,7 +122,7 @@ int serialboot(void)
printf("Booting from serial...\n"); printf("Booting from serial...\n");
printf("Press Q or ESC to abort boot completely.\n"); printf("Press Q or ESC to abort boot completely.\n");
// send the "magic" request to host for a firmware download /* send the serialboot "magic" request to Host */
c = str; c = str;
while(*c) { while(*c) {
uart_write(*c); uart_write(*c);
@ -158,10 +158,8 @@ int serialboot(void)
actualcrc = ((int)frame.crc[0] << 8)|(int)frame.crc[1]; actualcrc = ((int)frame.crc[0] << 8)|(int)frame.crc[1];
goodcrc = crc16(&frame.cmd, frame.payload_length+1); goodcrc = crc16(&frame.cmd, frame.payload_length+1);
if(actualcrc != goodcrc) { if(actualcrc != goodcrc) {
// clear out the RX buffer /* Clear out the RX buffer */
while (uart_read_nonblock()) { while (uart_read_nonblock()) uart_read();
uart_read();
}
failed++; failed++;
if(failed == MAX_FAILED) { if(failed == MAX_FAILED) {
printf("Too many consecutive errors, aborting"); printf("Too many consecutive errors, aborting");