From d6f6341a6475eb7f9c2b948a7d0fd56fd16ad675 Mon Sep 17 00:00:00 2001 From: Jiri Slaby Date: Wed, 30 Apr 2008 00:53:57 -0700 Subject: Char: rio, fix cirrus defines Rename defines to be in RIO* namespace to not to collide with other defines in tree. This broke (as akpm correctly pointed out) some allmodconfig builds, e.g. on ppc: In file included from drivers/char/rio/rio_linux.c:81: drivers/char/rio/cirrus.h:202:1: warning: "COMPLETE" redefined In file included from include/net/netns/ipv4.h:8, from include/net/net_namespace.h:13, from include/linux/seq_file.h:7, from include/asm/machdep.h:12, from include/asm/pci.h:17, from include/linux/pci.h:951, from drivers/char/rio/rio_linux.c:50: include/net/inet_frag.h:28:1: warning: this is the location of the previous definition Signed-off-by: Jiri Slaby Signed-off-by: Andrew Morton Signed-off-by: Linus Torvalds --- drivers/char/rio/riotty.c | 25 +++++++++++++------------ 1 file changed, 13 insertions(+), 12 deletions(-) (limited to 'drivers/char/rio/riotty.c') diff --git a/drivers/char/rio/riotty.c b/drivers/char/rio/riotty.c index 1cb8580a161d..c99354843be1 100644 --- a/drivers/char/rio/riotty.c +++ b/drivers/char/rio/riotty.c @@ -211,7 +211,7 @@ int riotopen(struct tty_struct *tty, struct file *filp) rio_dprintk(RIO_DEBUG_TTY, "Waiting for RIO_CLOSING to go away\n"); if (repeat_this-- <= 0) { rio_dprintk(RIO_DEBUG_TTY, "Waiting for not idle closed broken by signal\n"); - RIOPreemptiveCmd(p, PortP, FCLOSE); + RIOPreemptiveCmd(p, PortP, RIOC_FCLOSE); retval = -EINTR; goto bombout; } @@ -264,7 +264,7 @@ int riotopen(struct tty_struct *tty, struct file *filp) here. If I read the docs correctly the "open" command piggybacks the parameters immediately. -- REW */ - RIOParam(PortP, OPEN, 1, OK_TO_SLEEP); /* Open the port */ + RIOParam(PortP, RIOC_OPEN, 1, OK_TO_SLEEP); /* Open the port */ rio_spin_lock_irqsave(&PortP->portSem, flags); /* @@ -275,7 +275,7 @@ int riotopen(struct tty_struct *tty, struct file *filp) rio_spin_unlock_irqrestore(&PortP->portSem, flags); if (RIODelay(PortP, HUNDRED_MS) == RIO_FAIL) { rio_dprintk(RIO_DEBUG_TTY, "Waiting for open to finish broken by signal\n"); - RIOPreemptiveCmd(p, PortP, FCLOSE); + RIOPreemptiveCmd(p, PortP, RIOC_FCLOSE); func_exit(); return -EINTR; } @@ -297,7 +297,8 @@ int riotopen(struct tty_struct *tty, struct file *filp) ** insert test for carrier here. -- ??? ** I already see that test here. What's the deal? -- REW */ - if ((PortP->gs.tty->termios->c_cflag & CLOCAL) || (PortP->ModemState & MSVR1_CD)) { + if ((PortP->gs.tty->termios->c_cflag & CLOCAL) || + (PortP->ModemState & RIOC_MSVR1_CD)) { rio_dprintk(RIO_DEBUG_TTY, "open(%d) Modem carr on\n", SysPort); /* tp->tm.c_state |= CARR_ON; @@ -325,7 +326,7 @@ int riotopen(struct tty_struct *tty, struct file *filp) ** I think it's OK. -- REW */ rio_dprintk(RIO_DEBUG_TTY, "open(%d) sleeping for carr broken by signal\n", SysPort); - RIOPreemptiveCmd(p, PortP, FCLOSE); + RIOPreemptiveCmd(p, PortP, RIOC_FCLOSE); /* tp->tm.c_state &= ~WOPEN; */ @@ -416,7 +417,7 @@ int riotclose(void *ptr) */ PortP->State &= ~RIO_MOPEN; PortP->State &= ~RIO_CARR_ON; - PortP->ModemState &= ~MSVR1_CD; + PortP->ModemState &= ~RIOC_MSVR1_CD; /* ** If the device was open as both a Modem and a tty line ** then we need to wimp out here, as the port has not really @@ -453,7 +454,7 @@ int riotclose(void *ptr) if (repeat_this-- <= 0) { rv = -EINTR; rio_dprintk(RIO_DEBUG_TTY, "Waiting for not idle closed broken by signal\n"); - RIOPreemptiveCmd(p, PortP, FCLOSE); + RIOPreemptiveCmd(p, PortP, RIOC_FCLOSE); goto close_end; } rio_dprintk(RIO_DEBUG_TTY, "Calling timeout to flush in closing\n"); @@ -492,8 +493,8 @@ int riotclose(void *ptr) /* Can't call RIOShortCommand with the port locked. */ rio_spin_unlock_irqrestore(&PortP->portSem, flags); - if (RIOShortCommand(p, PortP, CLOSE, 1, 0) == RIO_FAIL) { - RIOPreemptiveCmd(p, PortP, FCLOSE); + if (RIOShortCommand(p, PortP, RIOC_CLOSE, 1, 0) == RIO_FAIL) { + RIOPreemptiveCmd(p, PortP, RIOC_FCLOSE); rio_spin_lock_irqsave(&PortP->portSem, flags); goto close_end; } @@ -503,7 +504,7 @@ int riotclose(void *ptr) try--; if (time_after(jiffies, end_time)) { rio_dprintk(RIO_DEBUG_TTY, "Run out of tries - force the bugger shut!\n"); - RIOPreemptiveCmd(p, PortP, FCLOSE); + RIOPreemptiveCmd(p, PortP, RIOC_FCLOSE); break; } rio_dprintk(RIO_DEBUG_TTY, "Close: PortState:ISOPEN is %d\n", PortP->PortState & PORT_ISOPEN); @@ -515,14 +516,14 @@ int riotclose(void *ptr) } if (RIODelay(PortP, HUNDRED_MS) == RIO_FAIL) { rio_dprintk(RIO_DEBUG_TTY, "RTA EINTR in delay \n"); - RIOPreemptiveCmd(p, PortP, FCLOSE); + RIOPreemptiveCmd(p, PortP, RIOC_FCLOSE); break; } } rio_spin_lock_irqsave(&PortP->portSem, flags); rio_dprintk(RIO_DEBUG_TTY, "Close: try was %d on completion\n", try); - /* RIOPreemptiveCmd(p, PortP, FCLOSE); */ + /* RIOPreemptiveCmd(p, PortP, RIOC_FCLOSE); */ /* ** 15.10.1998 ARG - ESIL 0761 part fix -- cgit v1.2.3