Re: [PATCH 08/10] x86, pkeys: default to a restrictive init PKRU

From
Dave Hansen <hidden>
Date
2016-08-01 15:00:20
Also in
linux-arch, linux-mm, lkml
Reply to
Vlastimil Babka, 2016-08-01
On 08/01/2016 07:42 AM, Vlastimil Babka wrote:
On 07/29/2016 06:30 PM, Dave Hansen wrote:
quoted
This does not cause any practical problems with applications
using protection keys because we require them to specify initial
permissions for each key when it is allocated, which override the
restrictive default.
Here you mean the init_access_rights parameter of pkey_alloc()? So will
children of fork() after that pkey_alloc() inherit the new value or go
default?
Hi Vlastimil,

Yes, exactly, the initial permissions are provided via pkey_alloc()'s
'init_access_rights' argument.

Do you mean fork() or clone()?  In both cases, we actually copy the FPU
state from the parent, so children always inherit the state from their
parent which contains the permissions set by the parent's calls to
pkey_alloc().

--
To unsubscribe, send a message with 'unsubscribe linux-mm' in
the body to majordomo@kvack.org.  For more info on Linux MM,
see: http://www.linux-mm.org/ .
Don't email: <a href=mailto:"dont@kvack.org"> email@kvack.org </a>
Thread (19 messages) 19 messages, 4 authors, last reply 2016-08-02
Keyboard shortcuts
hback out one level
jnext message in thread / next series-diff position
kprevious message in thread / previous series-diff position
ldrill in
Escclose help / fold thread tree
?toggle this help