lkml.org 
[lkml]   [2022]   [Jun]   [14]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
SubjectRe: [External] Re: [PATCH v4 1/2] mm/memory-failure: introduce "hwpoisoned-pages" entry
From


On 6/14/22 15:13, David Hildenbrand wrote:
> &hwpoisoned_pages);
>>
>> I'm not sure how useful this interface from userspace (controlling test process
>> with this?). Do we really need to expose this to userspace?
>>
>>
>> TBH I feel that another approach like below is more desirable:
>>
>> - define a new flag in "enum mf_flags" (for example named MF_SW_SIMULATED),
>> - set the flag when calling memory_failure() from the three callers
>> mentioned above,
>> - define a global variable (typed bool) in mm/memory_failure.c_to show that
>> the system has experienced a real hardware memory error events.
>> - once memory_failure() is called without MF_SW_SIMULATED, the new global
>> bool variable is set, and afterward unpoison_memory always fails with
>> -EOPNOTSUPP.
>
> Exactly what I had in mind.
>

Sure, I'll send a new version later! Thanks!

--
zhenwei pi

\
 
 \ /
  Last update: 2022-06-14 09:21    [W:2.095 / U:0.448 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site