diff options
Diffstat (limited to 'drivers/char')
-rw-r--r-- | drivers/char/agp/intel-agp.c | 19 | ||||
-rw-r--r-- | drivers/char/hvc_xen.c | 25 | ||||
-rw-r--r-- | drivers/char/keyboard.c | 2 | ||||
-rw-r--r-- | drivers/char/tty_port.c | 10 | ||||
-rw-r--r-- | drivers/char/vt_ioctl.c | 6 |
5 files changed, 48 insertions, 14 deletions
diff --git a/drivers/char/agp/intel-agp.c b/drivers/char/agp/intel-agp.c index 4068467ce7b9..3cb56a049e24 100644 --- a/drivers/char/agp/intel-agp.c +++ b/drivers/char/agp/intel-agp.c | |||
@@ -62,6 +62,7 @@ | |||
62 | #define PCI_DEVICE_ID_INTEL_IGDNG_D_IG 0x0042 | 62 | #define PCI_DEVICE_ID_INTEL_IGDNG_D_IG 0x0042 |
63 | #define PCI_DEVICE_ID_INTEL_IGDNG_M_HB 0x0044 | 63 | #define PCI_DEVICE_ID_INTEL_IGDNG_M_HB 0x0044 |
64 | #define PCI_DEVICE_ID_INTEL_IGDNG_MA_HB 0x0062 | 64 | #define PCI_DEVICE_ID_INTEL_IGDNG_MA_HB 0x0062 |
65 | #define PCI_DEVICE_ID_INTEL_IGDNG_MC2_HB 0x006a | ||
65 | #define PCI_DEVICE_ID_INTEL_IGDNG_M_IG 0x0046 | 66 | #define PCI_DEVICE_ID_INTEL_IGDNG_M_IG 0x0046 |
66 | 67 | ||
67 | /* cover 915 and 945 variants */ | 68 | /* cover 915 and 945 variants */ |
@@ -96,7 +97,8 @@ | |||
96 | agp_bridge->dev->device == PCI_DEVICE_ID_INTEL_B43_HB || \ | 97 | agp_bridge->dev->device == PCI_DEVICE_ID_INTEL_B43_HB || \ |
97 | agp_bridge->dev->device == PCI_DEVICE_ID_INTEL_IGDNG_D_HB || \ | 98 | agp_bridge->dev->device == PCI_DEVICE_ID_INTEL_IGDNG_D_HB || \ |
98 | agp_bridge->dev->device == PCI_DEVICE_ID_INTEL_IGDNG_M_HB || \ | 99 | agp_bridge->dev->device == PCI_DEVICE_ID_INTEL_IGDNG_M_HB || \ |
99 | agp_bridge->dev->device == PCI_DEVICE_ID_INTEL_IGDNG_MA_HB) | 100 | agp_bridge->dev->device == PCI_DEVICE_ID_INTEL_IGDNG_MA_HB || \ |
101 | agp_bridge->dev->device == PCI_DEVICE_ID_INTEL_IGDNG_MC2_HB) | ||
100 | 102 | ||
101 | extern int agp_memory_reserved; | 103 | extern int agp_memory_reserved; |
102 | 104 | ||
@@ -1161,12 +1163,6 @@ static int intel_i915_configure(void) | |||
1161 | 1163 | ||
1162 | intel_i9xx_setup_flush(); | 1164 | intel_i9xx_setup_flush(); |
1163 | 1165 | ||
1164 | #ifdef USE_PCI_DMA_API | ||
1165 | if (pci_set_dma_mask(intel_private.pcidev, DMA_BIT_MASK(36))) | ||
1166 | dev_err(&intel_private.pcidev->dev, | ||
1167 | "set gfx device dma mask 36bit failed!\n"); | ||
1168 | #endif | ||
1169 | |||
1170 | return 0; | 1166 | return 0; |
1171 | } | 1167 | } |
1172 | 1168 | ||
@@ -1364,6 +1360,7 @@ static void intel_i965_get_gtt_range(int *gtt_offset, int *gtt_size) | |||
1364 | case PCI_DEVICE_ID_INTEL_IGDNG_D_HB: | 1360 | case PCI_DEVICE_ID_INTEL_IGDNG_D_HB: |
1365 | case PCI_DEVICE_ID_INTEL_IGDNG_M_HB: | 1361 | case PCI_DEVICE_ID_INTEL_IGDNG_M_HB: |
1366 | case PCI_DEVICE_ID_INTEL_IGDNG_MA_HB: | 1362 | case PCI_DEVICE_ID_INTEL_IGDNG_MA_HB: |
1363 | case PCI_DEVICE_ID_INTEL_IGDNG_MC2_HB: | ||
1367 | *gtt_offset = *gtt_size = MB(2); | 1364 | *gtt_offset = *gtt_size = MB(2); |
1368 | break; | 1365 | break; |
1369 | default: | 1366 | default: |
@@ -2365,6 +2362,8 @@ static const struct intel_driver_description { | |||
2365 | "IGDNG/M", NULL, &intel_i965_driver }, | 2362 | "IGDNG/M", NULL, &intel_i965_driver }, |
2366 | { PCI_DEVICE_ID_INTEL_IGDNG_MA_HB, PCI_DEVICE_ID_INTEL_IGDNG_M_IG, 0, | 2363 | { PCI_DEVICE_ID_INTEL_IGDNG_MA_HB, PCI_DEVICE_ID_INTEL_IGDNG_M_IG, 0, |
2367 | "IGDNG/MA", NULL, &intel_i965_driver }, | 2364 | "IGDNG/MA", NULL, &intel_i965_driver }, |
2365 | { PCI_DEVICE_ID_INTEL_IGDNG_MC2_HB, PCI_DEVICE_ID_INTEL_IGDNG_M_IG, 0, | ||
2366 | "IGDNG/MC2", NULL, &intel_i965_driver }, | ||
2368 | { 0, 0, 0, NULL, NULL, NULL } | 2367 | { 0, 0, 0, NULL, NULL, NULL } |
2369 | }; | 2368 | }; |
2370 | 2369 | ||
@@ -2456,6 +2455,11 @@ static int __devinit agp_intel_probe(struct pci_dev *pdev, | |||
2456 | &bridge->mode); | 2455 | &bridge->mode); |
2457 | } | 2456 | } |
2458 | 2457 | ||
2458 | if (bridge->driver->mask_memory == intel_i965_mask_memory) | ||
2459 | if (pci_set_dma_mask(intel_private.pcidev, DMA_BIT_MASK(36))) | ||
2460 | dev_err(&intel_private.pcidev->dev, | ||
2461 | "set gfx device dma mask 36bit failed!\n"); | ||
2462 | |||
2459 | pci_set_drvdata(pdev, bridge); | 2463 | pci_set_drvdata(pdev, bridge); |
2460 | return agp_add_bridge(bridge); | 2464 | return agp_add_bridge(bridge); |
2461 | } | 2465 | } |
@@ -2561,6 +2565,7 @@ static struct pci_device_id agp_intel_pci_table[] = { | |||
2561 | ID(PCI_DEVICE_ID_INTEL_IGDNG_D_HB), | 2565 | ID(PCI_DEVICE_ID_INTEL_IGDNG_D_HB), |
2562 | ID(PCI_DEVICE_ID_INTEL_IGDNG_M_HB), | 2566 | ID(PCI_DEVICE_ID_INTEL_IGDNG_M_HB), |
2563 | ID(PCI_DEVICE_ID_INTEL_IGDNG_MA_HB), | 2567 | ID(PCI_DEVICE_ID_INTEL_IGDNG_MA_HB), |
2568 | ID(PCI_DEVICE_ID_INTEL_IGDNG_MC2_HB), | ||
2564 | { } | 2569 | { } |
2565 | }; | 2570 | }; |
2566 | 2571 | ||
diff --git a/drivers/char/hvc_xen.c b/drivers/char/hvc_xen.c index eba999f8598d..a6ee32b599a8 100644 --- a/drivers/char/hvc_xen.c +++ b/drivers/char/hvc_xen.c | |||
@@ -55,7 +55,7 @@ static inline void notify_daemon(void) | |||
55 | notify_remote_via_evtchn(xen_start_info->console.domU.evtchn); | 55 | notify_remote_via_evtchn(xen_start_info->console.domU.evtchn); |
56 | } | 56 | } |
57 | 57 | ||
58 | static int write_console(uint32_t vtermno, const char *data, int len) | 58 | static int __write_console(const char *data, int len) |
59 | { | 59 | { |
60 | struct xencons_interface *intf = xencons_interface(); | 60 | struct xencons_interface *intf = xencons_interface(); |
61 | XENCONS_RING_IDX cons, prod; | 61 | XENCONS_RING_IDX cons, prod; |
@@ -76,6 +76,29 @@ static int write_console(uint32_t vtermno, const char *data, int len) | |||
76 | return sent; | 76 | return sent; |
77 | } | 77 | } |
78 | 78 | ||
79 | static int write_console(uint32_t vtermno, const char *data, int len) | ||
80 | { | ||
81 | int ret = len; | ||
82 | |||
83 | /* | ||
84 | * Make sure the whole buffer is emitted, polling if | ||
85 | * necessary. We don't ever want to rely on the hvc daemon | ||
86 | * because the most interesting console output is when the | ||
87 | * kernel is crippled. | ||
88 | */ | ||
89 | while (len) { | ||
90 | int sent = __write_console(data, len); | ||
91 | |||
92 | data += sent; | ||
93 | len -= sent; | ||
94 | |||
95 | if (unlikely(len)) | ||
96 | HYPERVISOR_sched_op(SCHEDOP_yield, NULL); | ||
97 | } | ||
98 | |||
99 | return ret; | ||
100 | } | ||
101 | |||
79 | static int read_console(uint32_t vtermno, char *buf, int len) | 102 | static int read_console(uint32_t vtermno, char *buf, int len) |
80 | { | 103 | { |
81 | struct xencons_interface *intf = xencons_interface(); | 104 | struct xencons_interface *intf = xencons_interface(); |
diff --git a/drivers/char/keyboard.c b/drivers/char/keyboard.c index 737be953cc58..950837cf9e9c 100644 --- a/drivers/char/keyboard.c +++ b/drivers/char/keyboard.c | |||
@@ -1249,7 +1249,7 @@ static void kbd_keycode(unsigned int keycode, int down, int hw_raw) | |||
1249 | 1249 | ||
1250 | if (keycode >= NR_KEYS) | 1250 | if (keycode >= NR_KEYS) |
1251 | if (keycode >= KEY_BRL_DOT1 && keycode <= KEY_BRL_DOT8) | 1251 | if (keycode >= KEY_BRL_DOT1 && keycode <= KEY_BRL_DOT8) |
1252 | keysym = K(KT_BRL, keycode - KEY_BRL_DOT1 + 1); | 1252 | keysym = U(K(KT_BRL, keycode - KEY_BRL_DOT1 + 1)); |
1253 | else | 1253 | else |
1254 | return; | 1254 | return; |
1255 | else | 1255 | else |
diff --git a/drivers/char/tty_port.c b/drivers/char/tty_port.c index a4bbb28f10be..c63f3d33914a 100644 --- a/drivers/char/tty_port.c +++ b/drivers/char/tty_port.c | |||
@@ -219,8 +219,14 @@ int tty_port_block_til_ready(struct tty_port *port, | |||
219 | 219 | ||
220 | /* if non-blocking mode is set we can pass directly to open unless | 220 | /* if non-blocking mode is set we can pass directly to open unless |
221 | the port has just hung up or is in another error state */ | 221 | the port has just hung up or is in another error state */ |
222 | if ((filp->f_flags & O_NONBLOCK) || | 222 | if (tty->flags & (1 << TTY_IO_ERROR)) { |
223 | (tty->flags & (1 << TTY_IO_ERROR))) { | 223 | port->flags |= ASYNC_NORMAL_ACTIVE; |
224 | return 0; | ||
225 | } | ||
226 | if (filp->f_flags & O_NONBLOCK) { | ||
227 | /* Indicate we are open */ | ||
228 | if (tty->termios->c_cflag & CBAUD) | ||
229 | tty_port_raise_dtr_rts(port); | ||
224 | port->flags |= ASYNC_NORMAL_ACTIVE; | 230 | port->flags |= ASYNC_NORMAL_ACTIVE; |
225 | return 0; | 231 | return 0; |
226 | } | 232 | } |
diff --git a/drivers/char/vt_ioctl.c b/drivers/char/vt_ioctl.c index ed86d3bf249a..6aa10284104a 100644 --- a/drivers/char/vt_ioctl.c +++ b/drivers/char/vt_ioctl.c | |||
@@ -103,8 +103,8 @@ void vt_event_post(unsigned int event, unsigned int old, unsigned int new) | |||
103 | ve->event.event = event; | 103 | ve->event.event = event; |
104 | /* kernel view is consoles 0..n-1, user space view is | 104 | /* kernel view is consoles 0..n-1, user space view is |
105 | console 1..n with 0 meaning current, so we must bias */ | 105 | console 1..n with 0 meaning current, so we must bias */ |
106 | ve->event.old = old + 1; | 106 | ve->event.oldev = old + 1; |
107 | ve->event.new = new + 1; | 107 | ve->event.newev = new + 1; |
108 | wake = 1; | 108 | wake = 1; |
109 | ve->done = 1; | 109 | ve->done = 1; |
110 | } | 110 | } |
@@ -186,7 +186,7 @@ int vt_waitactive(int n) | |||
186 | vt_event_wait(&vw); | 186 | vt_event_wait(&vw); |
187 | if (vw.done == 0) | 187 | if (vw.done == 0) |
188 | return -EINTR; | 188 | return -EINTR; |
189 | } while (vw.event.new != n); | 189 | } while (vw.event.newev != n); |
190 | return 0; | 190 | return 0; |
191 | } | 191 | } |
192 | 192 | ||