Merge git://git.kernel.org/pub/scm/linux/kernel/git/mchehab/v4l-dvb
[pandora-kernel.git] / drivers / char / rio / riointr.c
index 4734e26..71f8760 100644 (file)
 **
 ** -----------------------------------------------------------------------------
 */
-#ifdef SCCS_LABELS
-static char *_riointr_c_sccs_ = "@(#)riointr.c 1.2";
-#endif
-
 
 #include <linux/module.h>
 #include <linux/slab.h>
@@ -106,7 +102,7 @@ void RIOTxEnable(char *en)
 
        PortP = (struct Port *) en;
        p = (struct rio_info *) PortP->p;
-       tty = PortP->gs.tty;
+       tty = PortP->gs.port.tty;
 
 
        rio_dprintk(RIO_DEBUG_INTR, "tx port %d: %d chars queued.\n", PortP->PortNum, PortP->gs.xmit_cnt);
@@ -162,7 +158,7 @@ void RIOTxEnable(char *en)
        rio_spin_unlock_irqrestore(&PortP->portSem, flags);
 
        if (PortP->gs.xmit_cnt <= (PortP->gs.wakeup_chars + 2 * PKT_MAX_DATA_LEN))
-               tty_wakeup(PortP->gs.tty);
+               tty_wakeup(PortP->gs.port.tty);
 
 }
 
@@ -245,7 +241,7 @@ void RIOServiceHost(struct rio_info *p, struct Host *HostP)
                         ** find corresponding tty structure. The process of mapping
                         ** the ports puts these here.
                         */
-                       ttyP = PortP->gs.tty;
+                       ttyP = PortP->gs.port.tty;
 
                        /*
                         ** Lock the port before we begin working on it.
@@ -339,7 +335,7 @@ void RIOServiceHost(struct rio_info *p, struct Host *HostP)
                         ** find corresponding tty structure. The process of mapping
                         ** the ports puts these here.
                         */
-                       ttyP = PortP->gs.tty;
+                       ttyP = PortP->gs.port.tty;
                        /* If ttyP is NULL, the port is getting closed. Forget about it. */
                        if (!ttyP) {
                                rio_dprintk(RIO_DEBUG_INTR, "no tty, so skipping.\n");
@@ -401,9 +397,8 @@ void RIOServiceHost(struct rio_info *p, struct Host *HostP)
                                        PortP->InUse = NOT_INUSE;
 
                                        rio_spin_unlock(&PortP->portSem);
-                                       if (RIOParam(PortP, OPEN, ((PortP->Cor2Copy & (COR2_RTSFLOW | COR2_CTSFLOW)) == (COR2_RTSFLOW | COR2_CTSFLOW)) ? 1 : 0, DONT_SLEEP) == RIO_FAIL) {
+                                       if (RIOParam(PortP, RIOC_OPEN, ((PortP->Cor2Copy & (RIOC_COR2_RTSFLOW | RIOC_COR2_CTSFLOW)) == (RIOC_COR2_RTSFLOW | RIOC_COR2_CTSFLOW)) ? 1 : 0, DONT_SLEEP) == RIO_FAIL)
                                                continue;       /* with next port */
-                                       }
                                        rio_spin_lock(&PortP->portSem);
                                        PortP->MagicFlags &= ~MAGIC_REBOOT;
                                }
@@ -429,7 +424,7 @@ void RIOServiceHost(struct rio_info *p, struct Host *HostP)
                                         */
                                        PktCmdP = (struct PktCmd __iomem *) &PacketP->data[0];
 
-                                       writeb(WFLUSH, &PktCmdP->Command);
+                                       writeb(RIOC_WFLUSH, &PktCmdP->Command);
 
                                        p = PortP->HostPort % (u16) PORTS_PER_RTA;
 
@@ -547,7 +542,7 @@ static void RIOReceive(struct rio_info *p, struct Port *PortP)
 
        intCount++;
 
-       TtyP = PortP->gs.tty;
+       TtyP = PortP->gs.port.tty;
        if (!TtyP) {
                rio_dprintk(RIO_DEBUG_INTR, "RIOReceive: tty is null. \n");
                return;