Skip to contentSkip to conversation

serial: 8250: Fix initialisation of Quatech cards with the AMCC PCI chip

PATCH New Jonathan Woithe 2 participants 2 messages Oct 31, 2013 – Dec 9, 2013 TTY layer and serial drivers

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 serial: 8250: Fix initialisation of Quatech cards with the AMCC PCI chip

Fix the initialisation of older Quatech serial cards which are fitted with the AMCC PCI Matchmaker interface chip.

---

drivers/tty/serial/8250/8250_pci.c +2 -2
index c810da7..710f6d7 100644
@@ -1260,10 +1260,10 @@ static int pci_quatech_init(struct pci_dev *dev)
 		unsigned long base = pci_resource_start(dev, 0);
 		if (base) {
 			u32 tmp;
-			outl(inl(base + 0x38), base + 0x38);
+			outl(inl(base + 0x38) | 0x00002000, base + 0x38);
 			tmp = inl(base + 0x3c);
 			outl(tmp | 0x01000000, base + 0x3c);
-			outl(tmp, base + 0x3c);
+			outl(tmp &= ~0x01000000, base + 0x3c);
 		}
 	}
 	return 0;
#1 lore raw

PATCH RESEND 1/1 serial: 8250: Fix initialisation of Quatech cards with the AMCC PCI chip

Fix the initialisation of older Quatech serial cards which are fitted with the AMCC PCI Matchmaker interface chip.

---

drivers/tty/serial/8250/8250_pci.c +2 -2
index c810da7..710f6d7 100644
@@ -1260,10 +1260,10 @@ static int pci_quatech_init(struct pci_dev *dev)
 		unsigned long base = pci_resource_start(dev, 0);
 		if (base) {
 			u32 tmp;
-			outl(inl(base + 0x38), base + 0x38);
+			outl(inl(base + 0x38) | 0x00002000, base + 0x38);
 			tmp = inl(base + 0x3c);
 			outl(tmp | 0x01000000, base + 0x3c);
-			outl(tmp, base + 0x3c);
+			outl(tmp &= ~0x01000000, base + 0x3c);
 		}
 	}
 	return 0;