[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <b040c32a0711081243gd51acb0m3049ced25411524f@mail.gmail.com>
Date: Thu, 8 Nov 2007 12:43:20 -0800
From: "Ken Chen" <kenchen@...gle.com>
To: "Adam Litke" <agl@...ibm.com>
Cc: "Andrew Morton" <akpm@...ux-foundation.org>,
linux-kernel@...r.kernel.org, linuxppc-dev@...abs.org,
"Hoang-Nam Nguyen" <hnguyen@...ux.vnet.ibm.com>
Subject: Re: [PATCH] hugetlb: follow_hugetlb_page for write access
On Nov 7, 2007 11:51 AM, Adam Litke <agl@...ibm.com> wrote:
> When calling get_user_pages(), a write flag is passed in by the caller to
> indicate if write access is required on the faulted-in pages. Currently,
> follow_hugetlb_page() ignores this flag and always faults pages for
> read-only access. This can cause data corruption because a device driver
> that calls get_user_pages() with write set will not expect COW faults to
> occur on the returned pages.
>
> This patch passes the write flag down to follow_hugetlb_page() and makes
> sure hugetlb_fault() is called with the right write_access parameter.
>
> Signed-off-by: Adam Litke <agl@...ibm.com>
Adam, this looks good.
Reviewed-by: Ken Chen <kenchen@...gle.com>
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
Powered by blists - more mailing lists