diff options
Diffstat (limited to 'drivers/gpu')
30 files changed, 57 insertions, 44 deletions
diff --git a/drivers/gpu/drm/Kconfig b/drivers/gpu/drm/Kconfig index 4cab0c6397e..7af44367262 100644 --- a/drivers/gpu/drm/Kconfig +++ b/drivers/gpu/drm/Kconfig | |||
@@ -73,7 +73,8 @@ source "drivers/gpu/drm/radeon/Kconfig" | |||
73 | 73 | ||
74 | config DRM_I810 | 74 | config DRM_I810 |
75 | tristate "Intel I810" | 75 | tristate "Intel I810" |
76 | depends on DRM && AGP && AGP_INTEL | 76 | # BKL usage in order to avoid AB-BA deadlocks, may become BROKEN_ON_SMP |
77 | depends on DRM && AGP && AGP_INTEL && BKL | ||
77 | help | 78 | help |
78 | Choose this option if you have an Intel I810 graphics card. If M is | 79 | Choose this option if you have an Intel I810 graphics card. If M is |
79 | selected, the module will be called i810. AGP support is required | 80 | selected, the module will be called i810. AGP support is required |
@@ -86,6 +87,8 @@ choice | |||
86 | 87 | ||
87 | config DRM_I830 | 88 | config DRM_I830 |
88 | tristate "i830 driver" | 89 | tristate "i830 driver" |
90 | # BKL usage in order to avoid AB-BA deadlocks, i830 may get removed | ||
91 | depends on BKL | ||
89 | help | 92 | help |
90 | Choose this option if you have a system that has Intel 830M, 845G, | 93 | Choose this option if you have a system that has Intel 830M, 845G, |
91 | 852GM, 855GM or 865G integrated graphics. If M is selected, the | 94 | 852GM, 855GM or 865G integrated graphics. If M is selected, the |
diff --git a/drivers/gpu/drm/drm_drv.c b/drivers/gpu/drm/drm_drv.c index 5ff75a3a6b9..271835a7157 100644 --- a/drivers/gpu/drm/drm_drv.c +++ b/drivers/gpu/drm/drm_drv.c | |||
@@ -280,7 +280,8 @@ EXPORT_SYMBOL(drm_exit); | |||
280 | /** File operations structure */ | 280 | /** File operations structure */ |
281 | static const struct file_operations drm_stub_fops = { | 281 | static const struct file_operations drm_stub_fops = { |
282 | .owner = THIS_MODULE, | 282 | .owner = THIS_MODULE, |
283 | .open = drm_stub_open | 283 | .open = drm_stub_open, |
284 | .llseek = noop_llseek, | ||
284 | }; | 285 | }; |
285 | 286 | ||
286 | static int __init drm_core_init(void) | 287 | static int __init drm_core_init(void) |
diff --git a/drivers/gpu/drm/drm_modes.c b/drivers/gpu/drm/drm_modes.c index 949326d2a8e..58e65f92c23 100644 --- a/drivers/gpu/drm/drm_modes.c +++ b/drivers/gpu/drm/drm_modes.c | |||
@@ -76,7 +76,7 @@ EXPORT_SYMBOL(drm_mode_debug_printmodeline); | |||
76 | * according to the hdisplay, vdisplay, vrefresh. | 76 | * according to the hdisplay, vdisplay, vrefresh. |
77 | * It is based from the VESA(TM) Coordinated Video Timing Generator by | 77 | * It is based from the VESA(TM) Coordinated Video Timing Generator by |
78 | * Graham Loveridge April 9, 2003 available at | 78 | * Graham Loveridge April 9, 2003 available at |
79 | * http://www.vesa.org/public/CVT/CVTd6r1.xls | 79 | * http://www.elo.utfsm.cl/~elo212/docs/CVTd6r1.xls |
80 | * | 80 | * |
81 | * And it is copied from xf86CVTmode in xserver/hw/xfree86/modes/xf86cvt.c. | 81 | * And it is copied from xf86CVTmode in xserver/hw/xfree86/modes/xf86cvt.c. |
82 | * What I have done is to translate it by using integer calculation. | 82 | * What I have done is to translate it by using integer calculation. |
diff --git a/drivers/gpu/drm/i810/i810_dma.c b/drivers/gpu/drm/i810/i810_dma.c index fb07e73581e..ff33e53bbbf 100644 --- a/drivers/gpu/drm/i810/i810_dma.c +++ b/drivers/gpu/drm/i810/i810_dma.c | |||
@@ -119,6 +119,7 @@ static const struct file_operations i810_buffer_fops = { | |||
119 | .unlocked_ioctl = i810_ioctl, | 119 | .unlocked_ioctl = i810_ioctl, |
120 | .mmap = i810_mmap_buffers, | 120 | .mmap = i810_mmap_buffers, |
121 | .fasync = drm_fasync, | 121 | .fasync = drm_fasync, |
122 | .llseek = noop_llseek, | ||
122 | }; | 123 | }; |
123 | 124 | ||
124 | static int i810_map_buffer(struct drm_buf *buf, struct drm_file *file_priv) | 125 | static int i810_map_buffer(struct drm_buf *buf, struct drm_file *file_priv) |
diff --git a/drivers/gpu/drm/i810/i810_drv.c b/drivers/gpu/drm/i810/i810_drv.c index 1c73b0c43c1..88bcd331e7c 100644 --- a/drivers/gpu/drm/i810/i810_drv.c +++ b/drivers/gpu/drm/i810/i810_drv.c | |||
@@ -61,6 +61,7 @@ static struct drm_driver driver = { | |||
61 | .mmap = drm_mmap, | 61 | .mmap = drm_mmap, |
62 | .poll = drm_poll, | 62 | .poll = drm_poll, |
63 | .fasync = drm_fasync, | 63 | .fasync = drm_fasync, |
64 | .llseek = noop_llseek, | ||
64 | }, | 65 | }, |
65 | 66 | ||
66 | .pci_driver = { | 67 | .pci_driver = { |
diff --git a/drivers/gpu/drm/i830/i830_dma.c b/drivers/gpu/drm/i830/i830_dma.c index cc92c7e6236..ca6f31ff0ee 100644 --- a/drivers/gpu/drm/i830/i830_dma.c +++ b/drivers/gpu/drm/i830/i830_dma.c | |||
@@ -121,6 +121,7 @@ static const struct file_operations i830_buffer_fops = { | |||
121 | .unlocked_ioctl = i830_ioctl, | 121 | .unlocked_ioctl = i830_ioctl, |
122 | .mmap = i830_mmap_buffers, | 122 | .mmap = i830_mmap_buffers, |
123 | .fasync = drm_fasync, | 123 | .fasync = drm_fasync, |
124 | .llseek = noop_llseek, | ||
124 | }; | 125 | }; |
125 | 126 | ||
126 | static int i830_map_buffer(struct drm_buf *buf, struct drm_file *file_priv) | 127 | static int i830_map_buffer(struct drm_buf *buf, struct drm_file *file_priv) |
diff --git a/drivers/gpu/drm/i830/i830_drv.c b/drivers/gpu/drm/i830/i830_drv.c index 7140ffc12ee..f655ab7977d 100644 --- a/drivers/gpu/drm/i830/i830_drv.c +++ b/drivers/gpu/drm/i830/i830_drv.c | |||
@@ -72,6 +72,7 @@ static struct drm_driver driver = { | |||
72 | .mmap = drm_mmap, | 72 | .mmap = drm_mmap, |
73 | .poll = drm_poll, | 73 | .poll = drm_poll, |
74 | .fasync = drm_fasync, | 74 | .fasync = drm_fasync, |
75 | .llseek = noop_llseek, | ||
75 | }, | 76 | }, |
76 | 77 | ||
77 | .pci_driver = { | 78 | .pci_driver = { |
diff --git a/drivers/gpu/drm/i915/i915_debugfs.c b/drivers/gpu/drm/i915/i915_debugfs.c index 7698983577d..1f4f3ceb63c 100644 --- a/drivers/gpu/drm/i915/i915_debugfs.c +++ b/drivers/gpu/drm/i915/i915_debugfs.c | |||
@@ -974,6 +974,7 @@ static const struct file_operations i915_wedged_fops = { | |||
974 | .open = i915_wedged_open, | 974 | .open = i915_wedged_open, |
975 | .read = i915_wedged_read, | 975 | .read = i915_wedged_read, |
976 | .write = i915_wedged_write, | 976 | .write = i915_wedged_write, |
977 | .llseek = default_llseek, | ||
977 | }; | 978 | }; |
978 | 979 | ||
979 | /* As the drm_debugfs_init() routines are called before dev->dev_private is | 980 | /* As the drm_debugfs_init() routines are called before dev->dev_private is |
diff --git a/drivers/gpu/drm/i915/i915_drv.c b/drivers/gpu/drm/i915/i915_drv.c index 8e632110c58..3467dd42076 100644 --- a/drivers/gpu/drm/i915/i915_drv.c +++ b/drivers/gpu/drm/i915/i915_drv.c | |||
@@ -632,6 +632,7 @@ static struct drm_driver driver = { | |||
632 | #ifdef CONFIG_COMPAT | 632 | #ifdef CONFIG_COMPAT |
633 | .compat_ioctl = i915_compat_ioctl, | 633 | .compat_ioctl = i915_compat_ioctl, |
634 | #endif | 634 | #endif |
635 | .llseek = noop_llseek, | ||
635 | }, | 636 | }, |
636 | 637 | ||
637 | .pci_driver = { | 638 | .pci_driver = { |
diff --git a/drivers/gpu/drm/i915/i915_gem.c b/drivers/gpu/drm/i915/i915_gem.c index 6c2618d884e..8eb8453208b 100644 --- a/drivers/gpu/drm/i915/i915_gem.c +++ b/drivers/gpu/drm/i915/i915_gem.c | |||
@@ -268,9 +268,9 @@ fast_shmem_read(struct page **pages, | |||
268 | char *vaddr; | 268 | char *vaddr; |
269 | int ret; | 269 | int ret; |
270 | 270 | ||
271 | vaddr = kmap_atomic(pages[page_base >> PAGE_SHIFT], KM_USER0); | 271 | vaddr = kmap_atomic(pages[page_base >> PAGE_SHIFT]); |
272 | ret = __copy_to_user_inatomic(data, vaddr + page_offset, length); | 272 | ret = __copy_to_user_inatomic(data, vaddr + page_offset, length); |
273 | kunmap_atomic(vaddr, KM_USER0); | 273 | kunmap_atomic(vaddr); |
274 | 274 | ||
275 | return ret; | 275 | return ret; |
276 | } | 276 | } |
@@ -619,10 +619,10 @@ fast_user_write(struct io_mapping *mapping, | |||
619 | char *vaddr_atomic; | 619 | char *vaddr_atomic; |
620 | unsigned long unwritten; | 620 | unsigned long unwritten; |
621 | 621 | ||
622 | vaddr_atomic = io_mapping_map_atomic_wc(mapping, page_base, KM_USER0); | 622 | vaddr_atomic = io_mapping_map_atomic_wc(mapping, page_base); |
623 | unwritten = __copy_from_user_inatomic_nocache(vaddr_atomic + page_offset, | 623 | unwritten = __copy_from_user_inatomic_nocache(vaddr_atomic + page_offset, |
624 | user_data, length); | 624 | user_data, length); |
625 | io_mapping_unmap_atomic(vaddr_atomic, KM_USER0); | 625 | io_mapping_unmap_atomic(vaddr_atomic); |
626 | return unwritten; | 626 | return unwritten; |
627 | } | 627 | } |
628 | 628 | ||
@@ -659,9 +659,9 @@ fast_shmem_write(struct page **pages, | |||
659 | char *vaddr; | 659 | char *vaddr; |
660 | int ret; | 660 | int ret; |
661 | 661 | ||
662 | vaddr = kmap_atomic(pages[page_base >> PAGE_SHIFT], KM_USER0); | 662 | vaddr = kmap_atomic(pages[page_base >> PAGE_SHIFT]); |
663 | ret = __copy_from_user_inatomic(vaddr + page_offset, data, length); | 663 | ret = __copy_from_user_inatomic(vaddr + page_offset, data, length); |
664 | kunmap_atomic(vaddr, KM_USER0); | 664 | kunmap_atomic(vaddr); |
665 | 665 | ||
666 | return ret; | 666 | return ret; |
667 | } | 667 | } |
@@ -3395,9 +3395,9 @@ i915_gem_execbuffer_relocate(struct drm_i915_gem_object *obj, | |||
3395 | uint32_t page_offset = reloc.offset & ~PAGE_MASK; | 3395 | uint32_t page_offset = reloc.offset & ~PAGE_MASK; |
3396 | char *vaddr; | 3396 | char *vaddr; |
3397 | 3397 | ||
3398 | vaddr = kmap_atomic(obj->pages[reloc.offset >> PAGE_SHIFT], KM_USER0); | 3398 | vaddr = kmap_atomic(obj->pages[reloc.offset >> PAGE_SHIFT]); |
3399 | *(uint32_t *)(vaddr + page_offset) = reloc.delta; | 3399 | *(uint32_t *)(vaddr + page_offset) = reloc.delta; |
3400 | kunmap_atomic(vaddr, KM_USER0); | 3400 | kunmap_atomic(vaddr); |
3401 | } else { | 3401 | } else { |
3402 | uint32_t __iomem *reloc_entry; | 3402 | uint32_t __iomem *reloc_entry; |
3403 | void __iomem *reloc_page; | 3403 | void __iomem *reloc_page; |
@@ -3409,12 +3409,11 @@ i915_gem_execbuffer_relocate(struct drm_i915_gem_object *obj, | |||
3409 | /* Map the page containing the relocation we're going to perform. */ | 3409 | /* Map the page containing the relocation we're going to perform. */ |
3410 | reloc.offset += obj->gtt_offset; | 3410 | reloc.offset += obj->gtt_offset; |
3411 | reloc_page = io_mapping_map_atomic_wc(dev_priv->mm.gtt_mapping, | 3411 | reloc_page = io_mapping_map_atomic_wc(dev_priv->mm.gtt_mapping, |
3412 | reloc.offset & PAGE_MASK, | 3412 | reloc.offset & PAGE_MASK); |
3413 | KM_USER0); | ||
3414 | reloc_entry = (uint32_t __iomem *) | 3413 | reloc_entry = (uint32_t __iomem *) |
3415 | (reloc_page + (reloc.offset & ~PAGE_MASK)); | 3414 | (reloc_page + (reloc.offset & ~PAGE_MASK)); |
3416 | iowrite32(reloc.delta, reloc_entry); | 3415 | iowrite32(reloc.delta, reloc_entry); |
3417 | io_mapping_unmap_atomic(reloc_page, KM_USER0); | 3416 | io_mapping_unmap_atomic(reloc_page); |
3418 | } | 3417 | } |
3419 | 3418 | ||
3420 | /* and update the user's relocation entry */ | 3419 | /* and update the user's relocation entry */ |
@@ -4776,11 +4775,11 @@ void i915_gem_detach_phys_object(struct drm_device *dev, | |||
4776 | page_count = obj->size / PAGE_SIZE; | 4775 | page_count = obj->size / PAGE_SIZE; |
4777 | 4776 | ||
4778 | for (i = 0; i < page_count; i++) { | 4777 | for (i = 0; i < page_count; i++) { |
4779 | char *dst = kmap_atomic(obj_priv->pages[i], KM_USER0); | 4778 | char *dst = kmap_atomic(obj_priv->pages[i]); |
4780 | char *src = obj_priv->phys_obj->handle->vaddr + (i * PAGE_SIZE); | 4779 | char *src = obj_priv->phys_obj->handle->vaddr + (i * PAGE_SIZE); |
4781 | 4780 | ||
4782 | memcpy(dst, src, PAGE_SIZE); | 4781 | memcpy(dst, src, PAGE_SIZE); |
4783 | kunmap_atomic(dst, KM_USER0); | 4782 | kunmap_atomic(dst); |
4784 | } | 4783 | } |
4785 | drm_clflush_pages(obj_priv->pages, page_count); | 4784 | drm_clflush_pages(obj_priv->pages, page_count); |
4786 | drm_agp_chipset_flush(dev); | 4785 | drm_agp_chipset_flush(dev); |
@@ -4837,11 +4836,11 @@ i915_gem_attach_phys_object(struct drm_device *dev, | |||
4837 | page_count = obj->size / PAGE_SIZE; | 4836 | page_count = obj->size / PAGE_SIZE; |
4838 | 4837 | ||
4839 | for (i = 0; i < page_count; i++) { | 4838 | for (i = 0; i < page_count; i++) { |
4840 | char *src = kmap_atomic(obj_priv->pages[i], KM_USER0); | 4839 | char *src = kmap_atomic(obj_priv->pages[i]); |
4841 | char *dst = obj_priv->phys_obj->handle->vaddr + (i * PAGE_SIZE); | 4840 | char *dst = obj_priv->phys_obj->handle->vaddr + (i * PAGE_SIZE); |
4842 | 4841 | ||
4843 | memcpy(dst, src, PAGE_SIZE); | 4842 | memcpy(dst, src, PAGE_SIZE); |
4844 | kunmap_atomic(src, KM_USER0); | 4843 | kunmap_atomic(src); |
4845 | } | 4844 | } |
4846 | 4845 | ||
4847 | i915_gem_object_put_pages(obj); | 4846 | i915_gem_object_put_pages(obj); |
diff --git a/drivers/gpu/drm/i915/i915_irq.c b/drivers/gpu/drm/i915/i915_irq.c index 237b8bdb599..729fd0c91d7 100644 --- a/drivers/gpu/drm/i915/i915_irq.c +++ b/drivers/gpu/drm/i915/i915_irq.c | |||
@@ -456,10 +456,9 @@ i915_error_object_create(struct drm_device *dev, | |||
456 | 456 | ||
457 | local_irq_save(flags); | 457 | local_irq_save(flags); |
458 | s = io_mapping_map_atomic_wc(dev_priv->mm.gtt_mapping, | 458 | s = io_mapping_map_atomic_wc(dev_priv->mm.gtt_mapping, |
459 | reloc_offset, | 459 | reloc_offset); |
460 | KM_IRQ0); | ||
461 | memcpy_fromio(d, s, PAGE_SIZE); | 460 | memcpy_fromio(d, s, PAGE_SIZE); |
462 | io_mapping_unmap_atomic(s, KM_IRQ0); | 461 | io_mapping_unmap_atomic(s); |
463 | local_irq_restore(flags); | 462 | local_irq_restore(flags); |
464 | 463 | ||
465 | dst->pages[page] = d; | 464 | dst->pages[page] = d; |
diff --git a/drivers/gpu/drm/i915/intel_overlay.c b/drivers/gpu/drm/i915/intel_overlay.c index 375316a8420..afb96d25219 100644 --- a/drivers/gpu/drm/i915/intel_overlay.c +++ b/drivers/gpu/drm/i915/intel_overlay.c | |||
@@ -1465,28 +1465,25 @@ struct intel_overlay_error_state { | |||
1465 | }; | 1465 | }; |
1466 | 1466 | ||
1467 | static struct overlay_registers * | 1467 | static struct overlay_registers * |
1468 | intel_overlay_map_regs_atomic(struct intel_overlay *overlay, | 1468 | intel_overlay_map_regs_atomic(struct intel_overlay *overlay) |
1469 | int slot) | ||
1470 | { | 1469 | { |
1471 | drm_i915_private_t *dev_priv = overlay->dev->dev_private; | 1470 | drm_i915_private_t *dev_priv = overlay->dev->dev_private; |
1472 | struct overlay_registers *regs; | 1471 | struct overlay_registers *regs; |
1473 | 1472 | ||
1474 | if (OVERLAY_NEEDS_PHYSICAL(overlay->dev)) | 1473 | if (OVERLAY_NEEDS_PHYSICAL(overlay->dev)) |
1475 | regs = overlay->reg_bo->phys_obj->handle->vaddr; | 1474 | regs = overlay->reg_bo->phys_obj->handle->vaddr; |
1476 | else | 1475 | else |
1477 | regs = io_mapping_map_atomic_wc(dev_priv->mm.gtt_mapping, | 1476 | regs = io_mapping_map_atomic_wc(dev_priv->mm.gtt_mapping, |
1478 | overlay->reg_bo->gtt_offset, | 1477 | overlay->reg_bo->gtt_offset); |
1479 | slot); | ||
1480 | 1478 | ||
1481 | return regs; | 1479 | return regs; |
1482 | } | 1480 | } |
1483 | 1481 | ||
1484 | static void intel_overlay_unmap_regs_atomic(struct intel_overlay *overlay, | 1482 | static void intel_overlay_unmap_regs_atomic(struct intel_overlay *overlay, |
1485 | int slot, | ||
1486 | struct overlay_registers *regs) | 1483 | struct overlay_registers *regs) |
1487 | { | 1484 | { |
1488 | if (!OVERLAY_NEEDS_PHYSICAL(overlay->dev)) | 1485 | if (!OVERLAY_NEEDS_PHYSICAL(overlay->dev)) |
1489 | io_mapping_unmap_atomic(regs, slot); | 1486 | io_mapping_unmap_atomic(regs); |
1490 | } | 1487 | } |
1491 | 1488 | ||
1492 | 1489 | ||
@@ -1512,12 +1509,12 @@ intel_overlay_capture_error_state(struct drm_device *dev) | |||
1512 | else | 1509 | else |
1513 | error->base = (long) overlay->reg_bo->gtt_offset; | 1510 | error->base = (long) overlay->reg_bo->gtt_offset; |
1514 | 1511 | ||
1515 | regs = intel_overlay_map_regs_atomic(overlay, KM_IRQ0); | 1512 | regs = intel_overlay_map_regs_atomic(overlay); |
1516 | if (!regs) | 1513 | if (!regs) |
1517 | goto err; | 1514 | goto err; |
1518 | 1515 | ||
1519 | memcpy_fromio(&error->regs, regs, sizeof(struct overlay_registers)); | 1516 | memcpy_fromio(&error->regs, regs, sizeof(struct overlay_registers)); |
1520 | intel_overlay_unmap_regs_atomic(overlay, KM_IRQ0, regs); | 1517 | intel_overlay_unmap_regs_atomic(overlay, regs); |
1521 | 1518 | ||
1522 | return error; | 1519 | return error; |
1523 | 1520 | ||
diff --git a/drivers/gpu/drm/mga/mga_drv.c b/drivers/gpu/drm/mga/mga_drv.c index 65ea42cf179..0aaf5f67a43 100644 --- a/drivers/gpu/drm/mga/mga_drv.c +++ b/drivers/gpu/drm/mga/mga_drv.c | |||
@@ -73,6 +73,7 @@ static struct drm_driver driver = { | |||
73 | #ifdef CONFIG_COMPAT | 73 | #ifdef CONFIG_COMPAT |
74 | .compat_ioctl = mga_compat_ioctl, | 74 | .compat_ioctl = mga_compat_ioctl, |
75 | #endif | 75 | #endif |
76 | .llseek = noop_llseek, | ||
76 | }, | 77 | }, |
77 | .pci_driver = { | 78 | .pci_driver = { |
78 | .name = DRIVER_NAME, | 79 | .name = DRIVER_NAME, |
diff --git a/drivers/gpu/drm/nouveau/nouveau_bios.c b/drivers/gpu/drm/nouveau/nouveau_bios.c index 53f4eba65cb..5f21030a293 100644 --- a/drivers/gpu/drm/nouveau/nouveau_bios.c +++ b/drivers/gpu/drm/nouveau/nouveau_bios.c | |||
@@ -2158,11 +2158,11 @@ peek_fb(struct drm_device *dev, struct io_mapping *fb, | |||
2158 | 2158 | ||
2159 | if (off < pci_resource_len(dev->pdev, 1)) { | 2159 | if (off < pci_resource_len(dev->pdev, 1)) { |
2160 | uint8_t __iomem *p = | 2160 | uint8_t __iomem *p = |
2161 | io_mapping_map_atomic_wc(fb, off & PAGE_MASK, KM_USER0); | 2161 | io_mapping_map_atomic_wc(fb, off & PAGE_MASK); |
2162 | 2162 | ||
2163 | val = ioread32(p + (off & ~PAGE_MASK)); | 2163 | val = ioread32(p + (off & ~PAGE_MASK)); |
2164 | 2164 | ||
2165 | io_mapping_unmap_atomic(p, KM_USER0); | 2165 | io_mapping_unmap_atomic(p); |
2166 | } | 2166 | } |
2167 | 2167 | ||
2168 | return val; | 2168 | return val; |
@@ -2174,12 +2174,12 @@ poke_fb(struct drm_device *dev, struct io_mapping *fb, | |||
2174 | { | 2174 | { |
2175 | if (off < pci_resource_len(dev->pdev, 1)) { | 2175 | if (off < pci_resource_len(dev->pdev, 1)) { |
2176 | uint8_t __iomem *p = | 2176 | uint8_t __iomem *p = |
2177 | io_mapping_map_atomic_wc(fb, off & PAGE_MASK, KM_USER0); | 2177 | io_mapping_map_atomic_wc(fb, off & PAGE_MASK); |
2178 | 2178 | ||
2179 | iowrite32(val, p + (off & ~PAGE_MASK)); | 2179 | iowrite32(val, p + (off & ~PAGE_MASK)); |
2180 | wmb(); | 2180 | wmb(); |
2181 | 2181 | ||
2182 | io_mapping_unmap_atomic(p, KM_USER0); | 2182 | io_mapping_unmap_atomic(p); |
2183 | } | 2183 | } |
2184 | } | 2184 | } |
2185 | 2185 | ||
diff --git a/drivers/gpu/drm/nouveau/nouveau_drv.c b/drivers/gpu/drm/nouveau/nouveau_drv.c index edc4a9ab28d..90875494a65 100644 --- a/drivers/gpu/drm/nouveau/nouveau_drv.c +++ b/drivers/gpu/drm/nouveau/nouveau_drv.c | |||
@@ -406,6 +406,7 @@ static struct drm_driver driver = { | |||
406 | #if defined(CONFIG_COMPAT) | 406 | #if defined(CONFIG_COMPAT) |
407 | .compat_ioctl = nouveau_compat_ioctl, | 407 | .compat_ioctl = nouveau_compat_ioctl, |
408 | #endif | 408 | #endif |
409 | .llseek = noop_llseek, | ||
409 | }, | 410 | }, |
410 | .pci_driver = { | 411 | .pci_driver = { |
411 | .name = DRIVER_NAME, | 412 | .name = DRIVER_NAME, |
diff --git a/drivers/gpu/drm/nouveau/nouveau_i2c.h b/drivers/gpu/drm/nouveau/nouveau_i2c.h index c77a6ba66b7..422b62fd827 100644 --- a/drivers/gpu/drm/nouveau/nouveau_i2c.h +++ b/drivers/gpu/drm/nouveau/nouveau_i2c.h | |||
@@ -24,7 +24,6 @@ | |||
24 | #define __NOUVEAU_I2C_H__ | 24 | #define __NOUVEAU_I2C_H__ |
25 | 25 | ||
26 | #include <linux/i2c.h> | 26 | #include <linux/i2c.h> |
27 | #include <linux/i2c-id.h> | ||
28 | #include <linux/i2c-algo-bit.h> | 27 | #include <linux/i2c-algo-bit.h> |
29 | #include "drm_dp_helper.h" | 28 | #include "drm_dp_helper.h" |
30 | 29 | ||
diff --git a/drivers/gpu/drm/r128/r128_drv.c b/drivers/gpu/drm/r128/r128_drv.c index 67309f84f16..18c3c71e41b 100644 --- a/drivers/gpu/drm/r128/r128_drv.c +++ b/drivers/gpu/drm/r128/r128_drv.c | |||
@@ -69,6 +69,7 @@ static struct drm_driver driver = { | |||
69 | #ifdef CONFIG_COMPAT | 69 | #ifdef CONFIG_COMPAT |
70 | .compat_ioctl = r128_compat_ioctl, | 70 | .compat_ioctl = r128_compat_ioctl, |
71 | #endif | 71 | #endif |
72 | .llseek = noop_llseek, | ||
72 | }, | 73 | }, |
73 | .pci_driver = { | 74 | .pci_driver = { |
74 | .name = DRIVER_NAME, | 75 | .name = DRIVER_NAME, |
diff --git a/drivers/gpu/drm/radeon/radeon_cs.c b/drivers/gpu/drm/radeon/radeon_cs.c index fcc79b5d22d..6d64a2705f1 100644 --- a/drivers/gpu/drm/radeon/radeon_cs.c +++ b/drivers/gpu/drm/radeon/radeon_cs.c | |||
@@ -268,7 +268,7 @@ int radeon_cs_ioctl(struct drm_device *dev, void *data, struct drm_file *filp) | |||
268 | } | 268 | } |
269 | r = radeon_ib_schedule(rdev, parser.ib); | 269 | r = radeon_ib_schedule(rdev, parser.ib); |
270 | if (r) { | 270 | if (r) { |
271 | DRM_ERROR("Faild to schedule IB !\n"); | 271 | DRM_ERROR("Failed to schedule IB !\n"); |
272 | } | 272 | } |
273 | radeon_cs_parser_fini(&parser, r); | 273 | radeon_cs_parser_fini(&parser, r); |
274 | mutex_unlock(&rdev->cs_mutex); | 274 | mutex_unlock(&rdev->cs_mutex); |
diff --git a/drivers/gpu/drm/radeon/radeon_drv.c b/drivers/gpu/drm/radeon/radeon_drv.c index c20669b9a6a..88e4ea92590 100644 --- a/drivers/gpu/drm/radeon/radeon_drv.c +++ b/drivers/gpu/drm/radeon/radeon_drv.c | |||
@@ -214,6 +214,7 @@ static struct drm_driver driver_old = { | |||
214 | #ifdef CONFIG_COMPAT | 214 | #ifdef CONFIG_COMPAT |
215 | .compat_ioctl = radeon_compat_ioctl, | 215 | .compat_ioctl = radeon_compat_ioctl, |
216 | #endif | 216 | #endif |
217 | .llseek = noop_llseek, | ||
217 | }, | 218 | }, |
218 | 219 | ||
219 | .pci_driver = { | 220 | .pci_driver = { |
diff --git a/drivers/gpu/drm/radeon/radeon_mode.h b/drivers/gpu/drm/radeon/radeon_mode.h index 61b9243db21..92457163d07 100644 --- a/drivers/gpu/drm/radeon/radeon_mode.h +++ b/drivers/gpu/drm/radeon/radeon_mode.h | |||
@@ -37,7 +37,6 @@ | |||
37 | #include <drm_fixed.h> | 37 | #include <drm_fixed.h> |
38 | #include <drm_crtc_helper.h> | 38 | #include <drm_crtc_helper.h> |
39 | #include <linux/i2c.h> | 39 | #include <linux/i2c.h> |
40 | #include <linux/i2c-id.h> | ||
41 | #include <linux/i2c-algo-bit.h> | 40 | #include <linux/i2c-algo-bit.h> |
42 | 41 | ||
43 | struct radeon_bo; | 42 | struct radeon_bo; |
diff --git a/drivers/gpu/drm/radeon/radeon_ttm.c b/drivers/gpu/drm/radeon/radeon_ttm.c index 0921910698d..fe95bb35317 100644 --- a/drivers/gpu/drm/radeon/radeon_ttm.c +++ b/drivers/gpu/drm/radeon/radeon_ttm.c | |||
@@ -619,7 +619,7 @@ int radeon_mmap(struct file *filp, struct vm_area_struct *vma) | |||
619 | return drm_mmap(filp, vma); | 619 | return drm_mmap(filp, vma); |
620 | } | 620 | } |
621 | 621 | ||
622 | file_priv = (struct drm_file *)filp->private_data; | 622 | file_priv = filp->private_data; |
623 | rdev = file_priv->minor->dev->dev_private; | 623 | rdev = file_priv->minor->dev->dev_private; |
624 | if (rdev == NULL) { | 624 | if (rdev == NULL) { |
625 | return -EINVAL; | 625 | return -EINVAL; |
diff --git a/drivers/gpu/drm/savage/savage_drv.c b/drivers/gpu/drm/savage/savage_drv.c index c0385633667..fa64d25d424 100644 --- a/drivers/gpu/drm/savage/savage_drv.c +++ b/drivers/gpu/drm/savage/savage_drv.c | |||
@@ -52,6 +52,7 @@ static struct drm_driver driver = { | |||
52 | .mmap = drm_mmap, | 52 | .mmap = drm_mmap, |
53 | .poll = drm_poll, | 53 | .poll = drm_poll, |
54 | .fasync = drm_fasync, | 54 | .fasync = drm_fasync, |
55 | .llseek = noop_llseek, | ||
55 | }, | 56 | }, |
56 | 57 | ||
57 | .pci_driver = { | 58 | .pci_driver = { |
diff --git a/drivers/gpu/drm/sis/sis_drv.c b/drivers/gpu/drm/sis/sis_drv.c index 4d9f311d249..4caf5d01cfd 100644 --- a/drivers/gpu/drm/sis/sis_drv.c +++ b/drivers/gpu/drm/sis/sis_drv.c | |||
@@ -80,6 +80,7 @@ static struct drm_driver driver = { | |||
80 | .mmap = drm_mmap, | 80 | .mmap = drm_mmap, |
81 | .poll = drm_poll, | 81 | .poll = drm_poll, |
82 | .fasync = drm_fasync, | 82 | .fasync = drm_fasync, |
83 | .llseek = noop_llseek, | ||
83 | }, | 84 | }, |
84 | .pci_driver = { | 85 | .pci_driver = { |
85 | .name = DRIVER_NAME, | 86 | .name = DRIVER_NAME, |
diff --git a/drivers/gpu/drm/tdfx/tdfx_drv.c b/drivers/gpu/drm/tdfx/tdfx_drv.c index e0768adbecc..b70fa91d761 100644 --- a/drivers/gpu/drm/tdfx/tdfx_drv.c +++ b/drivers/gpu/drm/tdfx/tdfx_drv.c | |||
@@ -50,6 +50,7 @@ static struct drm_driver driver = { | |||
50 | .mmap = drm_mmap, | 50 | .mmap = drm_mmap, |
51 | .poll = drm_poll, | 51 | .poll = drm_poll, |
52 | .fasync = drm_fasync, | 52 | .fasync = drm_fasync, |
53 | .llseek = noop_llseek, | ||
53 | }, | 54 | }, |
54 | .pci_driver = { | 55 | .pci_driver = { |
55 | .name = DRIVER_NAME, | 56 | .name = DRIVER_NAME, |
diff --git a/drivers/gpu/drm/ttm/ttm_bo_util.c b/drivers/gpu/drm/ttm/ttm_bo_util.c index ff358ad45aa..3106d5bcce3 100644 --- a/drivers/gpu/drm/ttm/ttm_bo_util.c +++ b/drivers/gpu/drm/ttm/ttm_bo_util.c | |||
@@ -163,7 +163,7 @@ static int ttm_copy_io_ttm_page(struct ttm_tt *ttm, void *src, | |||
163 | src = (void *)((unsigned long)src + (page << PAGE_SHIFT)); | 163 | src = (void *)((unsigned long)src + (page << PAGE_SHIFT)); |
164 | 164 | ||
165 | #ifdef CONFIG_X86 | 165 | #ifdef CONFIG_X86 |
166 | dst = kmap_atomic_prot(d, KM_USER0, prot); | 166 | dst = kmap_atomic_prot(d, prot); |
167 | #else | 167 | #else |
168 | if (pgprot_val(prot) != pgprot_val(PAGE_KERNEL)) | 168 | if (pgprot_val(prot) != pgprot_val(PAGE_KERNEL)) |
169 | dst = vmap(&d, 1, 0, prot); | 169 | dst = vmap(&d, 1, 0, prot); |
@@ -176,7 +176,7 @@ static int ttm_copy_io_ttm_page(struct ttm_tt *ttm, void *src, | |||
176 | memcpy_fromio(dst, src, PAGE_SIZE); | 176 | memcpy_fromio(dst, src, PAGE_SIZE); |
177 | 177 | ||
178 | #ifdef CONFIG_X86 | 178 | #ifdef CONFIG_X86 |
179 | kunmap_atomic(dst, KM_USER0); | 179 | kunmap_atomic(dst); |
180 | #else | 180 | #else |
181 | if (pgprot_val(prot) != pgprot_val(PAGE_KERNEL)) | 181 | if (pgprot_val(prot) != pgprot_val(PAGE_KERNEL)) |
182 | vunmap(dst); | 182 | vunmap(dst); |
@@ -199,7 +199,7 @@ static int ttm_copy_ttm_io_page(struct ttm_tt *ttm, void *dst, | |||
199 | 199 | ||
200 | dst = (void *)((unsigned long)dst + (page << PAGE_SHIFT)); | 200 | dst = (void *)((unsigned long)dst + (page << PAGE_SHIFT)); |
201 | #ifdef CONFIG_X86 | 201 | #ifdef CONFIG_X86 |
202 | src = kmap_atomic_prot(s, KM_USER0, prot); | 202 | src = kmap_atomic_prot(s, prot); |
203 | #else | 203 | #else |
204 | if (pgprot_val(prot) != pgprot_val(PAGE_KERNEL)) | 204 | if (pgprot_val(prot) != pgprot_val(PAGE_KERNEL)) |
205 | src = vmap(&s, 1, 0, prot); | 205 | src = vmap(&s, 1, 0, prot); |
@@ -212,7 +212,7 @@ static int ttm_copy_ttm_io_page(struct ttm_tt *ttm, void *dst, | |||
212 | memcpy_toio(dst, src, PAGE_SIZE); | 212 | memcpy_toio(dst, src, PAGE_SIZE); |
213 | 213 | ||
214 | #ifdef CONFIG_X86 | 214 | #ifdef CONFIG_X86 |
215 | kunmap_atomic(src, KM_USER0); | 215 | kunmap_atomic(src); |
216 | #else | 216 | #else |
217 | if (pgprot_val(prot) != pgprot_val(PAGE_KERNEL)) | 217 | if (pgprot_val(prot) != pgprot_val(PAGE_KERNEL)) |
218 | vunmap(src); | 218 | vunmap(src); |
diff --git a/drivers/gpu/drm/via/via_drv.c b/drivers/gpu/drm/via/via_drv.c index 02f733db61c..e1ff4e7a6eb 100644 --- a/drivers/gpu/drm/via/via_drv.c +++ b/drivers/gpu/drm/via/via_drv.c | |||
@@ -60,6 +60,7 @@ static struct drm_driver driver = { | |||
60 | .mmap = drm_mmap, | 60 | .mmap = drm_mmap, |
61 | .poll = drm_poll, | 61 | .poll = drm_poll, |
62 | .fasync = drm_fasync, | 62 | .fasync = drm_fasync, |
63 | .llseek = noop_llseek, | ||
63 | }, | 64 | }, |
64 | .pci_driver = { | 65 | .pci_driver = { |
65 | .name = DRIVER_NAME, | 66 | .name = DRIVER_NAME, |
diff --git a/drivers/gpu/drm/vmwgfx/vmwgfx_drv.c b/drivers/gpu/drm/vmwgfx/vmwgfx_drv.c index d0ef624fbdc..10ca97ee020 100644 --- a/drivers/gpu/drm/vmwgfx/vmwgfx_drv.c +++ b/drivers/gpu/drm/vmwgfx/vmwgfx_drv.c | |||
@@ -907,6 +907,7 @@ static struct drm_driver driver = { | |||
907 | #if defined(CONFIG_COMPAT) | 907 | #if defined(CONFIG_COMPAT) |
908 | .compat_ioctl = drm_compat_ioctl, | 908 | .compat_ioctl = drm_compat_ioctl, |
909 | #endif | 909 | #endif |
910 | .llseek = noop_llseek, | ||
910 | }, | 911 | }, |
911 | .pci_driver = { | 912 | .pci_driver = { |
912 | .name = VMWGFX_DRIVER_NAME, | 913 | .name = VMWGFX_DRIVER_NAME, |
diff --git a/drivers/gpu/drm/vmwgfx/vmwgfx_fifo.c b/drivers/gpu/drm/vmwgfx/vmwgfx_fifo.c index 0fe31766e4c..635c0ffee7f 100644 --- a/drivers/gpu/drm/vmwgfx/vmwgfx_fifo.c +++ b/drivers/gpu/drm/vmwgfx/vmwgfx_fifo.c | |||
@@ -545,7 +545,7 @@ int vmw_fifo_mmap(struct file *filp, struct vm_area_struct *vma) | |||
545 | struct drm_file *file_priv; | 545 | struct drm_file *file_priv; |
546 | struct vmw_private *dev_priv; | 546 | struct vmw_private *dev_priv; |
547 | 547 | ||
548 | file_priv = (struct drm_file *)filp->private_data; | 548 | file_priv = filp->private_data; |
549 | dev_priv = vmw_priv(file_priv->minor->dev); | 549 | dev_priv = vmw_priv(file_priv->minor->dev); |
550 | 550 | ||
551 | if (vma->vm_pgoff != (dev_priv->mmio_start >> PAGE_SHIFT) || | 551 | if (vma->vm_pgoff != (dev_priv->mmio_start >> PAGE_SHIFT) || |
diff --git a/drivers/gpu/drm/vmwgfx/vmwgfx_ttm_glue.c b/drivers/gpu/drm/vmwgfx/vmwgfx_ttm_glue.c index 83123287c60..1e8eedd901e 100644 --- a/drivers/gpu/drm/vmwgfx/vmwgfx_ttm_glue.c +++ b/drivers/gpu/drm/vmwgfx/vmwgfx_ttm_glue.c | |||
@@ -39,7 +39,7 @@ int vmw_mmap(struct file *filp, struct vm_area_struct *vma) | |||
39 | return drm_mmap(filp, vma); | 39 | return drm_mmap(filp, vma); |
40 | } | 40 | } |
41 | 41 | ||
42 | file_priv = (struct drm_file *)filp->private_data; | 42 | file_priv = filp->private_data; |
43 | dev_priv = vmw_priv(file_priv->minor->dev); | 43 | dev_priv = vmw_priv(file_priv->minor->dev); |
44 | return ttm_bo_mmap(filp, vma, &dev_priv->bdev); | 44 | return ttm_bo_mmap(filp, vma, &dev_priv->bdev); |
45 | } | 45 | } |
diff --git a/drivers/gpu/vga/vgaarb.c b/drivers/gpu/vga/vgaarb.c index f366f968155..c380c65da41 100644 --- a/drivers/gpu/vga/vgaarb.c +++ b/drivers/gpu/vga/vgaarb.c | |||
@@ -1211,6 +1211,7 @@ static const struct file_operations vga_arb_device_fops = { | |||
1211 | .poll = vga_arb_fpoll, | 1211 | .poll = vga_arb_fpoll, |
1212 | .open = vga_arb_open, | 1212 | .open = vga_arb_open, |
1213 | .release = vga_arb_release, | 1213 | .release = vga_arb_release, |
1214 | .llseek = noop_llseek, | ||
1214 | }; | 1215 | }; |
1215 | 1216 | ||
1216 | static struct miscdevice vga_arb_device = { | 1217 | static struct miscdevice vga_arb_device = { |