566a03a623
Check the error bits in the interrupt status register. According to the AHCI 1.2 spec, "Interrupt sources that are disabled (‘0’) are still reflected in the status registers.", so this should work even though grub uses polling This fixes the following problem on a Fujitsu E744 laptop: Sometimes there is a very long delay (up to several minutes) when booting from hard disk. It seems accessing the DVD drive (which has no disk inserted) sometimes fails with some errors, which leads to each access being stalled until the 20s timeout triggers. This seems to happen when grub is trying to read filesystem/partition data. The problem is that the command_issue bit that is checked in the loop is only reset if the "HBA receives a FIS which clears the BSY, DRQ, and ERR bits for the command", but the ERR bit is never cleared. Therefore command_issue is never reset and grub waits for the timeout. The relevant bit in our case is the Task File Error Status (TFES), which is equivalent to the ERR bit 0 in tfd. But this patch also checks the other error bits except for the "Interface non-fatal error status" bit. Signed-off-by: Stefan Fritsch <fritsch@genua.de> Reviewed-by: Daniel Kiper <daniel.kiper@oracle.com> |
||
---|---|---|
.. | ||
boot | ||
bus | ||
commands | ||
disk | ||
efiemu | ||
font | ||
fs | ||
gdb | ||
gettext | ||
gfxmenu | ||
gnulib | ||
hello | ||
hook | ||
io | ||
kern | ||
lib | ||
loader | ||
mmap | ||
net | ||
normal | ||
osdep | ||
partmap | ||
parttool | ||
script | ||
term | ||
tests | ||
video | ||
gdb_grub.in | ||
genemuinit.sh | ||
genemuinitheader.sh | ||
genmod.sh.in | ||
genmoddep.awk | ||
gensyminfo.sh.in | ||
gensymlist.sh | ||
gentrigtables.c | ||
gmodule.pl.in | ||
gnulib-fix-gcc7-fallthrough.diff | ||
gnulib-fix-null-deref.diff | ||
gnulib-fix-width.diff | ||
gnulib-no-abort.diff | ||
gnulib-no-gets.diff | ||
Makefile.am | ||
Makefile.core.def | ||
modinfo.sh.in |