Fix booting without CD in drive.

git-svn-id: svn://coreboot.org/openbios/openbios-devel@79 f158a5a8-5612-0410-a976-696ce0be7e32
This commit is contained in:
Stefan Reinauer
2006-08-20 15:59:02 +00:00
parent 8be21e0d3a
commit 6b2c88cf60

View File

@@ -118,7 +118,12 @@ do_command(esp_private_t *esp, sd_private_t *sd, int cmdlen, int replylen)
// Check status
status = esp->ll->regs[ESP_STATUS];
if ((status & ESP_STAT_TCNT) != ESP_STAT_TCNT)
DPRINTF("do_command: id %d, cmd[0] 0x%x, status 0x%x\n", sd->id, esp->buffer[0], status);
// Target didn't want all command data or went to status phase
// instead of data phase?
if ((status & ESP_STAT_TCNT) != ESP_STAT_TCNT
|| (status & ESP_STAT_PMASK) == ESP_STATP)
return status;
// Get reply
@@ -136,6 +141,8 @@ do_command(esp_private_t *esp, sd_private_t *sd, int cmdlen, int replylen)
// Check status
status = esp->ll->regs[ESP_STATUS];
DPRINTF("do_command_reply: status 0x%x\n", status);
if ((status & ESP_STAT_TCNT) != ESP_STAT_TCNT)
return status;
else