On Tue, Jun 15, 2010 at 02:22:06PM +0300, Avi Kivity wrote:
Too much duplication. How about putting the tail end of the function in aWhere is is_hwpoison_address() coming from? I can't find it anywhere.
common helper (with an inatomic flag)?
btw, is_hwpoison_address() is racy. While it looks up the address, some
other task can unmap the page tables under us.
Anyways hwpoison will not remove the page as long as there
is a reference to it, so as long as you get the reference
race free against another task you're ok. Of course there might
be always an error in between and the hardware may poison
the data, but we don't try to handle all kernel errors.