arm: tegra: usb_phy: fix hsic suspend issue on xmm
[linux-2.6.git] / mm / madvise.c
index ecde40a..74bf193 100644 (file)
@@ -72,7 +72,8 @@ static long madvise_behavior(struct vm_area_struct * vma,
                        goto out;
                break;
        case MADV_HUGEPAGE:
-               error = hugepage_madvise(&new_flags);
+       case MADV_NOHUGEPAGE:
+               error = hugepage_madvise(vma, &new_flags, behavior);
                if (error)
                        goto out;
                break;
@@ -217,7 +218,7 @@ static long madvise_remove(struct vm_area_struct *vma,
        endoff = (loff_t)(end - vma->vm_start - 1)
                        + ((loff_t)vma->vm_pgoff << PAGE_SHIFT);
 
-       /* vmtruncate_range needs to take i_mutex and i_alloc_sem */
+       /* vmtruncate_range needs to take i_mutex */
        up_read(&current->mm->mmap_sem);
        error = vmtruncate_range(mapping->host, offset, endoff);
        down_read(&current->mm->mmap_sem);
@@ -290,6 +291,7 @@ madvise_behavior_valid(int behavior)
 #endif
 #ifdef CONFIG_TRANSPARENT_HUGEPAGE
        case MADV_HUGEPAGE:
+       case MADV_NOHUGEPAGE:
 #endif
                return 1;