]> git.ipfire.org Git - thirdparty/grub.git/commitdiff
merge mainline into pciclean
authorVladimir 'phcoder' Serbinenko <phcoder@gmail.com>
Wed, 20 Jan 2010 19:40:30 +0000 (20:40 +0100)
committerVladimir 'phcoder' Serbinenko <phcoder@gmail.com>
Wed, 20 Jan 2010 19:40:30 +0000 (20:40 +0100)
1  2 
bus/pci.c
commands/efi/fixvideo.c
commands/efi/loadbios.c
commands/lspci.c
disk/ata.c
loader/i386/efi/linux.c
loader/i386/efi/xnu.c
video/efi_uga.c

diff --cc bus/pci.c
Simple merge
Simple merge
Simple merge
index ab756616a13d309bd8ac9e4d2fa8866b12c57737,c2abd8736c21e78c7d90017949adf70f154bda29..a69bb35ad14f19b3bc03f7609ddc373c81365e63
@@@ -162,11 -163,11 +163,11 @@@ grub_lspci_iter (grub_pci_device_t dev
          addr = grub_pci_make_address (dev, reg);
          space = grub_pci_read (addr);
  
 -        reg++;
 -       
 +        reg += sizeof (grub_uint32_t);
-         
++
          if (space == 0)
            continue;
-         
+        
          switch (space & GRUB_PCI_ADDR_SPACE_MASK)
            {
            case GRUB_PCI_ADDR_SPACE_IO:
diff --cc disk/ata.c
index bc8383d4ee02443cc90c8bc1c482ecc715710a2e,833ccb976a740b426e40e70acf36e2159e985713..687ed9378c58346242cd7ec0b20c1a475e7e2af5
@@@ -400,19 -400,34 +400,34 @@@ grub_ata_pciinit (grub_pci_device_t dev
    int regb;
    int i;
    static int controller = 0;
+   int cs5536 = 0;
+   int nports = 2;
  
    /* Read class.  */
 -  addr = grub_pci_make_address (dev, 2);
 +  addr = grub_pci_make_address (dev, GRUB_PCI_REG_CLASS);
    class = grub_pci_read (addr);
  
+   /* AMD CS5536 Southbridge.  */
+   if (pciid == 0x208f1022)
+     {
+       cs5536 = 1;
+       nports = 1;
+     }
    /* Check if this class ID matches that of a PCI IDE Controller.  */
-   if (class >> 16 != 0x0101)
+   if (!cs5536 && (class >> 16 != 0x0101))
      return 0;
  
-   for (i = 0; i < 2; i++)
+   for (i = 0; i < nports; i++)
      {
        /* Set to 0 when the channel operated in compatibility mode.  */
-       int compat = (class >> (8 + 2 * i)) & 1;
+       int compat;
+       /* We don't support non-compatibility mode for CS5536.  */
+       if (cs5536)
+       compat = 0;
+       else
+       compat = (class >> (8 + 2 * i)) & 1;
  
        rega = 0;
        regb = 0;
Simple merge
Simple merge
diff --cc video/efi_uga.c
Simple merge