hardcoded SIGSEGV in __die() ?

Christophe Leroy christophe.leroy at c-s.fr
Tue Mar 24 02:31:40 AEDT 2020



Le 23/03/2020 à 16:08, Joakim Tjernlund a écrit :
> On Mon, 2020-03-23 at 15:45 +0100, Christophe Leroy wrote:
>> CAUTION: This email originated from outside of the organization. Do not click links or open attachments unless you recognize the sender and know the content is safe.
>>
>>
>> Le 23/03/2020 à 15:43, Christophe Leroy a écrit :
>>>
>>> Le 23/03/2020 à 15:17, Joakim Tjernlund a écrit :
>>>> In __die(), see below, there is this call to notify_send() with
>>>> SIGSEGV hardcoded, this seems odd
>>>> to me as the variable "err" holds the true signal(in my case SIGBUS)
>>>> Should not SIGSEGV be replaced with the true signal no.?
>>>
>>> As far as I can see, comes from
>>> https://nam03.safelinks.protection.outlook.com/?url=https%3A%2F%2Fgit.kernel.org%2Fpub%2Fscm%2Flinux%2Fkernel%2Fgit%2Ftorvalds%2Flinux.git%2Fcommit%2F%3Fid%3D66fcb1059&data=02%7C01%7CJoakim.Tjernlund%40infinera.com%7C4291ac1b501e4296869a08d7cf38cdb4%7C285643de5f5b4b03a1530ae2dc8aaf77%7C1%7C0%7C637205715189366995&sdata=Z2bFsmDlD2MKhLACQvayk9ejz0dqgMEOlBTlocAmtTg%3D&reserved=0
>>>
>>
>> And
>> https://nam03.safelinks.protection.outlook.com/?url=https%3A%2F%2Fgit.kernel.org%2Fpub%2Fscm%2Flinux%2Fkernel%2Fgit%2Ftorvalds%2Flinux.git%2Fcommit%2F%3Fid%3Dae87221d3ce49d9de1e43756da834fd0bf05a2ad&data=02%7C01%7CJoakim.Tjernlund%40infinera.com%7C4291ac1b501e4296869a08d7cf38cdb4%7C285643de5f5b4b03a1530ae2dc8aaf77%7C1%7C0%7C637205715189366995&sdata=97kyz3Ur88BhDUUYzya5t%2FFQVhXYu6qiHoW8hsEg81s%3D&reserved=0
>> shows it is (was?) similar on x86.
>>
> 
> I tried to follow that chain thinking it would end up sending a signal to user space but I cannot see
> that happens. Seems to be related to debugging.
> 
> In short, I cannot see any signal being delivered to user space. If so that would explain why
> our user space process never dies.
> Is there a signal hidden in machine_check handler for SIGBUS I cannot see?
> 

Isn't it done in do_exit(), called from oops_end() ?

Christophe


More information about the Linuxppc-dev mailing list