Re: [PATCH 4/4] Hugetlb: Copy on Write support

Rohit Seth
2005-11-10T01:47:01Z

On Wed, 2005-11-09 at 17:39 -0600, Adam Litke wrote:

>
> +#define huge_ptep_set_wrprotect(mm, addr, ptep) \
> + ptep_set_wrprotect(mm, addr, ptep)
> +static inline void set_huge_ptep_writable(struct vm_area_struct *vma,
> + unsigned long address, pte_t *ptep)
> +{
> + pte_t entry;
> +
> + entry = pte_mkwrite(pte_mkdirty(*ptep));
> + ptep_set_access_flags(vma, address, ptep, entry, 1);
> + update_mmu_cache(vma, address, entry);
> +}

lazy_mmu_prot_update will need to called here to make caches coherent
for some archs.

-rohit