Bug 186236

Summary: [kernel] [patch] sigcode not synced on executable stack on icache not coherent archs
Product: Base System Reporter: onwahe
Component: kernAssignee: freebsd-bugs (Nobody) <bugs>
Status: Open ---    
Severity: Affects Only Me    
Priority: Normal    
Version: Unspecified   
Hardware: Any   
OS: Any   
Attachments:
Description Flags
file.diff none

Description onwahe 2014-01-29 14:10:00 UTC
When sigcode (signal trampoline) is copied to user stack during exec, no icache syncing is called. This is problem on architectures where icache is not coherent.

Fix: I'm attaching simple patch. Another approche is to map user stack without exec privilege, copy sigcode, and then remap the stack with exec privilege.

Patch attached with submission follows:
How-To-Repeat: I have noticed the problem after fork(), when parent process was immediately sending signal to child process. As a cache problem, the problem displayed itself rarely.
Comment 1 Eitan Adler freebsd_committer freebsd_triage 2017-12-31 08:00:48 UTC
For bugs matching the following criteria:

Status: In Progress Changed: (is less than) 2014-06-01

Reset to default assignee and clear in-progress tags.

Mail being skipped