From: Andi Kleen <ak@muc.de>
To: torvalds@transmeta.com
Cc: linux-kernel@vger.kernel.org, davej@suse.de
Subject: [PATCH] Fix rocket port driver
Date: Thu, 31 Jan 2002 00:31:30 +0100 [thread overview]
Message-ID: <20020131003130.A1413@averell> (raw)
This patch fixes the rocketport serial driver to compile again
(after the kdev_t changes) and also adds support for a rocketport
card I managed to buy second hand with a non standard pci ID.
Patch for 2.5.3. Please apply.
-Andi
--- linux-2.5.3-work/drivers/char/rocket.c-o Fri Sep 21 19:55:22 2001
+++ linux-2.5.3-work/drivers/char/rocket.c Wed Jan 30 23:00:48 2002
@@ -227,7 +227,7 @@
if (!info)
return 1;
if (info->magic != RPORT_MAGIC) {
- printk(badmagic, MAJOR(device), MINOR(device), routine);
+ printk(badmagic, major(device), minor(device), routine);
return 1;
}
#endif
@@ -896,7 +896,7 @@
CHANNEL_t *cp;
unsigned long page;
- line = MINOR(tty->device) - tty->driver.minor_start;
+ line = minor(tty->device) - tty->driver.minor_start;
if ((line < 0) || (line >= MAX_RP_PORTS))
return -ENODEV;
if (!tmp_buf) {
@@ -1467,7 +1467,7 @@
{
if (tty)
sprintf(buf, "%s%d", tty->driver.name,
- MINOR(tty->device) - tty->driver.minor_start +
+ minor(tty->device) - tty->driver.minor_start +
tty->driver.name_base);
else
strcpy(buf, "NULL tty");
@@ -1964,6 +1964,10 @@
str = "8-port Modem";
max_num_aiops = 1;
break;
+ case 0x8:
+ str = "mysterious 8 port";
+ max_num_aiops = 1;
+ break;
default:
str = "(unknown/unsupported)";
max_num_aiops = 0;
@@ -2042,6 +2046,10 @@
PCI_DEVICE_ID_RP8M, i, &bus, &device_fn))
if(register_PCI(count+boards_found, bus, device_fn))
count++;
+ if(!pcibios_find_device(PCI_VENDOR_ID_RP,
+ 0x8, i, &bus, &device_fn))
+ if(register_PCI(count+boards_found, bus, device_fn))
+ count++;
}
return(count);
}
next reply other threads:[~2002-01-30 23:32 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2002-01-30 23:31 Andi Kleen [this message]
2002-01-31 1:16 ` [PATCH] Fix rocket port driver Jeff Garzik
2002-01-31 1:24 ` Andi Kleen
2002-01-31 1:25 ` Jeff Garzik
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=20020131003130.A1413@averell \
--to=ak@muc.de \
--cc=davej@suse.de \
--cc=linux-kernel@vger.kernel.org \
--cc=torvalds@transmeta.com \
/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;
as well as URLs for NNTP newsgroup(s).