[SeaBIOS] AHCI: Set transfer mode according to the capabilities of connected drive

Zeh, Werner werner.zeh at siemens.com
Mon Feb 15 13:00:48 CET 2016

Hi Kevin.

We had some issues with some connected AHCI devices in SeaBIOS. We have connected some CF-Cards
by using a simple SATA<->IDE bridge to the mainboard and in some cases, the drive (which is the CF-card) was
not recognized correctly. After some deeper analysis we found that SeaBIOS does not set up the
transfer rate which is used to communicate to the drive. The supported transfer rate can be found in the data structure
which is delivered by IDENTIFY_DEVICE command.

So in our error cases the default transfer rate was too high and therefore data error has occurred.
I have attached a patch which will deal with this case on AHCI controllers. Maybe you can push this patch to mainline
or at least have a look at it.

Up to now I have verified the function of this patch with the latest master branch of SeaBIOS and a Broadwell-DE CPU.
I have used PIO4, default PIO, Multiword-DMA2 and several Ultra-DMA CF-cards to ensure that all three paths work properly.

BTW: I am not that familiar with code style in SeaBIOS. If I made some formal mistakes, feel free to correct them.

Thank you in advance
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://www.seabios.org/pipermail/seabios/attachments/20160215/ba56e672/attachment.html>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: ahci_transfermode.diff
Type: application/octet-stream
Size: 3518 bytes
Desc: ahci_transfermode.diff
URL: <http://www.seabios.org/pipermail/seabios/attachments/20160215/ba56e672/attachment.obj>

More information about the SeaBIOS mailing list