aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/uio
diff options
context:
space:
mode:
authorUwe Kleine-König <u.kleine-koenig@pengutronix.de>2013-08-07 07:02:54 -0400
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>2013-08-12 18:46:51 -0400
commitb65c4014efbcfa37df91c00dfaea4b3f17ac4eb7 (patch)
treefca0b4228be45e7d10fdca7bb551409cf635efb7 /drivers/uio
parent7294151d0592e0ff48c61fca9fd7c93d613134da (diff)
uio: drop unused vma_count member in uio_device struct
vma_count is used write-only and so fails to be useful. So remove it. Signed-off-by: Uwe Kleine-König <u.kleine-koenig@pengutronix.de> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'drivers/uio')
-rw-r--r--drivers/uio/uio.c16
1 files changed, 0 insertions, 16 deletions
diff --git a/drivers/uio/uio.c b/drivers/uio/uio.c
index c4279b2234ac..8abe78c0b16f 100644
--- a/drivers/uio/uio.c
+++ b/drivers/uio/uio.c
@@ -35,7 +35,6 @@ struct uio_device {
35 atomic_t event; 35 atomic_t event;
36 struct fasync_struct *async_queue; 36 struct fasync_struct *async_queue;
37 wait_queue_head_t wait; 37 wait_queue_head_t wait;
38 int vma_count;
39 struct uio_info *info; 38 struct uio_info *info;
40 struct kobject *map_dir; 39 struct kobject *map_dir;
41 struct kobject *portio_dir; 40 struct kobject *portio_dir;
@@ -593,18 +592,6 @@ static int uio_find_mem_index(struct vm_area_struct *vma)
593 return -1; 592 return -1;
594} 593}
595 594
596static void uio_vma_open(struct vm_area_struct *vma)
597{
598 struct uio_device *idev = vma->vm_private_data;
599 idev->vma_count++;
600}
601
602static void uio_vma_close(struct vm_area_struct *vma)
603{
604 struct uio_device *idev = vma->vm_private_data;
605 idev->vma_count--;
606}
607
608static int uio_vma_fault(struct vm_area_struct *vma, struct vm_fault *vmf) 595static int uio_vma_fault(struct vm_area_struct *vma, struct vm_fault *vmf)
609{ 596{
610 struct uio_device *idev = vma->vm_private_data; 597 struct uio_device *idev = vma->vm_private_data;
@@ -631,8 +618,6 @@ static int uio_vma_fault(struct vm_area_struct *vma, struct vm_fault *vmf)
631} 618}
632 619
633static const struct vm_operations_struct uio_logical_vm_ops = { 620static const struct vm_operations_struct uio_logical_vm_ops = {
634 .open = uio_vma_open,
635 .close = uio_vma_close,
636 .fault = uio_vma_fault, 621 .fault = uio_vma_fault,
637}; 622};
638 623
@@ -640,7 +625,6 @@ static int uio_mmap_logical(struct vm_area_struct *vma)
640{ 625{
641 vma->vm_flags |= VM_DONTEXPAND | VM_DONTDUMP; 626 vma->vm_flags |= VM_DONTEXPAND | VM_DONTDUMP;
642 vma->vm_ops = &uio_logical_vm_ops; 627 vma->vm_ops = &uio_logical_vm_ops;
643 uio_vma_open(vma);
644 return 0; 628 return 0;
645} 629}
646 630