Commit d9e9b8c8 authored by Alexander Viro's avatar Alexander Viro Committed by Linus Torvalds

[PATCH] callout removal: cleanup

misc cleanup - switched to standard constant names for .subtype in the
drivers that had private equivalents, removed unused ->callout_termios
and friends from the last places where they were defined.
parent 3470b4cd
...@@ -157,7 +157,6 @@ struct dz_serial { ...@@ -157,7 +157,6 @@ struct dz_serial {
struct tq_struct tqueue; /* Queue for BH */ struct tq_struct tqueue; /* Queue for BH */
struct tq_struct tqueue_hangup; struct tq_struct tqueue_hangup;
struct termios normal_termios; struct termios normal_termios;
struct termios callout_termios;
wait_queue_head_t open_wait; wait_queue_head_t open_wait;
wait_queue_head_t close_wait; wait_queue_head_t close_wait;
......
...@@ -326,8 +326,6 @@ i2InitChannels ( i2eBordStrPtr pB, int nChannels, i2ChanStrPtr pCh) ...@@ -326,8 +326,6 @@ i2InitChannels ( i2eBordStrPtr pB, int nChannels, i2ChanStrPtr pCh)
pCh->speed = CBR_9600; pCh->speed = CBR_9600;
pCh->flags = 0; pCh->flags = 0;
pCh->session = 0;
pCh->pgrp = 0;
pCh->ClosingDelay = 5*HZ/10; pCh->ClosingDelay = 5*HZ/10;
pCh->ClosingWaitTime = 30*HZ; pCh->ClosingWaitTime = 30*HZ;
......
...@@ -159,8 +159,6 @@ static int stli_nrbrds = sizeof(stli_brdconf) / sizeof(stlconf_t); ...@@ -159,8 +159,6 @@ static int stli_nrbrds = sizeof(stli_brdconf) / sizeof(stlconf_t);
#define STL_CALLOUTMAJOR 25 #define STL_CALLOUTMAJOR 25
#endif #endif
#define STL_DRVTYPSERIAL 1
/*****************************************************************************/ /*****************************************************************************/
/* /*
...@@ -5303,7 +5301,7 @@ int __init stli_init(void) ...@@ -5303,7 +5301,7 @@ int __init stli_init(void)
stli_serial.minor_start = 0; stli_serial.minor_start = 0;
stli_serial.num = STL_MAXBRDS * STL_MAXPORTS; stli_serial.num = STL_MAXBRDS * STL_MAXPORTS;
stli_serial.type = TTY_DRIVER_TYPE_SERIAL; stli_serial.type = TTY_DRIVER_TYPE_SERIAL;
stli_serial.subtype = STL_DRVTYPSERIAL; stli_serial.subtype = SERIAL_TYPE_NORMAL;
stli_serial.init_termios = stli_deftermios; stli_serial.init_termios = stli_deftermios;
stli_serial.flags = TTY_DRIVER_REAL_RAW; stli_serial.flags = TTY_DRIVER_REAL_RAW;
stli_serial.refcount = &stli_refcount; stli_serial.refcount = &stli_refcount;
......
...@@ -111,10 +111,6 @@ know why. If you want to try anyway you'll have to increase the number ...@@ -111,10 +111,6 @@ know why. If you want to try anyway you'll have to increase the number
of boards in rio.h. You'll have to allocate more majors if you need of boards in rio.h. You'll have to allocate more majors if you need
more than 512 ports.... */ more than 512 ports.... */
/* Why the hell am I defining these here? */
#define RIO_TYPE_NORMAL 1
#ifndef RIO_NORMAL_MAJOR0 #ifndef RIO_NORMAL_MAJOR0
/* This allows overriding on the compiler commandline, or in a "major.h" /* This allows overriding on the compiler commandline, or in a "major.h"
include or something like that */ include or something like that */
...@@ -885,7 +881,7 @@ static int rio_init_drivers(void) ...@@ -885,7 +881,7 @@ static int rio_init_drivers(void)
rio_driver.major = RIO_NORMAL_MAJOR0; rio_driver.major = RIO_NORMAL_MAJOR0;
rio_driver.num = 256; rio_driver.num = 256;
rio_driver.type = TTY_DRIVER_TYPE_SERIAL; rio_driver.type = TTY_DRIVER_TYPE_SERIAL;
rio_driver.subtype = RIO_TYPE_NORMAL; rio_driver.subtype = SERIAL_TYPE_NORMAL;
rio_driver.init_termios = tty_std_termios; rio_driver.init_termios = tty_std_termios;
rio_driver.init_termios.c_cflag = rio_driver.init_termios.c_cflag =
B9600 | CS8 | CREAD | HUPCL | CLOCAL; B9600 | CS8 | CREAD | HUPCL | CLOCAL;
......
...@@ -83,8 +83,6 @@ ...@@ -83,8 +83,6 @@
static DECLARE_TASK_QUEUE(tq_riscom); static DECLARE_TASK_QUEUE(tq_riscom);
#define RISCOM_TYPE_NORMAL 1
static struct riscom_board * IRQ_to_board[16]; static struct riscom_board * IRQ_to_board[16];
static struct tty_driver riscom_driver; static struct tty_driver riscom_driver;
static int riscom_refcount; static int riscom_refcount;
...@@ -1715,7 +1713,7 @@ static inline int rc_init_drivers(void) ...@@ -1715,7 +1713,7 @@ static inline int rc_init_drivers(void)
riscom_driver.major = RISCOM8_NORMAL_MAJOR; riscom_driver.major = RISCOM8_NORMAL_MAJOR;
riscom_driver.num = RC_NBOARD * RC_NPORT; riscom_driver.num = RC_NBOARD * RC_NPORT;
riscom_driver.type = TTY_DRIVER_TYPE_SERIAL; riscom_driver.type = TTY_DRIVER_TYPE_SERIAL;
riscom_driver.subtype = RISCOM_TYPE_NORMAL; riscom_driver.subtype = SERIAL_TYPE_NORMAL;
riscom_driver.init_termios = tty_std_termios; riscom_driver.init_termios = tty_std_termios;
riscom_driver.init_termios.c_cflag = riscom_driver.init_termios.c_cflag =
B9600 | CS8 | CREAD | HUPCL | CLOCAL; B9600 | CS8 | CREAD | HUPCL | CLOCAL;
......
...@@ -699,7 +699,7 @@ static int a2232_init_drivers(void) ...@@ -699,7 +699,7 @@ static int a2232_init_drivers(void)
a2232_driver.major = A2232_NORMAL_MAJOR; a2232_driver.major = A2232_NORMAL_MAJOR;
a2232_driver.num = NUMLINES * nr_a2232; a2232_driver.num = NUMLINES * nr_a2232;
a2232_driver.type = TTY_DRIVER_TYPE_SERIAL; a2232_driver.type = TTY_DRIVER_TYPE_SERIAL;
a2232_driver.subtype = A2232_TTY_SUBTYPE_NORMAL; a2232_driver.subtype = SERIAL_TTY_NORMAL;
a2232_driver.init_termios = tty_std_termios; a2232_driver.init_termios = tty_std_termios;
a2232_driver.init_termios.c_cflag = a2232_driver.init_termios.c_cflag =
B9600 | CS8 | CREAD | HUPCL | CLOCAL; B9600 | CS8 | CREAD | HUPCL | CLOCAL;
......
...@@ -49,9 +49,6 @@ ...@@ -49,9 +49,6 @@
/* Some magic is always good - Who knows :) */ /* Some magic is always good - Who knows :) */
#define A2232_MAGIC 0x000a2232 #define A2232_MAGIC 0x000a2232
/* for the tty_struct subtype field */
#define A2232_TTY_SUBTYPE_NORMAL 1
/* A2232 port structure to keep track of the /* A2232 port structure to keep track of the
status of every single line used */ status of every single line used */
struct a2232_port{ struct a2232_port{
......
...@@ -176,8 +176,6 @@ DECLARE_TASK_QUEUE(tq_specialix); ...@@ -176,8 +176,6 @@ DECLARE_TASK_QUEUE(tq_specialix);
#undef RS_EVENT_WRITE_WAKEUP #undef RS_EVENT_WRITE_WAKEUP
#define RS_EVENT_WRITE_WAKEUP 0 #define RS_EVENT_WRITE_WAKEUP 0
#define SPECIALIX_TYPE_NORMAL 1
static struct tty_driver specialix_driver; static struct tty_driver specialix_driver;
static int specialix_refcount; static int specialix_refcount;
static struct tty_struct * specialix_table[SX_NBOARD * SX_NPORT]; static struct tty_struct * specialix_table[SX_NBOARD * SX_NPORT];
...@@ -2188,7 +2186,7 @@ static int sx_init_drivers(void) ...@@ -2188,7 +2186,7 @@ static int sx_init_drivers(void)
specialix_driver.major = SPECIALIX_NORMAL_MAJOR; specialix_driver.major = SPECIALIX_NORMAL_MAJOR;
specialix_driver.num = SX_NBOARD * SX_NPORT; specialix_driver.num = SX_NBOARD * SX_NPORT;
specialix_driver.type = TTY_DRIVER_TYPE_SERIAL; specialix_driver.type = TTY_DRIVER_TYPE_SERIAL;
specialix_driver.subtype = SPECIALIX_TYPE_NORMAL; specialix_driver.subtype = SERIAL_TYPE_NORMAL;
specialix_driver.init_termios = tty_std_termios; specialix_driver.init_termios = tty_std_termios;
specialix_driver.init_termios.c_cflag = specialix_driver.init_termios.c_cflag =
B9600 | CS8 | CREAD | HUPCL | CLOCAL; B9600 | CS8 | CREAD | HUPCL | CLOCAL;
......
...@@ -120,8 +120,6 @@ static int stl_nrbrds = sizeof(stl_brdconf) / sizeof(stlconf_t); ...@@ -120,8 +120,6 @@ static int stl_nrbrds = sizeof(stl_brdconf) / sizeof(stlconf_t);
#define STL_CALLOUTMAJOR 25 #define STL_CALLOUTMAJOR 25
#endif #endif
#define STL_DRVTYPSERIAL 1
/* /*
* Set the TX buffer size. Bigger is better, but we don't want * Set the TX buffer size. Bigger is better, but we don't want
* to chew too much memory with buffers! * to chew too much memory with buffers!
...@@ -3185,7 +3183,7 @@ int __init stl_init(void) ...@@ -3185,7 +3183,7 @@ int __init stl_init(void)
stl_serial.minor_start = 0; stl_serial.minor_start = 0;
stl_serial.num = STL_MAXBRDS * STL_MAXPORTS; stl_serial.num = STL_MAXBRDS * STL_MAXPORTS;
stl_serial.type = TTY_DRIVER_TYPE_SERIAL; stl_serial.type = TTY_DRIVER_TYPE_SERIAL;
stl_serial.subtype = STL_DRVTYPSERIAL; stl_serial.subtype = SERIAL_TYPE_NORMAL;
stl_serial.init_termios = stl_deftermios; stl_serial.init_termios = stl_deftermios;
stl_serial.flags = TTY_DRIVER_REAL_RAW; stl_serial.flags = TTY_DRIVER_REAL_RAW;
stl_serial.refcount = &stl_refcount; stl_serial.refcount = &stl_refcount;
......
...@@ -249,11 +249,6 @@ ...@@ -249,11 +249,6 @@
one machine. You'll have to increase the number of boards in sx.h one machine. You'll have to increase the number of boards in sx.h
if you want more than 4 boards. */ if you want more than 4 boards. */
/* Why the hell am I defining these here? */
#define SX_TYPE_NORMAL 1
#ifndef PCI_DEVICE_ID_SPECIALIX_SX_XIO_IO8 #ifndef PCI_DEVICE_ID_SPECIALIX_SX_XIO_IO8
#define PCI_DEVICE_ID_SPECIALIX_SX_XIO_IO8 0x2000 #define PCI_DEVICE_ID_SPECIALIX_SX_XIO_IO8 0x2000
#endif #endif
...@@ -2240,7 +2235,7 @@ static int sx_init_drivers(void) ...@@ -2240,7 +2235,7 @@ static int sx_init_drivers(void)
sx_driver.major = SX_NORMAL_MAJOR; sx_driver.major = SX_NORMAL_MAJOR;
sx_driver.num = sx_nports; sx_driver.num = sx_nports;
sx_driver.type = TTY_DRIVER_TYPE_SERIAL; sx_driver.type = TTY_DRIVER_TYPE_SERIAL;
sx_driver.subtype = SX_TYPE_NORMAL; sx_driver.subtype = SERIAL_TYPE_NORMAL;
sx_driver.init_termios = tty_std_termios; sx_driver.init_termios = tty_std_termios;
sx_driver.init_termios.c_cflag = sx_driver.init_termios.c_cflag =
B9600 | CS8 | CREAD | HUPCL | CLOCAL; B9600 | CS8 | CREAD | HUPCL | CLOCAL;
......
...@@ -334,14 +334,11 @@ struct z8530_channel ...@@ -334,14 +334,11 @@ struct z8530_channel
struct tty_struct *tty; /* Attached terminal */ struct tty_struct *tty; /* Attached terminal */
int line; /* Minor number */ int line; /* Minor number */
struct termios normal_termios; /* Terminal settings */ struct termios normal_termios; /* Terminal settings */
struct termios callout_termios;
wait_queue_head_t open_wait; /* Tasks waiting to open */ wait_queue_head_t open_wait; /* Tasks waiting to open */
wait_queue_head_t close_wait; /* and for close to end */ wait_queue_head_t close_wait; /* and for close to end */
unsigned long event; /* Pending events */ unsigned long event; /* Pending events */
int fdcount; /* # of fd on device */ int fdcount; /* # of fd on device */
int blocked_open; /* # of blocked opens */ int blocked_open; /* # of blocked opens */
long session; /* Session of opening process */
long pgrp; /* pgrp of opening process */
int x_char; /* XON/XOF char */ int x_char; /* XON/XOF char */
unsigned char *xmit_buf; /* Transmit pointer */ unsigned char *xmit_buf; /* Transmit pointer */
int xmit_head; /* Transmit ring */ int xmit_head; /* Transmit ring */
......
...@@ -48,7 +48,6 @@ ...@@ -48,7 +48,6 @@
#define CTC_ASYNC_SPLIT_TERMIOS 0x0008 /* Sep. termios for dialin/out */ #define CTC_ASYNC_SPLIT_TERMIOS 0x0008 /* Sep. termios for dialin/out */
#define CTC_TTY_XMIT_SIZE 1024 /* Default bufsize for write */ #define CTC_TTY_XMIT_SIZE 1024 /* Default bufsize for write */
#define CTC_SERIAL_XMIT_MAX 4000 /* Maximum bufsize for write */ #define CTC_SERIAL_XMIT_MAX 4000 /* Maximum bufsize for write */
#define CTC_SERIAL_TYPE_NORMAL 1
/* Private data (similar to async_struct in <linux/serial.h>) */ /* Private data (similar to async_struct in <linux/serial.h>) */
typedef struct { typedef struct {
...@@ -1176,7 +1175,7 @@ ctc_tty_init(void) ...@@ -1176,7 +1175,7 @@ ctc_tty_init(void)
device->minor_start = 0; device->minor_start = 0;
device->num = CTC_TTY_MAX_DEVICES; device->num = CTC_TTY_MAX_DEVICES;
device->type = TTY_DRIVER_TYPE_SERIAL; device->type = TTY_DRIVER_TYPE_SERIAL;
device->subtype = CTC_SERIAL_TYPE_NORMAL; device->subtype = SERIAL_TYPE_NORMAL;
device->init_termios = tty_std_termios; device->init_termios = tty_std_termios;
device->init_termios.c_cflag = B9600 | CS8 | CREAD | HUPCL | CLOCAL; device->init_termios.c_cflag = B9600 | CS8 | CREAD | HUPCL | CLOCAL;
device->flags = TTY_DRIVER_REAL_RAW; device->flags = TTY_DRIVER_REAL_RAW;
......
...@@ -85,8 +85,6 @@ int irqhit=0; ...@@ -85,8 +85,6 @@ int irqhit=0;
#define MIN(a,b) ((a) < (b) ? (a) : (b)) #define MIN(a,b) ((a) < (b) ? (a) : (b))
#endif #endif
#define AURORA_TYPE_NORMAL 1
static struct tty_driver aurora_driver; static struct tty_driver aurora_driver;
static struct Aurora_board aurora_board[AURORA_NBOARD] = { static struct Aurora_board aurora_board[AURORA_NBOARD] = {
{0,}, {0,},
...@@ -2293,7 +2291,7 @@ static int aurora_init_drivers(void) ...@@ -2293,7 +2291,7 @@ static int aurora_init_drivers(void)
aurora_driver.major = AURORA_MAJOR; aurora_driver.major = AURORA_MAJOR;
aurora_driver.num = AURORA_TNPORTS; aurora_driver.num = AURORA_TNPORTS;
aurora_driver.type = TTY_DRIVER_TYPE_SERIAL; aurora_driver.type = TTY_DRIVER_TYPE_SERIAL;
aurora_driver.subtype = AURORA_TYPE_NORMAL; aurora_driver.subtype = SERIAL_TYPE_NORMAL;
aurora_driver.init_termios = tty_std_termios; aurora_driver.init_termios = tty_std_termios;
aurora_driver.init_termios.c_cflag = aurora_driver.init_termios.c_cflag =
B9600 | CS8 | CREAD | HUPCL | CLOCAL; B9600 | CS8 | CREAD | HUPCL | CLOCAL;
......
...@@ -299,8 +299,6 @@ typedef struct modem_info { ...@@ -299,8 +299,6 @@ typedef struct modem_info {
int line; int line;
int count; /* # of fd on device */ int count; /* # of fd on device */
int blocked_open; /* # of blocked opens */ int blocked_open; /* # of blocked opens */
long session; /* Session of opening process */
long pgrp; /* pgrp of opening process */
int online; /* 1 = B-Channel is up, drop data */ int online; /* 1 = B-Channel is up, drop data */
/* 2 = B-Channel is up, deliver d.*/ /* 2 = B-Channel is up, deliver d.*/
int dialing; /* Dial in progress or ATA */ int dialing; /* Dial in progress or ATA */
......
...@@ -50,7 +50,6 @@ struct serial_state { ...@@ -50,7 +50,6 @@ struct serial_state {
unsigned short closing_wait; /* time to wait before closing */ unsigned short closing_wait; /* time to wait before closing */
struct async_icount icount; struct async_icount icount;
struct termios normal_termios; struct termios normal_termios;
struct termios callout_termios;
int io_type; int io_type;
struct async_struct *info; struct async_struct *info;
struct pci_dev *dev; struct pci_dev *dev;
...@@ -80,8 +79,6 @@ struct async_struct { ...@@ -80,8 +79,6 @@ struct async_struct {
unsigned long last_active; unsigned long last_active;
int line; int line;
int blocked_open; /* # of blocked opens */ int blocked_open; /* # of blocked opens */
long session; /* Session of opening process */
long pgrp; /* pgrp of opening process */
struct circ_buf xmit; struct circ_buf xmit;
spinlock_t xmit_lock; spinlock_t xmit_lock;
u8 *iomem_base; u8 *iomem_base;
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment