diff options
Diffstat (limited to 'drivers/char')
| -rw-r--r-- | drivers/char/Kconfig | 6 | ||||
| -rw-r--r-- | drivers/char/genrtc.c | 1 | ||||
| -rw-r--r-- | drivers/char/hw_random/virtio-rng.c | 3 | ||||
| -rw-r--r-- | drivers/char/rtc.c | 1 | ||||
| -rw-r--r-- | drivers/char/sonypi.c | 1 | ||||
| -rw-r--r-- | drivers/char/tty_buffer.c | 31 | ||||
| -rw-r--r-- | drivers/char/virtio_console.c | 1 | ||||
| -rw-r--r-- | drivers/char/vt_ioctl.c | 2 |
8 files changed, 22 insertions, 24 deletions
diff --git a/drivers/char/Kconfig b/drivers/char/Kconfig index 08a6f50ae791..6aad99ec4e0f 100644 --- a/drivers/char/Kconfig +++ b/drivers/char/Kconfig | |||
| @@ -323,7 +323,7 @@ config SPECIALIX | |||
| 323 | 323 | ||
| 324 | config SX | 324 | config SX |
| 325 | tristate "Specialix SX (and SI) card support" | 325 | tristate "Specialix SX (and SI) card support" |
| 326 | depends on SERIAL_NONSTANDARD && (PCI || EISA || ISA) | 326 | depends on SERIAL_NONSTANDARD && (PCI || EISA || ISA) && BROKEN |
| 327 | help | 327 | help |
| 328 | This is a driver for the SX and SI multiport serial cards. | 328 | This is a driver for the SX and SI multiport serial cards. |
| 329 | Please read the file <file:Documentation/serial/sx.txt> for details. | 329 | Please read the file <file:Documentation/serial/sx.txt> for details. |
| @@ -334,7 +334,7 @@ config SX | |||
| 334 | 334 | ||
| 335 | config RIO | 335 | config RIO |
| 336 | tristate "Specialix RIO system support" | 336 | tristate "Specialix RIO system support" |
| 337 | depends on SERIAL_NONSTANDARD | 337 | depends on SERIAL_NONSTANDARD && BROKEN |
| 338 | help | 338 | help |
| 339 | This is a driver for the Specialix RIO, a smart serial card which | 339 | This is a driver for the Specialix RIO, a smart serial card which |
| 340 | drives an outboard box that can support up to 128 ports. Product | 340 | drives an outboard box that can support up to 128 ports. Product |
| @@ -395,7 +395,7 @@ config NOZOMI | |||
| 395 | 395 | ||
| 396 | config A2232 | 396 | config A2232 |
| 397 | tristate "Commodore A2232 serial support (EXPERIMENTAL)" | 397 | tristate "Commodore A2232 serial support (EXPERIMENTAL)" |
| 398 | depends on EXPERIMENTAL && ZORRO && BROKEN_ON_SMP | 398 | depends on EXPERIMENTAL && ZORRO && BROKEN |
| 399 | ---help--- | 399 | ---help--- |
| 400 | This option supports the 2232 7-port serial card shipped with the | 400 | This option supports the 2232 7-port serial card shipped with the |
| 401 | Amiga 2000 and other Zorro-bus machines, dating from 1989. At | 401 | Amiga 2000 and other Zorro-bus machines, dating from 1989. At |
diff --git a/drivers/char/genrtc.c b/drivers/char/genrtc.c index aac0985a572b..31e7c91c2d9d 100644 --- a/drivers/char/genrtc.c +++ b/drivers/char/genrtc.c | |||
| @@ -43,6 +43,7 @@ | |||
| 43 | #define RTC_VERSION "1.07" | 43 | #define RTC_VERSION "1.07" |
| 44 | 44 | ||
| 45 | #include <linux/module.h> | 45 | #include <linux/module.h> |
| 46 | #include <linux/sched.h> | ||
| 46 | #include <linux/errno.h> | 47 | #include <linux/errno.h> |
| 47 | #include <linux/miscdevice.h> | 48 | #include <linux/miscdevice.h> |
| 48 | #include <linux/fcntl.h> | 49 | #include <linux/fcntl.h> |
diff --git a/drivers/char/hw_random/virtio-rng.c b/drivers/char/hw_random/virtio-rng.c index 962968f05b94..915157fcff98 100644 --- a/drivers/char/hw_random/virtio-rng.c +++ b/drivers/char/hw_random/virtio-rng.c | |||
| @@ -21,7 +21,6 @@ | |||
| 21 | #include <linux/scatterlist.h> | 21 | #include <linux/scatterlist.h> |
| 22 | #include <linux/spinlock.h> | 22 | #include <linux/spinlock.h> |
| 23 | #include <linux/virtio.h> | 23 | #include <linux/virtio.h> |
| 24 | #include <linux/virtio_ids.h> | ||
| 25 | #include <linux/virtio_rng.h> | 24 | #include <linux/virtio_rng.h> |
| 26 | 25 | ||
| 27 | /* The host will fill any buffer we give it with sweet, sweet randomness. We | 26 | /* The host will fill any buffer we give it with sweet, sweet randomness. We |
| @@ -117,7 +116,7 @@ static int virtrng_probe(struct virtio_device *vdev) | |||
| 117 | return 0; | 116 | return 0; |
| 118 | } | 117 | } |
| 119 | 118 | ||
| 120 | static void virtrng_remove(struct virtio_device *vdev) | 119 | static void __devexit virtrng_remove(struct virtio_device *vdev) |
| 121 | { | 120 | { |
| 122 | vdev->config->reset(vdev); | 121 | vdev->config->reset(vdev); |
| 123 | hwrng_unregister(&virtio_hwrng); | 122 | hwrng_unregister(&virtio_hwrng); |
diff --git a/drivers/char/rtc.c b/drivers/char/rtc.c index e0d0f8b2696b..bc4ab3e54550 100644 --- a/drivers/char/rtc.c +++ b/drivers/char/rtc.c | |||
| @@ -74,6 +74,7 @@ | |||
| 74 | #include <linux/proc_fs.h> | 74 | #include <linux/proc_fs.h> |
| 75 | #include <linux/seq_file.h> | 75 | #include <linux/seq_file.h> |
| 76 | #include <linux/spinlock.h> | 76 | #include <linux/spinlock.h> |
| 77 | #include <linux/sched.h> | ||
| 77 | #include <linux/sysctl.h> | 78 | #include <linux/sysctl.h> |
| 78 | #include <linux/wait.h> | 79 | #include <linux/wait.h> |
| 79 | #include <linux/bcd.h> | 80 | #include <linux/bcd.h> |
diff --git a/drivers/char/sonypi.c b/drivers/char/sonypi.c index fd3dced97776..8c262aaf7c26 100644 --- a/drivers/char/sonypi.c +++ b/drivers/char/sonypi.c | |||
| @@ -36,6 +36,7 @@ | |||
| 36 | */ | 36 | */ |
| 37 | 37 | ||
| 38 | #include <linux/module.h> | 38 | #include <linux/module.h> |
| 39 | #include <linux/sched.h> | ||
| 39 | #include <linux/input.h> | 40 | #include <linux/input.h> |
| 40 | #include <linux/pci.h> | 41 | #include <linux/pci.h> |
| 41 | #include <linux/init.h> | 42 | #include <linux/init.h> |
diff --git a/drivers/char/tty_buffer.c b/drivers/char/tty_buffer.c index 3108991c5c8b..66fa4e10d76b 100644 --- a/drivers/char/tty_buffer.c +++ b/drivers/char/tty_buffer.c | |||
| @@ -402,28 +402,26 @@ static void flush_to_ldisc(struct work_struct *work) | |||
| 402 | container_of(work, struct tty_struct, buf.work.work); | 402 | container_of(work, struct tty_struct, buf.work.work); |
| 403 | unsigned long flags; | 403 | unsigned long flags; |
| 404 | struct tty_ldisc *disc; | 404 | struct tty_ldisc *disc; |
| 405 | struct tty_buffer *tbuf, *head; | ||
| 406 | char *char_buf; | ||
| 407 | unsigned char *flag_buf; | ||
| 408 | 405 | ||
| 409 | disc = tty_ldisc_ref(tty); | 406 | disc = tty_ldisc_ref(tty); |
| 410 | if (disc == NULL) /* !TTY_LDISC */ | 407 | if (disc == NULL) /* !TTY_LDISC */ |
| 411 | return; | 408 | return; |
| 412 | 409 | ||
| 413 | spin_lock_irqsave(&tty->buf.lock, flags); | 410 | spin_lock_irqsave(&tty->buf.lock, flags); |
| 414 | /* So we know a flush is running */ | 411 | |
| 415 | set_bit(TTY_FLUSHING, &tty->flags); | 412 | if (!test_and_set_bit(TTY_FLUSHING, &tty->flags)) { |
| 416 | head = tty->buf.head; | 413 | struct tty_buffer *head; |
| 417 | if (head != NULL) { | 414 | while ((head = tty->buf.head) != NULL) { |
| 418 | tty->buf.head = NULL; | 415 | int count; |
| 419 | for (;;) { | 416 | char *char_buf; |
| 420 | int count = head->commit - head->read; | 417 | unsigned char *flag_buf; |
| 418 | |||
| 419 | count = head->commit - head->read; | ||
| 421 | if (!count) { | 420 | if (!count) { |
| 422 | if (head->next == NULL) | 421 | if (head->next == NULL) |
| 423 | break; | 422 | break; |
| 424 | tbuf = head; | 423 | tty->buf.head = head->next; |
| 425 | head = head->next; | 424 | tty_buffer_free(tty, head); |
| 426 | tty_buffer_free(tty, tbuf); | ||
| 427 | continue; | 425 | continue; |
| 428 | } | 426 | } |
| 429 | /* Ldisc or user is trying to flush the buffers | 427 | /* Ldisc or user is trying to flush the buffers |
| @@ -445,9 +443,9 @@ static void flush_to_ldisc(struct work_struct *work) | |||
| 445 | flag_buf, count); | 443 | flag_buf, count); |
| 446 | spin_lock_irqsave(&tty->buf.lock, flags); | 444 | spin_lock_irqsave(&tty->buf.lock, flags); |
| 447 | } | 445 | } |
| 448 | /* Restore the queue head */ | 446 | clear_bit(TTY_FLUSHING, &tty->flags); |
| 449 | tty->buf.head = head; | ||
| 450 | } | 447 | } |
| 448 | |||
| 451 | /* We may have a deferred request to flush the input buffer, | 449 | /* We may have a deferred request to flush the input buffer, |
| 452 | if so pull the chain under the lock and empty the queue */ | 450 | if so pull the chain under the lock and empty the queue */ |
| 453 | if (test_bit(TTY_FLUSHPENDING, &tty->flags)) { | 451 | if (test_bit(TTY_FLUSHPENDING, &tty->flags)) { |
| @@ -455,7 +453,6 @@ static void flush_to_ldisc(struct work_struct *work) | |||
| 455 | clear_bit(TTY_FLUSHPENDING, &tty->flags); | 453 | clear_bit(TTY_FLUSHPENDING, &tty->flags); |
| 456 | wake_up(&tty->read_wait); | 454 | wake_up(&tty->read_wait); |
| 457 | } | 455 | } |
| 458 | clear_bit(TTY_FLUSHING, &tty->flags); | ||
| 459 | spin_unlock_irqrestore(&tty->buf.lock, flags); | 456 | spin_unlock_irqrestore(&tty->buf.lock, flags); |
| 460 | 457 | ||
| 461 | tty_ldisc_deref(disc); | 458 | tty_ldisc_deref(disc); |
| @@ -471,7 +468,7 @@ static void flush_to_ldisc(struct work_struct *work) | |||
| 471 | */ | 468 | */ |
| 472 | void tty_flush_to_ldisc(struct tty_struct *tty) | 469 | void tty_flush_to_ldisc(struct tty_struct *tty) |
| 473 | { | 470 | { |
| 474 | flush_to_ldisc(&tty->buf.work.work); | 471 | flush_delayed_work(&tty->buf.work); |
| 475 | } | 472 | } |
| 476 | 473 | ||
| 477 | /** | 474 | /** |
diff --git a/drivers/char/virtio_console.c b/drivers/char/virtio_console.c index 0d328b59568d..a035ae39a359 100644 --- a/drivers/char/virtio_console.c +++ b/drivers/char/virtio_console.c | |||
| @@ -31,7 +31,6 @@ | |||
| 31 | #include <linux/err.h> | 31 | #include <linux/err.h> |
| 32 | #include <linux/init.h> | 32 | #include <linux/init.h> |
| 33 | #include <linux/virtio.h> | 33 | #include <linux/virtio.h> |
| 34 | #include <linux/virtio_ids.h> | ||
| 35 | #include <linux/virtio_console.h> | 34 | #include <linux/virtio_console.h> |
| 36 | #include "hvc_console.h" | 35 | #include "hvc_console.h" |
| 37 | 36 | ||
diff --git a/drivers/char/vt_ioctl.c b/drivers/char/vt_ioctl.c index 6b36ee56e6fe..ed86d3bf249a 100644 --- a/drivers/char/vt_ioctl.c +++ b/drivers/char/vt_ioctl.c | |||
| @@ -1532,7 +1532,7 @@ long vt_compat_ioctl(struct tty_struct *tty, struct file * file, | |||
| 1532 | 1532 | ||
| 1533 | case PIO_UNIMAP: | 1533 | case PIO_UNIMAP: |
| 1534 | case GIO_UNIMAP: | 1534 | case GIO_UNIMAP: |
| 1535 | ret = do_unimap_ioctl(cmd, up, perm, vc); | 1535 | ret = compat_unimap_ioctl(cmd, up, perm, vc); |
| 1536 | break; | 1536 | break; |
| 1537 | 1537 | ||
| 1538 | /* | 1538 | /* |
