diff options
| -rw-r--r-- | serial-8250_pci-add-support-for-fintek-4-8-and-12-port-cards.patch | 46 |
1 files changed, 37 insertions, 9 deletions
diff --git a/serial-8250_pci-add-support-for-fintek-4-8-and-12-port-cards.patch b/serial-8250_pci-add-support-for-fintek-4-8-and-12-port-cards.patch index a03b82c975346e..b0c2169d2cf458 100644 --- a/serial-8250_pci-add-support-for-fintek-4-8-and-12-port-cards.patch +++ b/serial-8250_pci-add-support-for-fintek-4-8-and-12-port-cards.patch @@ -16,8 +16,8 @@ Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> --- - drivers/tty/serial/8250/8250_pci.c | 134 ++++++++++++++++++++++++++++++++++++- - 1 file changed, 133 insertions(+), 1 deletion(-) + drivers/tty/serial/8250/8250_pci.c | 162 ++++++++++++++++++++++++++++++++++++- + 1 file changed, 161 insertions(+), 1 deletion(-) --- a/drivers/tty/serial/8250/8250_pci.c +++ b/drivers/tty/serial/8250/8250_pci.c @@ -30,7 +30,7 @@ Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> /* * init function returns: -@@ -1344,6 +1344,94 @@ pci_brcm_trumanage_setup(struct serial_p +@@ -1344,6 +1344,122 @@ pci_brcm_trumanage_setup(struct serial_p return ret; } @@ -38,31 +38,59 @@ Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> + const struct pciserial_board *board, + struct uart_8250_port *port, int idx) +{ ++ int iobase; + int ret; + ++ /* FIXME: read these from the PCI config space */ + switch (idx) { + case 0: ++ iobase = 0xe000; ++ break; + case 1: ++ iobase = 0xe008; ++ break; + case 2: ++ iobase = 0xe010; ++ break; + case 3: ++ iobase = 0xe018; + break; + case 4: ++ iobase = 0xe020; ++ break; + case 5: ++ iobase = 0xe028; ++ break; + case 6: ++ iobase = 0xe030; ++ break; + case 7: ++ iobase = 0xe038; + break; + case 8: ++ iobase = 0xe040; ++ break; + case 9: ++ iobase = 0xe048; ++ break; + case 10: ++ iobase = 0xe050; ++ break; + case 11: ++ iobase = 0xe058; + break; + default: + /* Unknown number of ports, get out of here */ + return -EINVAL; + } ++ port->port.iotype = UPIO_PORT; ++ port->port.iobase = iobase; ++ port->port.mapbase = 0; ++ port->port.membase = NULL; ++ port->port.regshift = 0; + -+ ret = pci_default_setup(priv, board, port, idx); -+ return ret; ++// ret = pci_default_setup(priv, board, port, idx); ++ return 0; +#if 0 +static int +setup_port(struct serial_private *priv, struct uart_8250_port *port, @@ -125,7 +153,7 @@ Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> static int skip_tx_en_setup(struct serial_private *priv, const struct pciserial_board *board, struct uart_8250_port *port, int idx) -@@ -2254,6 +2342,27 @@ static struct pci_serial_quirk pci_seria +@@ -2254,6 +2370,27 @@ static struct pci_serial_quirk pci_seria .subdevice = PCI_ANY_ID, .setup = pci_brcm_trumanage_setup, }, @@ -153,7 +181,7 @@ Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> /* * Default "match everything" terminator entry -@@ -2451,6 +2560,9 @@ enum pci_board_num_t { +@@ -2451,6 +2588,9 @@ enum pci_board_num_t { pbn_omegapci, pbn_NETMOS9900_2s_115200, pbn_brcm_trumanage, @@ -163,7 +191,7 @@ Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> }; /* -@@ -3201,6 +3313,21 @@ static struct pciserial_board pci_boards +@@ -3201,6 +3341,21 @@ static struct pciserial_board pci_boards .reg_shift = 2, .base_baud = 115200, }, @@ -185,7 +213,7 @@ Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> }; static const struct pci_device_id blacklist[] = { -@@ -4911,6 +5038,11 @@ static struct pci_device_id serial_pci_t +@@ -4911,6 +5066,11 @@ static struct pci_device_id serial_pci_t 0, 0, pbn_exar_XR17V358 }, |
