diff options
author | Daniel Vetter <daniel.vetter@ffwll.ch> | 2014-09-23 09:46:49 -0400 |
---|---|---|
committer | Dave Airlie <airlied@redhat.com> | 2014-09-23 21:43:07 -0400 |
commit | bfbf3c851ce53b914fe98d60ea3fe3fc1ab75b96 (patch) | |
tree | 789fa903b1dfd94ffb95a5546830cef74025b622 /drivers/gpu/drm | |
parent | 197633b924517082327b66db6caf34bae720ea4e (diff) |
drm: move drm_mmap to <drm/drm_legacy.h>
Now that we've removed the copypasted users in gem/ttm we can
relegate the legacy buffer mapping support to where it belongs.
Also give it the proper drm_legacy_ prefix.
While at it statify drm_mmap_locked, somehow I've missed that in my
previous header rework.
Signed-off-by: Daniel Vetter <daniel.vetter@intel.com>
Reviewed-by: David Herrmann <dh.herrmann@gmail.com>
Acked-by: Alex Deucher <alexander.deucher@amd.com>
Signed-off-by: Dave Airlie <airlied@redhat.com>
Diffstat (limited to 'drivers/gpu/drm')
-rw-r--r-- | drivers/gpu/drm/drm_internal.h | 1 | ||||
-rw-r--r-- | drivers/gpu/drm/drm_vm.c | 6 | ||||
-rw-r--r-- | drivers/gpu/drm/i810/i810_drv.c | 2 | ||||
-rw-r--r-- | drivers/gpu/drm/mga/mga_drv.c | 2 | ||||
-rw-r--r-- | drivers/gpu/drm/r128/r128_drv.c | 2 | ||||
-rw-r--r-- | drivers/gpu/drm/radeon/radeon_drv.c | 2 | ||||
-rw-r--r-- | drivers/gpu/drm/savage/savage_drv.c | 2 | ||||
-rw-r--r-- | drivers/gpu/drm/sis/sis_drv.c | 2 | ||||
-rw-r--r-- | drivers/gpu/drm/tdfx/tdfx_drv.c | 3 | ||||
-rw-r--r-- | drivers/gpu/drm/via/via_drv.c | 2 |
10 files changed, 12 insertions, 12 deletions
diff --git a/drivers/gpu/drm/drm_internal.h b/drivers/gpu/drm/drm_internal.h index 7e459bf38c26..d27faae45f1b 100644 --- a/drivers/gpu/drm/drm_internal.h +++ b/drivers/gpu/drm/drm_internal.h | |||
@@ -37,7 +37,6 @@ int drm_irq_by_busid(struct drm_device *dev, void *data, | |||
37 | 37 | ||
38 | /* drm_vm.c */ | 38 | /* drm_vm.c */ |
39 | int drm_vma_info(struct seq_file *m, void *data); | 39 | int drm_vma_info(struct seq_file *m, void *data); |
40 | int drm_mmap_locked(struct file *filp, struct vm_area_struct *vma); | ||
41 | void drm_vm_close_locked(struct drm_device *dev, struct vm_area_struct *vma); | 40 | void drm_vm_close_locked(struct drm_device *dev, struct vm_area_struct *vma); |
42 | 41 | ||
43 | /* drm_prime.c */ | 42 | /* drm_prime.c */ |
diff --git a/drivers/gpu/drm/drm_vm.c b/drivers/gpu/drm/drm_vm.c index b2b231cda139..28739d401596 100644 --- a/drivers/gpu/drm/drm_vm.c +++ b/drivers/gpu/drm/drm_vm.c | |||
@@ -537,7 +537,7 @@ static resource_size_t drm_core_get_reg_ofs(struct drm_device *dev) | |||
537 | * according to the mapping type and remaps the pages. Finally sets the file | 537 | * according to the mapping type and remaps the pages. Finally sets the file |
538 | * pointer and calls vm_open(). | 538 | * pointer and calls vm_open(). |
539 | */ | 539 | */ |
540 | int drm_mmap_locked(struct file *filp, struct vm_area_struct *vma) | 540 | static int drm_mmap_locked(struct file *filp, struct vm_area_struct *vma) |
541 | { | 541 | { |
542 | struct drm_file *priv = filp->private_data; | 542 | struct drm_file *priv = filp->private_data; |
543 | struct drm_device *dev = priv->minor->dev; | 543 | struct drm_device *dev = priv->minor->dev; |
@@ -651,7 +651,7 @@ int drm_mmap_locked(struct file *filp, struct vm_area_struct *vma) | |||
651 | return 0; | 651 | return 0; |
652 | } | 652 | } |
653 | 653 | ||
654 | int drm_mmap(struct file *filp, struct vm_area_struct *vma) | 654 | int drm_legacy_mmap(struct file *filp, struct vm_area_struct *vma) |
655 | { | 655 | { |
656 | struct drm_file *priv = filp->private_data; | 656 | struct drm_file *priv = filp->private_data; |
657 | struct drm_device *dev = priv->minor->dev; | 657 | struct drm_device *dev = priv->minor->dev; |
@@ -666,7 +666,7 @@ int drm_mmap(struct file *filp, struct vm_area_struct *vma) | |||
666 | 666 | ||
667 | return ret; | 667 | return ret; |
668 | } | 668 | } |
669 | EXPORT_SYMBOL(drm_mmap); | 669 | EXPORT_SYMBOL(drm_legacy_mmap); |
670 | 670 | ||
671 | void drm_legacy_vma_flush(struct drm_device *dev) | 671 | void drm_legacy_vma_flush(struct drm_device *dev) |
672 | { | 672 | { |
diff --git a/drivers/gpu/drm/i810/i810_drv.c b/drivers/gpu/drm/i810/i810_drv.c index 6cb08a1c6b62..44f4a131c8dd 100644 --- a/drivers/gpu/drm/i810/i810_drv.c +++ b/drivers/gpu/drm/i810/i810_drv.c | |||
@@ -47,7 +47,7 @@ static const struct file_operations i810_driver_fops = { | |||
47 | .open = drm_open, | 47 | .open = drm_open, |
48 | .release = drm_release, | 48 | .release = drm_release, |
49 | .unlocked_ioctl = drm_ioctl, | 49 | .unlocked_ioctl = drm_ioctl, |
50 | .mmap = drm_mmap, | 50 | .mmap = drm_legacy_mmap, |
51 | .poll = drm_poll, | 51 | .poll = drm_poll, |
52 | #ifdef CONFIG_COMPAT | 52 | #ifdef CONFIG_COMPAT |
53 | .compat_ioctl = drm_compat_ioctl, | 53 | .compat_ioctl = drm_compat_ioctl, |
diff --git a/drivers/gpu/drm/mga/mga_drv.c b/drivers/gpu/drm/mga/mga_drv.c index cb5c71f4b28e..5e2f131a6a72 100644 --- a/drivers/gpu/drm/mga/mga_drv.c +++ b/drivers/gpu/drm/mga/mga_drv.c | |||
@@ -48,7 +48,7 @@ static const struct file_operations mga_driver_fops = { | |||
48 | .open = drm_open, | 48 | .open = drm_open, |
49 | .release = drm_release, | 49 | .release = drm_release, |
50 | .unlocked_ioctl = drm_ioctl, | 50 | .unlocked_ioctl = drm_ioctl, |
51 | .mmap = drm_mmap, | 51 | .mmap = drm_legacy_mmap, |
52 | .poll = drm_poll, | 52 | .poll = drm_poll, |
53 | #ifdef CONFIG_COMPAT | 53 | #ifdef CONFIG_COMPAT |
54 | .compat_ioctl = mga_compat_ioctl, | 54 | .compat_ioctl = mga_compat_ioctl, |
diff --git a/drivers/gpu/drm/r128/r128_drv.c b/drivers/gpu/drm/r128/r128_drv.c index 4a59370eb580..c57b4de63caf 100644 --- a/drivers/gpu/drm/r128/r128_drv.c +++ b/drivers/gpu/drm/r128/r128_drv.c | |||
@@ -46,7 +46,7 @@ static const struct file_operations r128_driver_fops = { | |||
46 | .open = drm_open, | 46 | .open = drm_open, |
47 | .release = drm_release, | 47 | .release = drm_release, |
48 | .unlocked_ioctl = drm_ioctl, | 48 | .unlocked_ioctl = drm_ioctl, |
49 | .mmap = drm_mmap, | 49 | .mmap = drm_legacy_mmap, |
50 | .poll = drm_poll, | 50 | .poll = drm_poll, |
51 | #ifdef CONFIG_COMPAT | 51 | #ifdef CONFIG_COMPAT |
52 | .compat_ioctl = r128_compat_ioctl, | 52 | .compat_ioctl = r128_compat_ioctl, |
diff --git a/drivers/gpu/drm/radeon/radeon_drv.c b/drivers/gpu/drm/radeon/radeon_drv.c index ec7e963d9bf7..dd082049fd5b 100644 --- a/drivers/gpu/drm/radeon/radeon_drv.c +++ b/drivers/gpu/drm/radeon/radeon_drv.c | |||
@@ -308,7 +308,7 @@ static const struct file_operations radeon_driver_old_fops = { | |||
308 | .open = drm_open, | 308 | .open = drm_open, |
309 | .release = drm_release, | 309 | .release = drm_release, |
310 | .unlocked_ioctl = drm_ioctl, | 310 | .unlocked_ioctl = drm_ioctl, |
311 | .mmap = drm_mmap, | 311 | .mmap = drm_legacy_mmap, |
312 | .poll = drm_poll, | 312 | .poll = drm_poll, |
313 | .read = drm_read, | 313 | .read = drm_read, |
314 | #ifdef CONFIG_COMPAT | 314 | #ifdef CONFIG_COMPAT |
diff --git a/drivers/gpu/drm/savage/savage_drv.c b/drivers/gpu/drm/savage/savage_drv.c index 1b09d2182037..21aed1febeb4 100644 --- a/drivers/gpu/drm/savage/savage_drv.c +++ b/drivers/gpu/drm/savage/savage_drv.c | |||
@@ -40,7 +40,7 @@ static const struct file_operations savage_driver_fops = { | |||
40 | .open = drm_open, | 40 | .open = drm_open, |
41 | .release = drm_release, | 41 | .release = drm_release, |
42 | .unlocked_ioctl = drm_ioctl, | 42 | .unlocked_ioctl = drm_ioctl, |
43 | .mmap = drm_mmap, | 43 | .mmap = drm_legacy_mmap, |
44 | .poll = drm_poll, | 44 | .poll = drm_poll, |
45 | #ifdef CONFIG_COMPAT | 45 | #ifdef CONFIG_COMPAT |
46 | .compat_ioctl = drm_compat_ioctl, | 46 | .compat_ioctl = drm_compat_ioctl, |
diff --git a/drivers/gpu/drm/sis/sis_drv.c b/drivers/gpu/drm/sis/sis_drv.c index 54858e6fedaf..79bce76cb8f7 100644 --- a/drivers/gpu/drm/sis/sis_drv.c +++ b/drivers/gpu/drm/sis/sis_drv.c | |||
@@ -70,7 +70,7 @@ static const struct file_operations sis_driver_fops = { | |||
70 | .open = drm_open, | 70 | .open = drm_open, |
71 | .release = drm_release, | 71 | .release = drm_release, |
72 | .unlocked_ioctl = drm_ioctl, | 72 | .unlocked_ioctl = drm_ioctl, |
73 | .mmap = drm_mmap, | 73 | .mmap = drm_legacy_mmap, |
74 | .poll = drm_poll, | 74 | .poll = drm_poll, |
75 | #ifdef CONFIG_COMPAT | 75 | #ifdef CONFIG_COMPAT |
76 | .compat_ioctl = drm_compat_ioctl, | 76 | .compat_ioctl = drm_compat_ioctl, |
diff --git a/drivers/gpu/drm/tdfx/tdfx_drv.c b/drivers/gpu/drm/tdfx/tdfx_drv.c index df533ff999a4..fab5ebcb0fef 100644 --- a/drivers/gpu/drm/tdfx/tdfx_drv.c +++ b/drivers/gpu/drm/tdfx/tdfx_drv.c | |||
@@ -36,6 +36,7 @@ | |||
36 | #include "tdfx_drv.h" | 36 | #include "tdfx_drv.h" |
37 | 37 | ||
38 | #include <drm/drm_pciids.h> | 38 | #include <drm/drm_pciids.h> |
39 | #include <drm/drm_legacy.h> | ||
39 | 40 | ||
40 | static struct pci_device_id pciidlist[] = { | 41 | static struct pci_device_id pciidlist[] = { |
41 | tdfx_PCI_IDS | 42 | tdfx_PCI_IDS |
@@ -46,7 +47,7 @@ static const struct file_operations tdfx_driver_fops = { | |||
46 | .open = drm_open, | 47 | .open = drm_open, |
47 | .release = drm_release, | 48 | .release = drm_release, |
48 | .unlocked_ioctl = drm_ioctl, | 49 | .unlocked_ioctl = drm_ioctl, |
49 | .mmap = drm_mmap, | 50 | .mmap = drm_legacy_mmap, |
50 | .poll = drm_poll, | 51 | .poll = drm_poll, |
51 | #ifdef CONFIG_COMPAT | 52 | #ifdef CONFIG_COMPAT |
52 | .compat_ioctl = drm_compat_ioctl, | 53 | .compat_ioctl = drm_compat_ioctl, |
diff --git a/drivers/gpu/drm/via/via_drv.c b/drivers/gpu/drm/via/via_drv.c index c16ffa63ded6..ed8aa8ff861a 100644 --- a/drivers/gpu/drm/via/via_drv.c +++ b/drivers/gpu/drm/via/via_drv.c | |||
@@ -62,7 +62,7 @@ static const struct file_operations via_driver_fops = { | |||
62 | .open = drm_open, | 62 | .open = drm_open, |
63 | .release = drm_release, | 63 | .release = drm_release, |
64 | .unlocked_ioctl = drm_ioctl, | 64 | .unlocked_ioctl = drm_ioctl, |
65 | .mmap = drm_mmap, | 65 | .mmap = drm_legacy_mmap, |
66 | .poll = drm_poll, | 66 | .poll = drm_poll, |
67 | #ifdef CONFIG_COMPAT | 67 | #ifdef CONFIG_COMPAT |
68 | .compat_ioctl = drm_compat_ioctl, | 68 | .compat_ioctl = drm_compat_ioctl, |