From: Andrey Panin <pazke@orbita1.ru>
To: Ed Vance <EdV@macrolink.com>
Cc: linux-kernel@vger.kernel.org
Subject: Re: Oxford Semiconductor's OXCB950 UART not recognized by serial. c
Date: Thu, 21 Feb 2002 12:56:51 +0300 [thread overview]
Message-ID: <20020221095651.GB275@pazke.ipt> (raw)
In-Reply-To: <11E89240C407D311958800A0C9ACF7D13A76A8@EXCHANGE>
In-Reply-To: <11E89240C407D311958800A0C9ACF7D13A76A8@EXCHANGE>
[-- Attachment #1.1: Type: text/plain, Size: 1834 bytes --]
On Срд, Фев 20, 2002 at 04:05:13 -0800, Ed Vance wrote:
> fabrizio.gennari@philips.com wrote:
> >
> > We have 32-bit CardBus cards with OXCB950 CardBus (PCI ID 1415:950b) UART
> > chips on them (OXCB950 is the CardBus version of 16C950) . The module
> > serial_cb in the pcmcia-cs package recognizes them correctly. But, when
> > not using serial_cb, the function serial_pci_guess_board in serial.c
> > doesn't (kernel 2.4.17 tested). The problem is that the card advertises 3
> > i/o memory regions and 2 ports. If one replaces the line
> >
> > if (num_iomem <= 1 && num_port == 1) {
> >
> > with
> >
> > if (num_port >= 1) {
> >
> > in the function serial_pci_guess_board(), the card is detected and works
> > perfectly. Only, when inserting it, the kernel displays the message:
> >
> > Redundant entry in serial pci_table. Please send the output of
> > lspci -vv, this message (1415,950b,1415,0001)
> > and the manufacturer and name of serial board or modem board
> > to serial-pci-info@lists.sourceforge.net.
>
> The "Redundant entry" message comes out of serial.c when a card is found in
> the PCI ID board list, but which function serial_pci_guess_board() also
> detects as a generic single UART card (and overwrites the card's
> board->flags field in the pci_boards[] array).
>
> Does anybody think this is a feature? Did I misunderstand?
>
> I suspect that the thought was to detect and eventually remove pci_boards[]
> entries for generic single-port cards that could also be detected by the
> serial_pci_guess_board() function. Can anybody confirm or deny?
You are right.
Does the attached patch remove this message ?
Best regards.
--
Andrey Panin | Embedded systems software engineer
pazke@orbita1.ru | PGP key: wwwkeys.eu.pgp.net
[-- Attachment #1.2: patch-serial-rentry --]
[-- Type: text/plain, Size: 1017 bytes --]
diff -urN -X /usr/dontdiff /linux.vanilla/drivers/char/serial.c /linux/drivers/char/serial.c
--- /linux.vanilla/drivers/char/serial.c Sat Feb 9 19:24:23 2002
+++ /linux/drivers/char/serial.c Sat Feb 9 20:02:14 2002
@@ -4451,6 +4451,12 @@
return 1;
}
+static inline int serial_is_redundant(const struct pci_board *board)
+{
+ return !((board->num_ports > 1) || (board->base_baud != 115200) ||
+ (board->init_fn) || (board->first_uart_offset));
+}
+
static int __devinit serial_init_one(struct pci_dev *dev,
const struct pci_device_id *ent)
{
@@ -4465,7 +4471,8 @@
if (ent->driver_data == pbn_default &&
serial_pci_guess_board(dev, board))
return -ENODEV;
- else if (serial_pci_guess_board(dev, &tmp) == 0) {
+ else if ((serial_pci_guess_board(dev, &tmp) == 0) &&
+ (serial_is_redundant(board))) {
printk(KERN_INFO "Redundant entry in serial pci_table. "
"Please send the output of\n"
"lspci -vv, this message (%04x,%04x,%04x,%04x)\n"
[-- Attachment #2: Type: application/pgp-signature, Size: 232 bytes --]
next prev parent reply other threads:[~2002-02-21 9:53 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2002-02-21 0:05 Ed Vance
2002-02-21 9:56 ` Andrey Panin [this message]
2002-02-28 18:07 fabrizio.gennari
2002-03-06 0:56 Ed Vance
2002-03-06 9:14 fabrizio.gennari
2002-03-06 19:53 Ed Vance
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20020221095651.GB275@pazke.ipt \
--to=pazke@orbita1.ru \
--cc=EdV@macrolink.com \
--cc=linux-kernel@vger.kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
all inboxes | Powered by JetHome®