Merge branch 'fix/hda' into for-linus
[firefly-linux-kernel-4.4.55.git] / arch / mips / pci / ops-mace.c
index e95881897ec904b0489233f3fb1fd771a7da20e3..1cfb5588699fb6764f0793db6f47512167943430 100644 (file)
@@ -61,6 +61,13 @@ mace_pci_read_config(struct pci_bus *bus, unsigned int devfn,
        /* ack possible master abort */
        mace->pci.error &= ~MACEPCI_ERROR_MASTER_ABORT;
        mace->pci.control = control;
+       /*
+        * someone forgot to set the ultra bit for the onboard
+        * scsi chips; we fake it here
+        */
+       if (bus->number == 0 && reg == 0x40 && size == 4 &&
+           (devfn == (1 << 3) || devfn == (2 << 3)))
+               *val |= 0x1000;
 
        DPRINTK("read%d: reg=%08x,val=%02x\n", size * 8, reg, *val);