PATCH: Fix up tty patch problem with pc300 and clean up braces
From: Alan Cox (alan_at_redhat.com)
Date: 09/30/04
- Previous message: Alan Cox: "PATCH: minor IDE clean up I noticed"
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
Date: Thu, 30 Sep 2004 13:58:00 -0400 To: linux-kernel@vger.kernel.org, torvalds@osdl.org, akpm@osdl.org
diff -u --new-file --recursive --exclude-from /usr/src/exclude linux.vanilla-2.6.9rc3/drivers/net/wan/pc300_tty.c linux-2.6.9rc3/drivers/net/wan/pc300_tty.c
--- linux.vanilla-2.6.9rc3/drivers/net/wan/pc300_tty.c 2004-09-30 16:13:09.075305760 +0100
+++ linux-2.6.9rc3/drivers/net/wan/pc300_tty.c 2004-09-30 17:02:18.400940112 +0100
@@ -192,13 +192,14 @@
*/
void cpc_tty_init(pc300dev_t *pc300dev)
{
- int port, aux;
+ unsigned long port;
+ int aux;
st_cpc_tty_area * cpc_tty;
/* hdlcX - X=interface number */
port = pc300dev->dev->name[4] - '0';
if (port >= CPC_TTY_NPORTS) {
- printk("%s-tty: invalid interface selected (0-%i): %i",
+ printk("%s-tty: invalid interface selected (0-%i): %li",
pc300dev->dev->name,
CPC_TTY_NPORTS-1,port);
return;
@@ -682,7 +683,8 @@
*/
static void cpc_tty_rx_work(void * data)
{
- int port, i, j;
+ unsigned long port;
+ int i, j;
st_cpc_tty_area *cpc_tty;
volatile st_cpc_rx_buf * buf;
char flags=0,flg_rx=1;
@@ -693,18 +695,15 @@
for (i=0; (i < 4) && flg_rx ; i++) {
flg_rx = 0;
- port = (int) data;
+ port = (unsigned long) data;
for (j=0; j < CPC_TTY_NPORTS; j++) {
cpc_tty = &cpc_tty_area[port];
if ((buf=cpc_tty->buf_rx.first) != 0) {
-
- if(cpc_tty->tty)
- {
- ld = tty_ldisc_ref(cpc_tty);
- if(ld)
- {
- if (ld->receive_buf)) {
+ if(cpc_tty->tty) {
+ ld = tty_ldisc_ref(cpc_tty->tty);
+ if(ld) {
+ if (ld->receive_buf) {
CPC_TTY_DBG("%s: call line disc. receive_buf\n",cpc_tty->name);
ld->receive_buf(cpc_tty->tty, (char *)(buf->data), &flags, buf->size);
}
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
- Previous message: Alan Cox: "PATCH: minor IDE clean up I noticed"
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
Relevant Pages
- Re: XFS breakage in 2.6.18-rc1
... system disk too who had to take the hit. ... send the line "unsubscribe linux-kernel"
in ... More majordomo info at http://vger.kernel.org/majordomo-info.html ... Please
read the FAQ at http://www.tux.org/lkml/ ... (Linux-Kernel) - Re: How to run an a.out file in a kernel module
... called in a kernel module using call_usermodehelper ... Please read the FAQ
at http://www.tux.org/lkml/ ... More majordomo info at http://vger.kernel.org/majordomo-info.html
... (Linux-Kernel) - Re: XFS Bug null pointer dereference in xfs_free_ag_extent
... I also filed bug 6877 at kernel.org ... send the line "unsubscribe linux-kernel"
in ... More majordomo info at http://vger.kernel.org/majordomo-info.html ... Please
read the FAQ at http://www.tux.org/lkml/ ... (Linux-Kernel) - Re: [patch] remove unused acct variables from task_struct
... struct mempolicy *mempolicy; ... More majordomo info at http://vger.kernel.org/majordomo-info.html
... Please read the FAQ at http://www.tux.org/lkml/ ... send the line "unsubscribe
linux-kernel" in ... (Linux-Kernel) - Re: DIPC alpha2 for i386, Alpha, SPARC, and M68k
... there seems to be a delay on cs.uwindsor.ca between the time you upload something and
the time it actually shows up on the page. ... More majordomo info at http://vger.kernel.org/majordomo-info.html
... Please read the FAQ at http://www.tux.org/lkml/ ... To unsubscribe from this
list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/
... (Linux-Kernel)