Blame SOURCES/0051-grub-core-disk-ahci.c-Do-not-enable-I-O-decoding-and.patch

f731ee
From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001
f731ee
From: Vladimir Serbinenko <phcoder@gmail.com>
f731ee
Date: Wed, 29 Jan 2014 23:43:25 +0100
f731ee
Subject: [PATCH] * grub-core/disk/ahci.c: Do not enable I/O decoding and keep
f731ee
 enabling busmaster for the end.
f731ee
f731ee
---
f731ee
 grub-core/disk/ahci.c | 10 ++++++----
f731ee
 ChangeLog             |  5 +++++
f731ee
 2 files changed, 11 insertions(+), 4 deletions(-)
f731ee
f731ee
diff --git a/grub-core/disk/ahci.c b/grub-core/disk/ahci.c
f731ee
index 0b13fb8ebed..18c13270c65 100644
f731ee
--- a/grub-core/disk/ahci.c
f731ee
+++ b/grub-core/disk/ahci.c
f731ee
@@ -194,10 +194,8 @@ grub_ahci_pciinit (grub_pci_device_t dev,
f731ee
     return 0;
f731ee
 
f731ee
   addr = grub_pci_make_address (dev, GRUB_PCI_REG_COMMAND);
f731ee
-  grub_pci_write_word (addr, grub_pci_read_word (addr) | 
f731ee
-		    GRUB_PCI_COMMAND_IO_ENABLED
f731ee
-		    | GRUB_PCI_COMMAND_MEM_ENABLED
f731ee
-		    | GRUB_PCI_COMMAND_BUS_MASTER);
f731ee
+  grub_pci_write_word (addr, grub_pci_read_word (addr)
f731ee
+		    | GRUB_PCI_COMMAND_MEM_ENABLED);
f731ee
 
f731ee
   hba = grub_pci_device_map_range (dev, bar & GRUB_PCI_ADDR_MEM_MASK,
f731ee
 				   sizeof (hba));
f731ee
@@ -621,6 +619,10 @@ grub_ahci_pciinit (grub_pci_device_t dev,
f731ee
     if (adevs[i] && (adevs[i]->hba->ports[adevs[i]->port].sig >> 16) == 0xeb14)
f731ee
       adevs[i]->atapi = 1;
f731ee
 
f731ee
+  addr = grub_pci_make_address (dev, GRUB_PCI_REG_COMMAND);
f731ee
+  grub_pci_write_word (addr, grub_pci_read_word (addr)
f731ee
+		    | GRUB_PCI_COMMAND_BUS_MASTER);
f731ee
+
f731ee
   for (i = 0; i < nports; i++)
f731ee
     if (adevs[i])
f731ee
       {
f731ee
diff --git a/ChangeLog b/ChangeLog
f731ee
index 9837c7f8d38..51eba95f36f 100644
f731ee
--- a/ChangeLog
f731ee
+++ b/ChangeLog
f731ee
@@ -1,3 +1,8 @@
f731ee
+2014-01-29  Vladimir Serbinenko  <phcoder@gmail.com>
f731ee
+
f731ee
+	* grub-core/disk/ahci.c: Do not enable I/O decoding and keep
f731ee
+	enabling busmaster for the end.
f731ee
+
f731ee
 2014-01-29  Vladimir Serbinenko  <phcoder@gmail.com>
f731ee
 
f731ee
 	* util/grub-mkfont.c: Downgrade warnings about unhandled features