[SeaBIOS] [PATCH] ahci: Ignore max_ports.

Vladimir 'φ-coder/phcoder' Serbinenko phcoder at gmail.com
Tue May 19 20:51:36 CEST 2015


At least AHCI on Intel on some machines claim to support only 6 ports
while in fact higher port numbers are present and work.
This is needed to access CD-ROM on PackardBell MS2290.
Both GRUB and Linux have a similar workaround.

Signed-off-by: Vladimir Serbinenko <phcoder at gmail.com>
---
 src/hw/ahci.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/src/hw/ahci.c b/src/hw/ahci.c
index ff5d5f9..3193d81 100644
--- a/src/hw/ahci.c
+++ b/src/hw/ahci.c
@@ -601,7 +601,7 @@ ahci_controller_setup(struct pci_device *pci)
     dprintf(2, "AHCI: cap 0x%x, ports_impl 0x%x\n",
             ctrl->caps, ctrl->ports);

-    max = ctrl->caps & 0x1f;
+    max = 0x1f;
     for (pnr = 0; pnr <= max; pnr++) {
         if (!(ctrl->ports & (1 << pnr)))
             continue;
-- 
2.1.4

-------------- next part --------------
A non-text attachment was scrubbed...
Name: 0001-ahci-Ignore-max_ports.patch
Type: application/x-patch
Size: 991 bytes
Desc: not available
URL: <http://www.seabios.org/pipermail/seabios/attachments/20150519/3624cfbe/attachment-0001.bin>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 213 bytes
Desc: OpenPGP digital signature
URL: <http://www.seabios.org/pipermail/seabios/attachments/20150519/3624cfbe/attachment-0001.asc>


More information about the SeaBIOS mailing list