Commit d8d16e47 authored by Jiri Slaby's avatar Jiri Slaby Committed by Linus Torvalds

[PATCH] char/isicom: Whitespace cleanup

Trailing spaces and tabs and space used for indentation deleted.  Indented
content of structures.  Switch/case indent.
Signed-off-by: default avatarJiri Slaby <xslaby@fi.muni.cz>
Signed-off-by: default avatarAndrew Morton <akpm@osdl.org>
Signed-off-by: default avatarLinus Torvalds <torvalds@osdl.org>
parent d9e39538
......@@ -161,16 +161,15 @@ static unsigned long tx_count = 0;
static int ISILoad_ioctl(struct inode *inode, struct file *filp, unsigned int cmd, unsigned long arg);
static void isicom_tx(unsigned long _data);
static void isicom_start(struct tty_struct * tty);
static void isicom_start(struct tty_struct *tty);
static unsigned char * tmp_buf;
static unsigned char *tmp_buf;
static DECLARE_MUTEX(tmp_buf_sem);
/* baud index mappings from linux defns to isi */
static signed char linuxb_to_isib[] = {
-1, 0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 11, 13, 15, 16, 17,
18, 19
-1, 0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 11, 13, 15, 16, 17, 18, 19
};
struct isi_board {
......@@ -261,111 +260,111 @@ static void unlock_card(struct isi_board *card)
* ISI Card specific ops ...
*/
static void raise_dtr(struct isi_port * port)
static void raise_dtr(struct isi_port *port)
{
struct isi_board * card = port->card;
struct isi_board *card = port->card;
unsigned short base = card->base;
unsigned char channel = port->channel;
if (!lock_card(card))
return;
outw(0x8000 | (channel << card->shift_count) | 0x02 , base);
outw(0x8000 | (channel << card->shift_count) | 0x02, base);
outw(0x0504, base);
InterruptTheCard(base);
port->status |= ISI_DTR;
unlock_card(card);
}
static inline void drop_dtr(struct isi_port * port)
static inline void drop_dtr(struct isi_port *port)
{
struct isi_board * card = port->card;
struct isi_board *card = port->card;
unsigned short base = card->base;
unsigned char channel = port->channel;
if (!lock_card(card))
return;
outw(0x8000 | (channel << card->shift_count) | 0x02 , base);
outw(0x8000 | (channel << card->shift_count) | 0x02, base);
outw(0x0404, base);
InterruptTheCard(base);
port->status &= ~ISI_DTR;
unlock_card(card);
}
static inline void raise_rts(struct isi_port * port)
static inline void raise_rts(struct isi_port *port)
{
struct isi_board * card = port->card;
struct isi_board *card = port->card;
unsigned short base = card->base;
unsigned char channel = port->channel;
if (!lock_card(card))
return;
outw(0x8000 | (channel << card->shift_count) | 0x02 , base);
outw(0x8000 | (channel << card->shift_count) | 0x02, base);
outw(0x0a04, base);
InterruptTheCard(base);
port->status |= ISI_RTS;
unlock_card(card);
}
static inline void drop_rts(struct isi_port * port)
static inline void drop_rts(struct isi_port *port)
{
struct isi_board * card = port->card;
struct isi_board *card = port->card;
unsigned short base = card->base;
unsigned char channel = port->channel;
if (!lock_card(card))
return;
outw(0x8000 | (channel << card->shift_count) | 0x02 , base);
outw(0x8000 | (channel << card->shift_count) | 0x02, base);
outw(0x0804, base);
InterruptTheCard(base);
port->status &= ~ISI_RTS;
unlock_card(card);
}
static inline void raise_dtr_rts(struct isi_port * port)
static inline void raise_dtr_rts(struct isi_port *port)
{
struct isi_board * card = port->card;
struct isi_board *card = port->card;
unsigned short base = card->base;
unsigned char channel = port->channel;
if (!lock_card(card))
return;
outw(0x8000 | (channel << card->shift_count) | 0x02 , base);
outw(0x8000 | (channel << card->shift_count) | 0x02, base);
outw(0x0f04, base);
InterruptTheCard(base);
port->status |= (ISI_DTR | ISI_RTS);
unlock_card(card);
}
static void drop_dtr_rts(struct isi_port * port)
static void drop_dtr_rts(struct isi_port *port)
{
struct isi_board * card = port->card;
struct isi_board *card = port->card;
unsigned short base = card->base;
unsigned char channel = port->channel;
if (!lock_card(card))
return;
outw(0x8000 | (channel << card->shift_count) | 0x02 , base);
outw(0x8000 | (channel << card->shift_count) | 0x02, base);
outw(0x0c04, base);
InterruptTheCard(base);
port->status &= ~(ISI_RTS | ISI_DTR);
unlock_card(card);
}
static inline void kill_queue(struct isi_port * port, short queue)
static inline void kill_queue(struct isi_port *port, short queue)
{
struct isi_board * card = port->card;
struct isi_board *card = port->card;
unsigned short base = card->base;
unsigned char channel = port->channel;
if (!lock_card(card))
return;
outw(0x8000 | (channel << card->shift_count) | 0x02 , base);
outw(0x8000 | (channel << card->shift_count) | 0x02, base);
outw((queue << 8) | 0x06, base);
InterruptTheCard(base);
unlock_card(card);
......@@ -407,15 +406,15 @@ static int ISILoad_ioctl(struct inode *inode, struct file *filp,
void __user *argp = (void __user *)arg;
/* exec_record exec_rec; */
if(get_user(card, (int __user *)argp))
if (get_user(card, (int __user *)argp))
return -EFAULT;
if(card < 0 || card >= BOARD_COUNT)
if (card < 0 || card >= BOARD_COUNT)
return -ENXIO;
base=isi_card[card].base;
if(base==0)
if (base==0)
return -ENXIO; /* disabled or not used */
switch(cmd) {
......@@ -426,12 +425,12 @@ static int ISILoad_ioctl(struct inode *inode, struct file *filp,
inw(base+0x8);
for(t=jiffies+HZ/100;time_before(jiffies, t););
for (t=jiffies+HZ/100;time_before(jiffies, t););
outw(0,base+0x8); /* Reset */
for(j=1;j<=3;j++) {
for(t=jiffies+HZ;time_before(jiffies, t););
for (j=1;j<=3;j++) {
for (t=jiffies+HZ;time_before(jiffies, t););
printk(".");
}
signature=(inw(base+0x4)) & 0xff;
......@@ -487,7 +486,7 @@ static int ISILoad_ioctl(struct inode *inode, struct file *filp,
if (!capable(CAP_SYS_ADMIN))
return -EPERM;
if(copy_from_user(&frame, argp, sizeof(bin_frame)))
if (copy_from_user(&frame, argp, sizeof(bin_frame)))
return -EFAULT;
if (WaitTillCardIsFree(base))
......@@ -495,13 +494,13 @@ static int ISILoad_ioctl(struct inode *inode, struct file *filp,
outw(0xf0,base); /* start upload sequence */
outw(0x00,base);
outw((frame.addr), base);/* lsb of adderess */
outw((frame.addr), base); /* lsb of adderess */
word_count=(frame.count >> 1) + frame.count % 2;
outw(word_count, base);
InterruptTheCard(base);
for(i=0;i<=0x2f;i++); /* a wee bit of delay */
for (i=0;i<=0x2f;i++); /* a wee bit of delay */
if (WaitTillCardIsFree(base))
return -EIO;
......@@ -515,7 +514,7 @@ static int ISILoad_ioctl(struct inode *inode, struct file *filp,
InterruptTheCard(base);
for(i=0;i<=0x0f;i++); /* another wee bit of delay */
for (i=0;i<=0x0f;i++); /* another wee bit of delay */
if (WaitTillCardIsFree(base))
return -EIO;
......@@ -530,7 +529,7 @@ static int ISILoad_ioctl(struct inode *inode, struct file *filp,
if (!capable(CAP_SYS_ADMIN))
return -EPERM;
if(copy_from_user(&frame, argp, sizeof(bin_header)))
if (copy_from_user(&frame, argp, sizeof(bin_header)))
return -EFAULT;
if (WaitTillCardIsFree(base))
......@@ -538,13 +537,13 @@ static int ISILoad_ioctl(struct inode *inode, struct file *filp,
outw(0xf1,base); /* start download sequence */
outw(0x00,base);
outw((frame.addr), base);/* lsb of adderess */
outw((frame.addr), base); /* lsb of adderess */
word_count=(frame.count >> 1) + frame.count % 2;
outw(word_count+1, base);
InterruptTheCard(base);
for(i=0;i<=0xf;i++); /* a wee bit of delay */
for (i=0;i<=0xf;i++); /* a wee bit of delay */
if (WaitTillCardIsFree(base))
return -EIO;
......@@ -559,7 +558,7 @@ static int ISILoad_ioctl(struct inode *inode, struct file *filp,
insw(base, frame.bin_data, word_count);
InterruptTheCard(base);
for(i=0;i<=0x0f;i++); /* another wee bit of delay */
for (i=0;i<=0x0f;i++); /* another wee bit of delay */
if (WaitTillCardIsFree(base))
return -EIO;
......@@ -569,7 +568,7 @@ static int ISILoad_ioctl(struct inode *inode, struct file *filp,
return -EIO;
}
if(copy_to_user(argp, &frame, sizeof(bin_frame)))
if (copy_to_user(argp, &frame, sizeof(bin_frame)))
return -EFAULT;
return 0;
......@@ -594,9 +593,7 @@ static int ISILoad_ioctl(struct inode *inode, struct file *filp,
printk(KERN_DEBUG "ISILoad: Received Ioctl cmd 0x%x.\n", cmd);
#endif
return -ENOIOCTLCMD;
}
}
......@@ -605,13 +602,13 @@ static int ISILoad_ioctl(struct inode *inode, struct file *filp,
*
*/
static inline int isicom_paranoia_check(struct isi_port const * port, char *name,
const char * routine)
static inline int isicom_paranoia_check(struct isi_port const *port, char *name,
const char *routine)
{
#ifdef ISICOM_DEBUG
static const char * badmagic =
static const char *badmagic =
KERN_WARNING "ISICOM: Warning: bad isicom magic for dev %s in %s.\n";
static const char * badport =
static const char *badport =
KERN_WARNING "ISICOM: Warning: NULL isicom port for dev %s in %s.\n";
if (!port) {
printk(badport, name, routine);
......@@ -636,8 +633,8 @@ static void isicom_tx(unsigned long _data)
{
short count = (BOARD_COUNT-1), card, base;
short txcount, wrd, residue, word_count, cnt;
struct isi_port * port;
struct tty_struct * tty;
struct isi_port *port;
struct tty_struct *tty;
#ifdef ISICOM_DEBUG
++tx_count;
......@@ -670,7 +667,7 @@ static void isicom_tx(unsigned long _data)
tty = port->tty;
if(tty == NULL) {
if (tty == NULL) {
unlock_card(&isi_card[card]);
continue;
}
......@@ -749,10 +746,10 @@ sched_again:
/* Interrupt handlers */
static void isicom_bottomhalf(void * data)
static void isicom_bottomhalf(void *data)
{
struct isi_port * port = (struct isi_port *) data;
struct tty_struct * tty = port->tty;
struct isi_port *port = (struct isi_port *) data;
struct tty_struct *tty = port->tty;
if (!tty)
return;
......@@ -768,9 +765,9 @@ static void isicom_bottomhalf(void * data)
static irqreturn_t isicom_interrupt(int irq, void *dev_id,
struct pt_regs *regs)
{
struct isi_board * card;
struct isi_port * port;
struct tty_struct * tty;
struct isi_board *card;
struct isi_port *port;
struct tty_struct *tty;
unsigned short base, header, word_count, count;
unsigned char channel;
short byte_count;
......@@ -951,10 +948,10 @@ static irqreturn_t isicom_interrupt(int irq, void *dev_id,
return IRQ_HANDLED;
}
static void isicom_config_port(struct isi_port * port)
static void isicom_config_port(struct isi_port *port)
{
struct isi_board * card = port->card;
struct tty_struct * tty;
struct isi_board *card = port->card;
struct tty_struct *tty;
unsigned long baud;
unsigned short channel_setup, base = card->base;
unsigned short channel = port->channel, shift_count = card->shift_count;
......@@ -1060,10 +1057,10 @@ static void isicom_config_port(struct isi_port * port)
/* open et all */
static inline void isicom_setup_board(struct isi_board * bp)
static inline void isicom_setup_board(struct isi_board *bp)
{
int channel;
struct isi_port * port;
struct isi_port *port;
unsigned long flags;
spin_lock_irqsave(&bp->card_lock, flags);
......@@ -1074,14 +1071,14 @@ static inline void isicom_setup_board(struct isi_board * bp)
port = bp->ports;
bp->status |= BOARD_ACTIVE;
spin_unlock_irqrestore(&bp->card_lock, flags);
for(channel = 0; channel < bp->port_count; channel++, port++)
for (channel = 0; channel < bp->port_count; channel++, port++)
drop_dtr_rts(port);
return;
}
static int isicom_setup_port(struct isi_port * port)
static int isicom_setup_port(struct isi_port *port)
{
struct isi_board * card = port->card;
struct isi_board *card = port->card;
unsigned long flags;
if (port->flags & ASYNC_INITIALIZED) {
......@@ -1118,9 +1115,9 @@ static int isicom_setup_port(struct isi_port * port)
return 0;
}
static int block_til_ready(struct tty_struct * tty, struct file * filp, struct isi_port * port)
static int block_til_ready(struct tty_struct *tty, struct file *filp, struct isi_port *port)
{
struct isi_board * card = port->card;
struct isi_board *card = port->card;
int do_clocal = 0, retval;
unsigned long flags;
DECLARE_WAITQUEUE(wait, current);
......@@ -1196,10 +1193,10 @@ static int block_til_ready(struct tty_struct * tty, struct file * filp, struct i
return 0;
}
static int isicom_open(struct tty_struct * tty, struct file * filp)
static int isicom_open(struct tty_struct *tty, struct file *filp)
{
struct isi_port * port;
struct isi_board * card;
struct isi_port *port;
struct isi_board *card;
unsigned int line, board;
int error;
......@@ -1235,7 +1232,7 @@ static int isicom_open(struct tty_struct * tty, struct file * filp)
/* close et all */
static inline void isicom_shutdown_board(struct isi_board * bp)
static inline void isicom_shutdown_board(struct isi_board *bp)
{
unsigned long flags;
......@@ -1246,10 +1243,10 @@ static inline void isicom_shutdown_board(struct isi_board * bp)
spin_unlock_irqrestore(&bp->card_lock, flags);
}
static void isicom_shutdown_port(struct isi_port * port)
static void isicom_shutdown_port(struct isi_port *port)
{
struct isi_board * card = port->card;
struct tty_struct * tty;
struct isi_board *card = port->card;
struct tty_struct *tty;
unsigned long flags;
tty = port->tty;
......@@ -1289,16 +1286,16 @@ static void isicom_shutdown_port(struct isi_port * port)
}
/* last port was closed , shutdown that boad too */
if(C_HUPCL(tty)) {
if (C_HUPCL(tty)) {
if (!card->count)
isicom_shutdown_board(card);
}
}
static void isicom_close(struct tty_struct * tty, struct file * filp)
static void isicom_close(struct tty_struct *tty, struct file *filp)
{
struct isi_port * port = (struct isi_port *) tty->driver_data;
struct isi_board * card = port->card;
struct isi_port *port = (struct isi_port *) tty->driver_data;
struct isi_board *card = port->card;
unsigned long flags;
if (!port)
......@@ -1373,11 +1370,11 @@ static void isicom_close(struct tty_struct * tty, struct file * filp)
}
/* write et all */
static int isicom_write(struct tty_struct * tty,
const unsigned char * buf, int count)
static int isicom_write(struct tty_struct *tty, const unsigned char *buf,
int count)
{
struct isi_port * port = (struct isi_port *) tty->driver_data;
struct isi_board * card = port->card;
struct isi_port *port = (struct isi_port *) tty->driver_data;
struct isi_board *card = port->card;
unsigned long flags;
int cnt, total = 0;
......@@ -1409,10 +1406,10 @@ static int isicom_write(struct tty_struct * tty,
}
/* put_char et all */
static void isicom_put_char(struct tty_struct * tty, unsigned char ch)
static void isicom_put_char(struct tty_struct *tty, unsigned char ch)
{
struct isi_port * port = (struct isi_port *) tty->driver_data;
struct isi_board * card = port->card;
struct isi_port *port = (struct isi_port *) tty->driver_data;
struct isi_board *card = port->card;
unsigned long flags;
if (isicom_paranoia_check(port, tty->name, "isicom_put_char"))
......@@ -1434,9 +1431,9 @@ static void isicom_put_char(struct tty_struct * tty, unsigned char ch)
}
/* flush_chars et all */
static void isicom_flush_chars(struct tty_struct * tty)
static void isicom_flush_chars(struct tty_struct *tty)
{
struct isi_port * port = (struct isi_port *) tty->driver_data;
struct isi_port *port = (struct isi_port *) tty->driver_data;
if (isicom_paranoia_check(port, tty->name, "isicom_flush_chars"))
return;
......@@ -1450,9 +1447,9 @@ static void isicom_flush_chars(struct tty_struct * tty)
}
/* write_room et all */
static int isicom_write_room(struct tty_struct * tty)
static int isicom_write_room(struct tty_struct *tty)
{
struct isi_port * port = (struct isi_port *) tty->driver_data;
struct isi_port *port = (struct isi_port *) tty->driver_data;
int free;
if (isicom_paranoia_check(port, tty->name, "isicom_write_room"))
......@@ -1465,21 +1462,21 @@ static int isicom_write_room(struct tty_struct * tty)
}
/* chars_in_buffer et all */
static int isicom_chars_in_buffer(struct tty_struct * tty)
static int isicom_chars_in_buffer(struct tty_struct *tty)
{
struct isi_port * port = (struct isi_port *) tty->driver_data;
struct isi_port *port = (struct isi_port *) tty->driver_data;
if (isicom_paranoia_check(port, tty->name, "isicom_chars_in_buffer"))
return 0;
return port->xmit_cnt;
}
/* ioctl et all */
static inline void isicom_send_break(struct isi_port * port, unsigned long length)
static inline void isicom_send_break(struct isi_port *port, unsigned long length)
{
struct isi_board * card = port->card;
struct isi_board *card = port->card;
unsigned short base = card->base;
if(!lock_card(card))
if (!lock_card(card))
return;
outw(0x8000 | ((port->channel) << (card->shift_count)) | 0x3, base);
......@@ -1492,7 +1489,7 @@ static inline void isicom_send_break(struct isi_port * port, unsigned long lengt
static int isicom_tiocmget(struct tty_struct *tty, struct file *file)
{
struct isi_port * port = (struct isi_port *) tty->driver_data;
struct isi_port *port = (struct isi_port *) tty->driver_data;
/* just send the port status */
unsigned short status = port->status;
......@@ -1510,7 +1507,7 @@ static int isicom_tiocmget(struct tty_struct *tty, struct file *file)
static int isicom_tiocmset(struct tty_struct *tty, struct file *file,
unsigned int set, unsigned int clear)
{
struct isi_port * port = (struct isi_port *) tty->driver_data;
struct isi_port *port = (struct isi_port *) tty->driver_data;
if (isicom_paranoia_check(port, tty->name, "isicom_ioctl"))
return -ENODEV;
......@@ -1528,13 +1525,13 @@ static int isicom_tiocmset(struct tty_struct *tty, struct file *file,
return 0;
}
static int isicom_set_serial_info(struct isi_port * port,
static int isicom_set_serial_info(struct isi_port *port,
struct serial_struct __user *info)
{
struct serial_struct newinfo;
int reconfig_port;
if(copy_from_user(&newinfo, info, sizeof(newinfo)))
if (copy_from_user(&newinfo, info, sizeof(newinfo)))
return -EFAULT;
reconfig_port = ((port->flags & ASYNC_SPD_MASK) !=
......@@ -1561,7 +1558,7 @@ static int isicom_set_serial_info(struct isi_port * port,
return 0;
}
static int isicom_get_serial_info(struct isi_port * port,
static int isicom_get_serial_info(struct isi_port *port,
struct serial_struct __user *info)
{
struct serial_struct out_info;
......@@ -1575,15 +1572,15 @@ static int isicom_get_serial_info(struct isi_port * port,
/* out_info.baud_base = ? */
out_info.close_delay = port->close_delay;
out_info.closing_wait = port->closing_wait;
if(copy_to_user(info, &out_info, sizeof(out_info)))
if (copy_to_user(info, &out_info, sizeof(out_info)))
return -EFAULT;
return 0;
}
static int isicom_ioctl(struct tty_struct * tty, struct file * filp,
static int isicom_ioctl(struct tty_struct *tty, struct file *filp,
unsigned int cmd, unsigned long arg)
{
struct isi_port * port = (struct isi_port *) tty->driver_data;
struct isi_port *port = (struct isi_port *) tty->driver_data;
void __user *argp = (void __user *)arg;
int retval;
......@@ -1612,7 +1609,7 @@ static int isicom_ioctl(struct tty_struct * tty, struct file * filp,
return put_user(C_CLOCAL(tty) ? 1 : 0, (unsigned long __user *)argp);
case TIOCSSOFTCAR:
if(get_user(arg, (unsigned long __user *) argp))
if (get_user(arg, (unsigned long __user *) argp))
return -EFAULT;
tty->termios->c_cflag =
((tty->termios->c_cflag & ~CLOCAL) |
......@@ -1632,9 +1629,10 @@ static int isicom_ioctl(struct tty_struct * tty, struct file * filp,
}
/* set_termios et all */
static void isicom_set_termios(struct tty_struct * tty, struct termios * old_termios)
static void isicom_set_termios(struct tty_struct *tty,
struct termios *old_termios)
{
struct isi_port * port = (struct isi_port *) tty->driver_data;
struct isi_port *port = (struct isi_port *) tty->driver_data;
if (isicom_paranoia_check(port, tty->name, "isicom_set_termios"))
return;
......@@ -1653,10 +1651,10 @@ static void isicom_set_termios(struct tty_struct * tty, struct termios * old_ter
}
/* throttle et all */
static void isicom_throttle(struct tty_struct * tty)
static void isicom_throttle(struct tty_struct *tty)
{
struct isi_port * port = (struct isi_port *) tty->driver_data;
struct isi_board * card = port->card;
struct isi_port *port = (struct isi_port *) tty->driver_data;
struct isi_board *card = port->card;
if (isicom_paranoia_check(port, tty->name, "isicom_throttle"))
return;
......@@ -1667,10 +1665,10 @@ static void isicom_throttle(struct tty_struct * tty)
}
/* unthrottle et all */
static void isicom_unthrottle(struct tty_struct * tty)
static void isicom_unthrottle(struct tty_struct *tty)
{
struct isi_port * port = (struct isi_port *) tty->driver_data;
struct isi_board * card = port->card;
struct isi_port *port = (struct isi_port *) tty->driver_data;
struct isi_board *card = port->card;
if (isicom_paranoia_check(port, tty->name, "isicom_unthrottle"))
return;
......@@ -1681,9 +1679,9 @@ static void isicom_unthrottle(struct tty_struct * tty)
}
/* stop et all */
static void isicom_stop(struct tty_struct * tty)
static void isicom_stop(struct tty_struct *tty)
{
struct isi_port * port = (struct isi_port *) tty->driver_data;
struct isi_port *port = (struct isi_port *) tty->driver_data;
if (isicom_paranoia_check(port, tty->name, "isicom_stop"))
return;
......@@ -1694,9 +1692,9 @@ static void isicom_stop(struct tty_struct * tty)
}
/* start et all */
static void isicom_start(struct tty_struct * tty)
static void isicom_start(struct tty_struct *tty)
{
struct isi_port * port = (struct isi_port *) tty->driver_data;
struct isi_port *port = (struct isi_port *) tty->driver_data;
if (isicom_paranoia_check(port, tty->name, "isicom_start"))
return;
......@@ -1707,19 +1705,19 @@ static void isicom_start(struct tty_struct * tty)
}
/* hangup et all */
static void do_isicom_hangup(void * data)
static void do_isicom_hangup(void *data)
{
struct isi_port * port = (struct isi_port *) data;
struct tty_struct * tty;
struct isi_port *port = (struct isi_port *) data;
struct tty_struct *tty;
tty = port->tty;
if (tty)
tty_hangup(tty);
}
static void isicom_hangup(struct tty_struct * tty)
static void isicom_hangup(struct tty_struct *tty)
{
struct isi_port * port = (struct isi_port *) tty->driver_data;
struct isi_port *port = (struct isi_port *) tty->driver_data;
if (isicom_paranoia_check(port, tty->name, "isicom_hangup"))
return;
......@@ -1732,10 +1730,10 @@ static void isicom_hangup(struct tty_struct * tty)
}
/* flush_buffer et all */
static void isicom_flush_buffer(struct tty_struct * tty)
static void isicom_flush_buffer(struct tty_struct *tty)
{
struct isi_port * port = (struct isi_port *) tty->driver_data;
struct isi_board * card = port->card;
struct isi_port *port = (struct isi_port *) tty->driver_data;
struct isi_board *card = port->card;
unsigned long flags;
if (isicom_paranoia_check(port, tty->name, "isicom_flush_buffer"))
......@@ -1880,7 +1878,7 @@ static void __exit unregister_isr(void)
static int __devinit isicom_init(void)
{
int card, channel, base;
struct isi_port * port;
struct isi_port *port;
unsigned long page;
if (!tmp_buf) {
......@@ -1963,7 +1961,7 @@ static int __devinit isicom_setup(void)
unsigned int ioaddr;
card = 0;
for(idx=0; idx < BOARD_COUNT; idx++) {
for (idx=0; idx < BOARD_COUNT; idx++) {
if (io[idx]) {
isi_card[idx].base=io[idx];
isi_card[idx].irq=irq[idx];
......@@ -2005,7 +2003,8 @@ static int __devinit isicom_setup(void)
break;
/* found a PCI ISI card! */
ioaddr = pci_resource_start (dev, 3); /* i.e at offset 0x1c in the
ioaddr = pci_resource_start (dev, 3);
/* i.e at offset 0x1c in the
* PCI configuration register
* space.
*/
......@@ -2063,7 +2062,7 @@ static void __exit isicom_exit(void)
unregister_isr();
unregister_drivers();
unregister_ioregion();
if(tmp_buf)
if (tmp_buf)
free_page((unsigned long)tmp_buf);
if (misc_deregister(&isiloader_device))
printk(KERN_ERR "ISICOM: Unable to unregister Firmware Loader driver\n");
......
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