diff options
-rw-r--r-- | arch/ia64/kernel/perfmon.c | 13 |
1 files changed, 4 insertions, 9 deletions
diff --git a/arch/ia64/kernel/perfmon.c b/arch/ia64/kernel/perfmon.c index 2777310b698b..899c0fa5b498 100644 --- a/arch/ia64/kernel/perfmon.c +++ b/arch/ia64/kernel/perfmon.c | |||
@@ -604,12 +604,6 @@ pfm_unprotect_ctx_ctxsw(pfm_context_t *x, unsigned long f) | |||
604 | spin_unlock(&(x)->ctx_lock); | 604 | spin_unlock(&(x)->ctx_lock); |
605 | } | 605 | } |
606 | 606 | ||
607 | static inline unsigned int | ||
608 | pfm_vm_munmap(struct mm_struct *mm, unsigned long addr, size_t len) | ||
609 | { | ||
610 | return vm_munmap(mm, addr, len); | ||
611 | } | ||
612 | |||
613 | static inline unsigned long | 607 | static inline unsigned long |
614 | pfm_get_unmapped_area(struct file *file, unsigned long addr, unsigned long len, unsigned long pgoff, unsigned long flags, unsigned long exec) | 608 | pfm_get_unmapped_area(struct file *file, unsigned long addr, unsigned long len, unsigned long pgoff, unsigned long flags, unsigned long exec) |
615 | { | 609 | { |
@@ -1458,8 +1452,9 @@ pfm_unreserve_session(pfm_context_t *ctx, int is_syswide, unsigned int cpu) | |||
1458 | * a PROTECT_CTX() section. | 1452 | * a PROTECT_CTX() section. |
1459 | */ | 1453 | */ |
1460 | static int | 1454 | static int |
1461 | pfm_remove_smpl_mapping(struct task_struct *task, void *vaddr, unsigned long size) | 1455 | pfm_remove_smpl_mapping(void *vaddr, unsigned long size) |
1462 | { | 1456 | { |
1457 | struct task_struct *task = current; | ||
1463 | int r; | 1458 | int r; |
1464 | 1459 | ||
1465 | /* sanity checks */ | 1460 | /* sanity checks */ |
@@ -1473,7 +1468,7 @@ pfm_remove_smpl_mapping(struct task_struct *task, void *vaddr, unsigned long siz | |||
1473 | /* | 1468 | /* |
1474 | * does the actual unmapping | 1469 | * does the actual unmapping |
1475 | */ | 1470 | */ |
1476 | r = pfm_vm_munmap(task->mm, (unsigned long)vaddr, size); | 1471 | r = vm_munmap(current->mm, (unsigned long)vaddr, size); |
1477 | 1472 | ||
1478 | if (r !=0) { | 1473 | if (r !=0) { |
1479 | printk(KERN_ERR "perfmon: [%d] unable to unmap sampling buffer @%p size=%lu\n", task_pid_nr(task), vaddr, size); | 1474 | printk(KERN_ERR "perfmon: [%d] unable to unmap sampling buffer @%p size=%lu\n", task_pid_nr(task), vaddr, size); |
@@ -1940,7 +1935,7 @@ pfm_flush(struct file *filp, fl_owner_t id) | |||
1940 | * because some VM function reenables interrupts. | 1935 | * because some VM function reenables interrupts. |
1941 | * | 1936 | * |
1942 | */ | 1937 | */ |
1943 | if (smpl_buf_vaddr) pfm_remove_smpl_mapping(current, smpl_buf_vaddr, smpl_buf_size); | 1938 | if (smpl_buf_vaddr) pfm_remove_smpl_mapping(smpl_buf_vaddr, smpl_buf_size); |
1944 | 1939 | ||
1945 | return 0; | 1940 | return 0; |
1946 | } | 1941 | } |