Re: [PATCH 1/2] memory-failure: Send right signal code to correct thread

2014-05-27 Thread Tony Luck
I'm exploring options to see what writers of threaded applications might want/need. I'm very doubtful that they would really want "broadcast to all threads". What if there are hundreds or thousands of threads? We send the signals from the context of the thread that hit the error. But that might

Re: [PATCH 1/2] memory-failure: Send right signal code to correct thread

2014-05-27 Thread Tony Luck
> - make sure that every thread in a recovery aware application should have >a SIGBUS handler, inside which >* code for SIGBUS(BUS_MCEERR_AR) is enabled for every thread >* code for SIGBUS(BUS_MCEERR_AO) is enabled only for a dedicated thread But how does the kernel know which is the

Re: [PATCH 1/2] memory-failure: Send right signal code to correct thread

2014-05-27 Thread Kamil Iskra
On Fri, May 23, 2014 at 09:48:42 -0700, Tony Luck wrote: Tony, > Added Kamil (hope I got the right one - the spinics.net archive obfuscates > the e-mail addresses). Yes, you got the right address :-). > >> - if ((flags & MF_ACTION_REQUIRED) && t == current) { > >> + if ((flags & MF_ACTI

Re: [PATCH 1/2] memory-failure: Send right signal code to correct thread

2014-05-23 Thread Tony Luck
Added Kamil (hope I got the right one - the spinics.net archive obfuscates the e-mail addresses). >> - if ((flags & MF_ACTION_REQUIRED) && t == current) { >> + if ((flags & MF_ACTION_REQUIRED) && t->mm == current->mm) { >> si.si_code = BUS_MCEERR_AR; >> - ret = fo

Re: [PATCH 1/2] memory-failure: Send right signal code to correct thread

2014-05-22 Thread Chen, Gong
On Tue, May 20, 2014 at 09:28:00AM -0700, Luck, Tony wrote: > When a thread in a multi-threaded application hits a machine > check because of an uncorrectable error in memory - we want to > send the SIGBUS with si.si_code = BUS_MCEERR_AR to that thread. > Currently we fail to do that if the active

RE: [PATCH 1/2] memory-failure: Send right signal code to correct thread

2014-05-20 Thread Luck, Tony
> Looks good to me, thank you. > Reviewed-by: Naoya Horiguchi Thanks for your time reviewing this > and I think this is worth going into stable trees. Good point. I should dig in the git history and make one of those fancy "Fixes: sha1 title" tags too. -Tony -- To unsubscribe from this list: