From 446393e9602d3b32515ca107f3c004194cb690f3 Mon Sep 17 00:00:00 2001 From: Ebru Akagunduz Date: Wed, 1 Oct 2014 23:04:48 +0300 Subject: [PATCH] staging: dgnc: Fix do not add new typedefs This patch fixes "do not add new typedefs" checkpatch.pl warning in dgnc_types.h Signed-off-by: Ebru Akagunduz Signed-off-by: Greg Kroah-Hartman --- drivers/staging/dgnc/dgnc_cls.c | 82 +++++++++++++++--------------- drivers/staging/dgnc/dgnc_driver.c | 2 +- drivers/staging/dgnc/dgnc_driver.h | 30 +++++------ drivers/staging/dgnc/dgnc_mgmt.c | 2 +- drivers/staging/dgnc/dgnc_neo.c | 74 +++++++++++++-------------- drivers/staging/dgnc/dgnc_tty.c | 8 +-- drivers/staging/dgnc/dgnc_tty.h | 2 +- drivers/staging/dgnc/dgnc_types.h | 3 -- 8 files changed, 100 insertions(+), 103 deletions(-) diff --git a/drivers/staging/dgnc/dgnc_cls.c b/drivers/staging/dgnc/dgnc_cls.c index 6c6bbd77ba13..a17f4f6095c8 100644 --- a/drivers/staging/dgnc/dgnc_cls.c +++ b/drivers/staging/dgnc/dgnc_cls.c @@ -50,7 +50,7 @@ static inline void cls_set_ixon_flow_control(struct channel_t *ch); static inline void cls_set_ixoff_flow_control(struct channel_t *ch); static inline void cls_set_no_output_flow_control(struct channel_t *ch); static inline void cls_set_no_input_flow_control(struct channel_t *ch); -static void cls_parse_modem(struct channel_t *ch, uchar signals); +static void cls_parse_modem(struct channel_t *ch, unsigned char signals); static void cls_tasklet(unsigned long data); static void cls_vpd(struct dgnc_board *brd); static void cls_uart_init(struct channel_t *ch); @@ -95,9 +95,9 @@ struct board_ops dgnc_cls_ops = { static inline void cls_set_cts_flow_control(struct channel_t *ch) { - uchar lcrb = readb(&ch->ch_cls_uart->lcr); - uchar ier = readb(&ch->ch_cls_uart->ier); - uchar isr_fcr = 0; + unsigned char lcrb = readb(&ch->ch_cls_uart->lcr); + unsigned char ier = readb(&ch->ch_cls_uart->ier); + unsigned char isr_fcr = 0; /* @@ -139,9 +139,9 @@ static inline void cls_set_cts_flow_control(struct channel_t *ch) static inline void cls_set_ixon_flow_control(struct channel_t *ch) { - uchar lcrb = readb(&ch->ch_cls_uart->lcr); - uchar ier = readb(&ch->ch_cls_uart->ier); - uchar isr_fcr = 0; + unsigned char lcrb = readb(&ch->ch_cls_uart->lcr); + unsigned char ier = readb(&ch->ch_cls_uart->ier); + unsigned char isr_fcr = 0; /* @@ -187,9 +187,9 @@ static inline void cls_set_ixon_flow_control(struct channel_t *ch) static inline void cls_set_no_output_flow_control(struct channel_t *ch) { - uchar lcrb = readb(&ch->ch_cls_uart->lcr); - uchar ier = readb(&ch->ch_cls_uart->ier); - uchar isr_fcr = 0; + unsigned char lcrb = readb(&ch->ch_cls_uart->lcr); + unsigned char ier = readb(&ch->ch_cls_uart->ier); + unsigned char isr_fcr = 0; /* @@ -233,9 +233,9 @@ static inline void cls_set_no_output_flow_control(struct channel_t *ch) static inline void cls_set_rts_flow_control(struct channel_t *ch) { - uchar lcrb = readb(&ch->ch_cls_uart->lcr); - uchar ier = readb(&ch->ch_cls_uart->ier); - uchar isr_fcr = 0; + unsigned char lcrb = readb(&ch->ch_cls_uart->lcr); + unsigned char ier = readb(&ch->ch_cls_uart->ier); + unsigned char isr_fcr = 0; /* @@ -275,9 +275,9 @@ static inline void cls_set_rts_flow_control(struct channel_t *ch) static inline void cls_set_ixoff_flow_control(struct channel_t *ch) { - uchar lcrb = readb(&ch->ch_cls_uart->lcr); - uchar ier = readb(&ch->ch_cls_uart->ier); - uchar isr_fcr = 0; + unsigned char lcrb = readb(&ch->ch_cls_uart->lcr); + unsigned char ier = readb(&ch->ch_cls_uart->ier); + unsigned char isr_fcr = 0; /* @@ -319,9 +319,9 @@ static inline void cls_set_ixoff_flow_control(struct channel_t *ch) static inline void cls_set_no_input_flow_control(struct channel_t *ch) { - uchar lcrb = readb(&ch->ch_cls_uart->lcr); - uchar ier = readb(&ch->ch_cls_uart->ier); - uchar isr_fcr = 0; + unsigned char lcrb = readb(&ch->ch_cls_uart->lcr); + unsigned char ier = readb(&ch->ch_cls_uart->ier); + unsigned char isr_fcr = 0; /* @@ -383,7 +383,7 @@ static inline void cls_clear_break(struct channel_t *ch, int force) /* Turn break off, and unset some variables */ if (ch->ch_flags & CH_BREAK_SENDING) { if (time_after(jiffies, ch->ch_stop_sending_break) || force) { - uchar temp = readb(&ch->ch_cls_uart->lcr); + unsigned char temp = readb(&ch->ch_cls_uart->lcr); writeb((temp & ~UART_LCR_SBC), &ch->ch_cls_uart->lcr); ch->ch_flags &= ~(CH_BREAK_SENDING); @@ -398,7 +398,7 @@ static inline void cls_clear_break(struct channel_t *ch, int force) static inline void cls_parse_isr(struct dgnc_board *brd, uint port) { struct channel_t *ch; - uchar isr = 0; + unsigned char isr = 0; unsigned long flags; /* @@ -464,10 +464,10 @@ static inline void cls_parse_isr(struct dgnc_board *brd, uint port) */ static void cls_param(struct tty_struct *tty) { - uchar lcr = 0; - uchar uart_lcr = 0; - uchar ier = 0; - uchar uart_ier = 0; + unsigned char lcr = 0; + unsigned char uart_lcr = 0; + unsigned char ier = 0; + unsigned char uart_ier = 0; uint baud = 9600; int quot = 0; struct dgnc_board *bd; @@ -796,7 +796,7 @@ static irqreturn_t cls_intr(int irq, void *voidbrd) { struct dgnc_board *brd = (struct dgnc_board *) voidbrd; uint i = 0; - uchar poll_reg; + unsigned char poll_reg; unsigned long flags; if (!brd) { @@ -847,7 +847,7 @@ static irqreturn_t cls_intr(int irq, void *voidbrd) static void cls_disable_receiver(struct channel_t *ch) { - uchar tmp = readb(&ch->ch_cls_uart->ier); + unsigned char tmp = readb(&ch->ch_cls_uart->ier); tmp &= ~(UART_IER_RDI); writeb(tmp, &ch->ch_cls_uart->ier); @@ -856,7 +856,7 @@ static void cls_disable_receiver(struct channel_t *ch) static void cls_enable_receiver(struct channel_t *ch) { - uchar tmp = readb(&ch->ch_cls_uart->ier); + unsigned char tmp = readb(&ch->ch_cls_uart->ier); tmp |= (UART_IER_RDI); writeb(tmp, &ch->ch_cls_uart->ier); @@ -866,8 +866,8 @@ static void cls_enable_receiver(struct channel_t *ch) static void cls_copy_data_from_uart_to_queue(struct channel_t *ch) { int qleft = 0; - uchar linestatus = 0; - uchar error_mask = 0; + unsigned char linestatus = 0; + unsigned char error_mask = 0; ushort head; ushort tail; unsigned long flags; @@ -903,7 +903,7 @@ static void cls_copy_data_from_uart_to_queue(struct channel_t *ch) * Discard character if we are ignoring the error mask. */ if (linestatus & error_mask) { - uchar discard; + unsigned char discard; linestatus = 0; discard = readb(&ch->ch_cls_uart->txrx); @@ -1114,9 +1114,9 @@ static void cls_copy_data_from_queue_to_uart(struct channel_t *ch) } -static void cls_parse_modem(struct channel_t *ch, uchar signals) +static void cls_parse_modem(struct channel_t *ch, unsigned char signals) { - uchar msignals = signals; + unsigned char msignals = signals; unsigned long flags; if (!ch || ch->magic != DGNC_CHANNEL_MAGIC) @@ -1128,7 +1128,7 @@ static void cls_parse_modem(struct channel_t *ch, uchar signals) */ spin_lock_irqsave(&ch->ch_lock, flags); if (ch->ch_digi.digi_flags & DIGI_ALTPIN) { - uchar mswap = signals; + unsigned char mswap = signals; if (mswap & UART_MSR_DDCD) { msignals &= ~UART_MSR_DDCD; @@ -1182,7 +1182,7 @@ static void cls_parse_modem(struct channel_t *ch, uchar signals) /* Make the UART raise any of the output signals we want up */ static void cls_assert_modem_signals(struct channel_t *ch) { - uchar out; + unsigned char out; if (!ch || ch->magic != DGNC_CHANNEL_MAGIC) return; @@ -1226,8 +1226,8 @@ static void cls_send_stop_character(struct channel_t *ch) /* Inits UART */ static void cls_uart_init(struct channel_t *ch) { - uchar lcrb = readb(&ch->ch_cls_uart->lcr); - uchar isr_fcr = 0; + unsigned char lcrb = readb(&ch->ch_cls_uart->lcr); + unsigned char isr_fcr = 0; writeb(0, &ch->ch_cls_uart->ier); @@ -1278,8 +1278,8 @@ static void cls_uart_off(struct channel_t *ch) */ static uint cls_get_uart_bytes_left(struct channel_t *ch) { - uchar left = 0; - uchar lsr = 0; + unsigned char left = 0; + unsigned char lsr = 0; if (!ch || ch->magic != DGNC_CHANNEL_MAGIC) return 0; @@ -1317,7 +1317,7 @@ static void cls_send_break(struct channel_t *ch, int msecs) if (msecs == 0) { /* Turn break off, and unset some variables */ if (ch->ch_flags & CH_BREAK_SENDING) { - uchar temp = readb(&ch->ch_cls_uart->lcr); + unsigned char temp = readb(&ch->ch_cls_uart->lcr); writeb((temp & ~UART_LCR_SBC), &ch->ch_cls_uart->lcr); ch->ch_flags &= ~(CH_BREAK_SENDING); @@ -1335,7 +1335,7 @@ static void cls_send_break(struct channel_t *ch, int msecs) /* Tell the UART to start sending the break */ if (!(ch->ch_flags & CH_BREAK_SENDING)) { - uchar temp = readb(&ch->ch_cls_uart->lcr); + unsigned char temp = readb(&ch->ch_cls_uart->lcr); writeb((temp | UART_LCR_SBC), &ch->ch_cls_uart->lcr); ch->ch_flags |= (CH_BREAK_SENDING); diff --git a/drivers/staging/dgnc/dgnc_driver.c b/drivers/staging/dgnc/dgnc_driver.c index 9975ba605366..29cc2e4ba935 100644 --- a/drivers/staging/dgnc/dgnc_driver.c +++ b/drivers/staging/dgnc/dgnc_driver.c @@ -130,7 +130,7 @@ static struct pci_device_id dgnc_pci_tbl[] = { MODULE_DEVICE_TABLE(pci, dgnc_pci_tbl); struct board_id { - uchar *name; + unsigned char *name; uint maxports; unsigned int is_pci_express; }; diff --git a/drivers/staging/dgnc/dgnc_driver.h b/drivers/staging/dgnc/dgnc_driver.h index c6d0746b32d7..f901957c757f 100644 --- a/drivers/staging/dgnc/dgnc_driver.h +++ b/drivers/staging/dgnc/dgnc_driver.h @@ -209,13 +209,13 @@ struct dgnc_board { u16 device; /* PCI device ID */ u16 subvendor; /* PCI subsystem vendor ID */ u16 subdevice; /* PCI subsystem device ID */ - uchar rev; /* PCI revision ID */ + unsigned char rev; /* PCI revision ID */ uint pci_bus; /* PCI bus value */ uint pci_slot; /* PCI slot value */ uint maxports; /* MAX ports this board can handle */ - uchar dvid; /* Board specific device id */ - uchar vpd[128]; /* VPD of board, if found */ - uchar serial_num[20]; /* Serial number of board, if found in VPD */ + unsigned char dvid; /* Board specific device id */ + unsigned char vpd[128]; /* VPD of board, if found */ + unsigned char serial_num[20]; /* Serial number of board, if found in VPD */ spinlock_t bd_lock; /* Used to protect board */ @@ -384,41 +384,41 @@ struct channel_t { tcflag_t ch_c_cflag; /* channel cflags */ tcflag_t ch_c_oflag; /* channel oflags */ tcflag_t ch_c_lflag; /* channel lflags */ - uchar ch_stopc; /* Stop character */ - uchar ch_startc; /* Start character */ + unsigned char ch_stopc; /* Stop character */ + unsigned char ch_startc; /* Start character */ uint ch_old_baud; /* Cache of the current baud */ uint ch_custom_speed;/* Custom baud, if set */ uint ch_wopen; /* Waiting for open process cnt */ - uchar ch_mostat; /* FEP output modem status */ - uchar ch_mistat; /* FEP input modem status */ + unsigned char ch_mostat; /* FEP output modem status */ + unsigned char ch_mistat; /* FEP input modem status */ struct neo_uart_struct __iomem *ch_neo_uart; /* Pointer to the "mapped" UART struct */ struct cls_uart_struct __iomem *ch_cls_uart; /* Pointer to the "mapped" UART struct */ - uchar ch_cached_lsr; /* Cached value of the LSR register */ + unsigned char ch_cached_lsr; /* Cached value of the LSR register */ - uchar *ch_rqueue; /* Our read queue buffer - malloc'ed */ + unsigned char *ch_rqueue; /* Our read queue buffer - malloc'ed */ ushort ch_r_head; /* Head location of the read queue */ ushort ch_r_tail; /* Tail location of the read queue */ - uchar *ch_equeue; /* Our error queue buffer - malloc'ed */ + unsigned char *ch_equeue; /* Our error queue buffer - malloc'ed */ ushort ch_e_head; /* Head location of the error queue */ ushort ch_e_tail; /* Tail location of the error queue */ - uchar *ch_wqueue; /* Our write queue buffer - malloc'ed */ + unsigned char *ch_wqueue; /* Our write queue buffer - malloc'ed */ ushort ch_w_head; /* Head location of the write queue */ ushort ch_w_tail; /* Tail location of the write queue */ ulong ch_rxcount; /* total of data received so far */ ulong ch_txcount; /* total of data transmitted so far */ - uchar ch_r_tlevel; /* Receive Trigger level */ - uchar ch_t_tlevel; /* Transmit Trigger level */ + unsigned char ch_r_tlevel; /* Receive Trigger level */ + unsigned char ch_t_tlevel; /* Transmit Trigger level */ - uchar ch_r_watermark; /* Receive Watermark */ + unsigned char ch_r_watermark; /* Receive Watermark */ ulong ch_stop_sending_break; /* Time we should STOP sending a break */ diff --git a/drivers/staging/dgnc/dgnc_mgmt.c b/drivers/staging/dgnc/dgnc_mgmt.c index 9e45b85717f3..5544a8e7f4bc 100644 --- a/drivers/staging/dgnc/dgnc_mgmt.c +++ b/drivers/staging/dgnc/dgnc_mgmt.c @@ -185,7 +185,7 @@ long dgnc_mgmt_ioctl(struct file *file, unsigned int cmd, unsigned long arg) { struct channel_t *ch; struct ni_info ni; - uchar mstat = 0; + unsigned char mstat = 0; uint board = 0; uint channel = 0; diff --git a/drivers/staging/dgnc/dgnc_neo.c b/drivers/staging/dgnc/dgnc_neo.c index 9c8f06ba6f66..a5bd08fef270 100644 --- a/drivers/staging/dgnc/dgnc_neo.c +++ b/drivers/staging/dgnc/dgnc_neo.c @@ -53,7 +53,7 @@ static inline void neo_set_ixoff_flow_control(struct channel_t *ch); static inline void neo_set_no_output_flow_control(struct channel_t *ch); static inline void neo_set_no_input_flow_control(struct channel_t *ch); static inline void neo_set_new_start_stop_chars(struct channel_t *ch); -static void neo_parse_modem(struct channel_t *ch, uchar signals); +static void neo_parse_modem(struct channel_t *ch, unsigned char signals); static void neo_tasklet(unsigned long data); static void neo_vpd(struct dgnc_board *brd); static void neo_uart_init(struct channel_t *ch); @@ -113,8 +113,8 @@ static inline void neo_pci_posting_flush(struct dgnc_board *bd) static inline void neo_set_cts_flow_control(struct channel_t *ch) { - uchar ier = readb(&ch->ch_neo_uart->ier); - uchar efr = readb(&ch->ch_neo_uart->efr); + unsigned char ier = readb(&ch->ch_neo_uart->ier); + unsigned char efr = readb(&ch->ch_neo_uart->efr); /* Turn on auto CTS flow control */ @@ -150,8 +150,8 @@ static inline void neo_set_cts_flow_control(struct channel_t *ch) static inline void neo_set_rts_flow_control(struct channel_t *ch) { - uchar ier = readb(&ch->ch_neo_uart->ier); - uchar efr = readb(&ch->ch_neo_uart->efr); + unsigned char ier = readb(&ch->ch_neo_uart->ier); + unsigned char efr = readb(&ch->ch_neo_uart->efr); /* Turn on auto RTS flow control */ #if 1 @@ -193,8 +193,8 @@ static inline void neo_set_rts_flow_control(struct channel_t *ch) static inline void neo_set_ixon_flow_control(struct channel_t *ch) { - uchar ier = readb(&ch->ch_neo_uart->ier); - uchar efr = readb(&ch->ch_neo_uart->efr); + unsigned char ier = readb(&ch->ch_neo_uart->ier); + unsigned char efr = readb(&ch->ch_neo_uart->efr); /* Turn off auto CTS flow control */ ier &= ~(UART_17158_IER_CTSDSR); @@ -230,8 +230,8 @@ static inline void neo_set_ixon_flow_control(struct channel_t *ch) static inline void neo_set_ixoff_flow_control(struct channel_t *ch) { - uchar ier = readb(&ch->ch_neo_uart->ier); - uchar efr = readb(&ch->ch_neo_uart->efr); + unsigned char ier = readb(&ch->ch_neo_uart->ier); + unsigned char efr = readb(&ch->ch_neo_uart->efr); /* Turn off auto RTS flow control */ ier &= ~(UART_17158_IER_RTSDTR); @@ -268,8 +268,8 @@ static inline void neo_set_ixoff_flow_control(struct channel_t *ch) static inline void neo_set_no_input_flow_control(struct channel_t *ch) { - uchar ier = readb(&ch->ch_neo_uart->ier); - uchar efr = readb(&ch->ch_neo_uart->efr); + unsigned char ier = readb(&ch->ch_neo_uart->ier); + unsigned char efr = readb(&ch->ch_neo_uart->efr); /* Turn off auto RTS flow control */ ier &= ~(UART_17158_IER_RTSDTR); @@ -308,8 +308,8 @@ static inline void neo_set_no_input_flow_control(struct channel_t *ch) static inline void neo_set_no_output_flow_control(struct channel_t *ch) { - uchar ier = readb(&ch->ch_neo_uart->ier); - uchar efr = readb(&ch->ch_neo_uart->efr); + unsigned char ier = readb(&ch->ch_neo_uart->ier); + unsigned char efr = readb(&ch->ch_neo_uart->efr); /* Turn off auto CTS flow control */ ier &= ~(UART_17158_IER_CTSDSR); @@ -382,7 +382,7 @@ static inline void neo_clear_break(struct channel_t *ch, int force) if (ch->ch_flags & CH_BREAK_SENDING) { if (time_after_eq(jiffies, ch->ch_stop_sending_break) || force) { - uchar temp = readb(&ch->ch_neo_uart->lcr); + unsigned char temp = readb(&ch->ch_neo_uart->lcr); writeb((temp & ~UART_LCR_SBC), &ch->ch_neo_uart->lcr); neo_pci_posting_flush(ch->ch_bd); @@ -400,8 +400,8 @@ static inline void neo_clear_break(struct channel_t *ch, int force) static inline void neo_parse_isr(struct dgnc_board *brd, uint port) { struct channel_t *ch; - uchar isr; - uchar cause; + unsigned char isr; + unsigned char cause; unsigned long flags; if (!brd || brd->magic != DGNC_BOARD_MAGIC) @@ -609,10 +609,10 @@ static inline void neo_parse_lsr(struct dgnc_board *brd, uint port) */ static void neo_param(struct tty_struct *tty) { - uchar lcr = 0; - uchar uart_lcr = 0; - uchar ier = 0; - uchar uart_ier = 0; + unsigned char lcr = 0; + unsigned char uart_lcr = 0; + unsigned char ier = 0; + unsigned char uart_ier = 0; uint baud = 9600; int quot = 0; struct dgnc_board *bd; @@ -1098,7 +1098,7 @@ static irqreturn_t neo_intr(int irq, void *voidbrd) */ static void neo_disable_receiver(struct channel_t *ch) { - uchar tmp = readb(&ch->ch_neo_uart->ier); + unsigned char tmp = readb(&ch->ch_neo_uart->ier); tmp &= ~(UART_IER_RDI); writeb(tmp, &ch->ch_neo_uart->ier); @@ -1113,7 +1113,7 @@ static void neo_disable_receiver(struct channel_t *ch) */ static void neo_enable_receiver(struct channel_t *ch) { - uchar tmp = readb(&ch->ch_neo_uart->ier); + unsigned char tmp = readb(&ch->ch_neo_uart->ier); tmp |= (UART_IER_RDI); writeb(tmp, &ch->ch_neo_uart->ier); @@ -1124,8 +1124,8 @@ static void neo_enable_receiver(struct channel_t *ch) static void neo_copy_data_from_uart_to_queue(struct channel_t *ch) { int qleft = 0; - uchar linestatus = 0; - uchar error_mask = 0; + unsigned char linestatus = 0; + unsigned char error_mask = 0; int n = 0; int total = 0; ushort head; @@ -1286,7 +1286,7 @@ static void neo_copy_data_from_uart_to_queue(struct channel_t *ch) * Discard character if we are ignoring the error mask. */ if (linestatus & error_mask) { - uchar discard; + unsigned char discard; linestatus = 0; memcpy_fromio(&discard, &ch->ch_neo_uart->txrxburst, 1); @@ -1309,7 +1309,7 @@ static void neo_copy_data_from_uart_to_queue(struct channel_t *ch) } memcpy_fromio(ch->ch_rqueue + head, &ch->ch_neo_uart->txrxburst, 1); - ch->ch_equeue[head] = (uchar) linestatus; + ch->ch_equeue[head] = (unsigned char) linestatus; dgnc_sniff_nowait_nolock(ch, "UART READ", ch->ch_rqueue + head, 1); /* Ditch any remaining linestatus value. */ @@ -1378,7 +1378,7 @@ static int neo_drain(struct tty_struct *tty, uint seconds) */ static void neo_flush_uart_write(struct channel_t *ch) { - uchar tmp = 0; + unsigned char tmp = 0; int i = 0; if (!ch || ch->magic != DGNC_CHANNEL_MAGIC) @@ -1408,7 +1408,7 @@ static void neo_flush_uart_write(struct channel_t *ch) */ static void neo_flush_uart_read(struct channel_t *ch) { - uchar tmp = 0; + unsigned char tmp = 0; int i = 0; if (!ch || ch->magic != DGNC_CHANNEL_MAGIC) @@ -1460,7 +1460,7 @@ static void neo_copy_data_from_queue_to_uart(struct channel_t *ch) * If FIFOs are disabled. Send data directly to txrx register */ if (!(ch->ch_flags & CH_FIFO_ENABLED)) { - uchar lsrbits = readb(&ch->ch_neo_uart->lsr); + unsigned char lsrbits = readb(&ch->ch_neo_uart->lsr); /* Cache the LSR bits for later parsing */ ch->ch_cached_lsr |= lsrbits; @@ -1584,9 +1584,9 @@ static void neo_copy_data_from_queue_to_uart(struct channel_t *ch) } -static void neo_parse_modem(struct channel_t *ch, uchar signals) +static void neo_parse_modem(struct channel_t *ch, unsigned char signals) { - uchar msignals = signals; + unsigned char msignals = signals; if (!ch || ch->magic != DGNC_CHANNEL_MAGIC) return; @@ -1596,7 +1596,7 @@ static void neo_parse_modem(struct channel_t *ch, uchar signals) * This prolly breaks DSRPACE, so we should be more clever here. */ if (ch->ch_digi.digi_flags & DIGI_ALTPIN) { - uchar mswap = msignals; + unsigned char mswap = msignals; if (mswap & UART_MSR_DDCD) { msignals &= ~UART_MSR_DDCD; @@ -1644,7 +1644,7 @@ static void neo_parse_modem(struct channel_t *ch, uchar signals) /* Make the UART raise any of the output signals we want up */ static void neo_assert_modem_signals(struct channel_t *ch) { - uchar out; + unsigned char out; if (!ch || ch->magic != DGNC_CHANNEL_MAGIC) return; @@ -1731,8 +1731,8 @@ static void neo_uart_off(struct channel_t *ch) static uint neo_get_uart_bytes_left(struct channel_t *ch) { - uchar left = 0; - uchar lsr = readb(&ch->ch_neo_uart->lsr); + unsigned char left = 0; + unsigned char lsr = readb(&ch->ch_neo_uart->lsr); /* We must cache the LSR as some of the bits get reset once read... */ ch->ch_cached_lsr |= lsr; @@ -1759,7 +1759,7 @@ static void neo_send_break(struct channel_t *ch, int msecs) */ if (msecs == 0) { if (ch->ch_flags & CH_BREAK_SENDING) { - uchar temp = readb(&ch->ch_neo_uart->lcr); + unsigned char temp = readb(&ch->ch_neo_uart->lcr); writeb((temp & ~UART_LCR_SBC), &ch->ch_neo_uart->lcr); neo_pci_posting_flush(ch->ch_bd); @@ -1778,7 +1778,7 @@ static void neo_send_break(struct channel_t *ch, int msecs) /* Tell the UART to start sending the break */ if (!(ch->ch_flags & CH_BREAK_SENDING)) { - uchar temp = readb(&ch->ch_neo_uart->lcr); + unsigned char temp = readb(&ch->ch_neo_uart->lcr); writeb((temp | UART_LCR_SBC), &ch->ch_neo_uart->lcr); neo_pci_posting_flush(ch->ch_bd); diff --git a/drivers/staging/dgnc/dgnc_tty.c b/drivers/staging/dgnc/dgnc_tty.c index 07fba1e9afaf..03c15069731f 100644 --- a/drivers/staging/dgnc/dgnc_tty.c +++ b/drivers/staging/dgnc/dgnc_tty.c @@ -67,7 +67,7 @@ * internal variables */ static struct dgnc_board *dgnc_BoardsByMajor[256]; -static uchar *dgnc_TmpWriteBuf; +static unsigned char *dgnc_TmpWriteBuf; static DECLARE_MUTEX(dgnc_TmpWriteSem); /* @@ -450,7 +450,7 @@ void dgnc_tty_uninit(struct dgnc_board *brd) * dgnc_sniff - Dump data out to the "sniff" buffer if the * proc sniff file is opened... */ -void dgnc_sniff_nowait_nolock(struct channel_t *ch, uchar *text, uchar *buf, int len) +void dgnc_sniff_nowait_nolock(struct channel_t *ch, unsigned char *text, unsigned char *buf, int len) { struct timeval tv; int n; @@ -1949,7 +1949,7 @@ static int dgnc_tty_write(struct tty_struct *tty, * copy_from_user() returns the number * of bytes that could *NOT* be copied. */ - count -= copy_from_user(dgnc_TmpWriteBuf, (const uchar __user *) buf, count); + count -= copy_from_user(dgnc_TmpWriteBuf, (const unsigned char __user *) buf, count); if (!count) { up(&dgnc_TmpWriteSem); @@ -2028,7 +2028,7 @@ static int dgnc_tty_tiocmget(struct tty_struct *tty) struct channel_t *ch; struct un_t *un; int result = -EIO; - uchar mstat = 0; + unsigned char mstat = 0; unsigned long flags; if (!tty || tty->magic != TTY_MAGIC) diff --git a/drivers/staging/dgnc/dgnc_tty.h b/drivers/staging/dgnc/dgnc_tty.h index 9d1c2847bd94..58eef257c2ec 100644 --- a/drivers/staging/dgnc/dgnc_tty.h +++ b/drivers/staging/dgnc/dgnc_tty.h @@ -37,6 +37,6 @@ void dgnc_carrier(struct channel_t *ch); void dgnc_wakeup_writes(struct channel_t *ch); void dgnc_check_queue_flow_control(struct channel_t *ch); -void dgnc_sniff_nowait_nolock(struct channel_t *ch, uchar *text, uchar *buf, int nbuf); +void dgnc_sniff_nowait_nolock(struct channel_t *ch, unsigned char *text, unsigned char *buf, int nbuf); #endif diff --git a/drivers/staging/dgnc/dgnc_types.h b/drivers/staging/dgnc/dgnc_types.h index 4fa358535f84..3aafcedbb0d9 100644 --- a/drivers/staging/dgnc/dgnc_types.h +++ b/drivers/staging/dgnc/dgnc_types.h @@ -30,7 +30,4 @@ # define FALSE 0 #endif -/* Required for our shared headers! */ -typedef unsigned char uchar; - #endif