Re: [PATCH] mm/hwpoison: Fix error page recovered but reported "not recovered"

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Wed, Jan 12, 2022 at 06:00:51PM -0800, Luck, Tony wrote:
> On Wed, Jan 12, 2022 at 09:11:45PM +0900, Naoya Horiguchi wrote:
> > On Fri, Jan 07, 2022 at 11:44:50AM -0800, Tony Luck wrote:
> > > From: Youquan Song <youquan.song@xxxxxxxxx>
> 
> > diff --git a/mm/memory-failure.c b/mm/memory-failure.c
> > index 14ae5c18e776..4c9bd1d37301 100644
> > --- a/mm/memory-failure.c
> > +++ b/mm/memory-failure.c
> > @@ -707,8 +707,10 @@ static int kill_accessing_process(struct task_struct *p, unsigned long pfn,
> >  			      (void *)&priv);
> >  	if (ret == 1 && priv.tk.addr)
> >  		kill_proc(&priv.tk, pfn, flags);
> > +	else
> > +		ret = 0;
> >  	mmap_read_unlock(p->mm);
> > -	return ret ? -EFAULT : -EHWPOISON;
> > +	return ret > 0 ? -EHWPOISON : -EFAULT;
> >  }
> >  
> >  static const char *action_name[] = {
> 
> Yes. This fixes the problem (and your explanation helped
> me understand this code better).
> 

Thank you for confirming.  I just sent v2.

> Fell free to take any words you need from the original patch
> comment and switch to:
> 
> Reported-by: Youquan Song <youquan.song@xxxxxxxxx>
> 
> Thanks for looking (and fixing!)

Your welcome :)

- Naoya




[Index of Archives]     [Linux ARM Kernel]     [Linux ARM]     [Linux Omap]     [Fedora ARM]     [IETF Annouce]     [Bugtraq]     [Linux OMAP]     [Linux MIPS]     [eCos]     [Asterisk Internet PBX]     [Linux API]

  Powered by Linux