/[linux-patches]/genpatches-2.6/trunk/2.6.12-pre/1344_sparc-sunsab.patch
Gentoo

Contents of /genpatches-2.6/trunk/2.6.12-pre/1344_sparc-sunsab.patch

Parent Directory Parent Directory | Revision Log Revision Log


Revision 4 - (show annotations) (download)
Sat Jun 11 23:20:41 2005 UTC (12 years, 4 months ago) by dsd
File size: 2206 byte(s)
Create 2.6.12 branch
1 diff -aur a/drivers/serial/sunsab.c b/drivers/serial/sunsab.c
2 --- a/drivers/serial/sunsab.c 2005-03-02 02:38:07.000000000 -0500
3 +++ b/drivers/serial/sunsab.c 2005-03-09 19:44:51.000000000 -0500
4 @@ -295,20 +295,22 @@
5 static void check_status(struct uart_sunsab_port *up,
6 union sab82532_irq_status *stat)
7 {
8 - if (stat->sreg.isr0 & SAB82532_ISR0_CDSC)
9 - uart_handle_dcd_change(&up->port,
10 + if (test_bit(SAB82532_MODEM_STATUS, &up->irqflags)) {
11 + if (stat->sreg.isr0 & SAB82532_ISR0_CDSC)
12 + uart_handle_dcd_change(&up->port,
13 !(readb(&up->regs->r.vstr) & SAB82532_VSTR_CD));
14
15 - if (stat->sreg.isr1 & SAB82532_ISR1_CSC)
16 - uart_handle_cts_change(&up->port,
17 + if (stat->sreg.isr1 & SAB82532_ISR1_CSC)
18 + uart_handle_cts_change(&up->port,
19 (readb(&up->regs->r.star) & SAB82532_STAR_CTS));
20
21 - if ((readb(&up->regs->r.pvr) & up->pvr_dsr_bit) ^ up->dsr) {
22 - up->dsr = (readb(&up->regs->r.pvr) & up->pvr_dsr_bit) ? 0 : 1;
23 - up->port.icount.dsr++;
24 - }
25 + if ((readb(&up->regs->r.pvr) & up->pvr_dsr_bit) ^ up->dsr) {
26 + up->dsr = (readb(&up->regs->r.pvr) & up->pvr_dsr_bit) ? 0 : 1;
27 + up->port.icount.dsr++;
28 + }
29
30 - wake_up_interruptible(&up->port.info->delta_msr_wait);
31 + wake_up_interruptible(&up->port.info->delta_msr_wait);
32 + }
33 }
34
35 static irqreturn_t sunsab_interrupt(int irq, void *dev_id, struct pt_regs *regs)
36 @@ -788,6 +790,11 @@
37
38 spin_lock_irqsave(&up->port.lock, flags);
39 sunsab_convert_to_sab(up, termios->c_cflag, termios->c_iflag, baud);
40 + if (UART_ENABLE_MS(&up->port, termios->c_cflag))
41 + set_bit(SAB82532_MODEM_STATUS, &up->irqflags);
42 + else
43 + clear_bit(SAB82532_MODEM_STATUS, &up->irqflags);
44 + uart_update_timeout(port, termios->c_cflag, baud);
45 spin_unlock_irqrestore(&up->port.lock, flags);
46 }
47
48 diff -aur a/drivers/serial/sunsab.h b/drivers/serial/sunsab.h
49 --- a/drivers/serial/sunsab.h 2005-03-02 02:38:33.000000000 -0500
50 +++ b/drivers/serial/sunsab.h 2005-03-09 19:44:51.000000000 -0500
51 @@ -126,6 +126,7 @@
52 /* irqflags bits */
53 #define SAB82532_ALLS 0x00000001
54 #define SAB82532_XPR 0x00000002
55 +#define SAB82532_MODEM_STATUS 0x00000004
56
57 /* RFIFO Status Byte */
58 #define SAB82532_RSTAT_PE 0x80

  ViewVC Help
Powered by ViewVC 1.1.20