mirror of
https://github.com/drasko/codezero.git
synced 2026-01-12 02:43:15 +01:00
Merged MAP and VIRTMEM/PHYSMEM capabilities into one.
VIRTMEM and PHYSMEM are theoretically separate resources to be protected than a MAP resource, which is meant to protect the syscall privileges. In practice MAP is always used together with a VIRTMEM and a PHYSMEM resource, therefore reach VIRTMEM/PHYSMEM resource is now merged with the MAP capability, combining the micro-permission bits.
This commit is contained in:
@@ -76,7 +76,7 @@ pager_end = \
|
||||
cap_virtmem = \
|
||||
'''
|
||||
\t\t\t[%(capidx)d] = {
|
||||
\t\t\t\t.type = CAP_TYPE_MAP | CAP_RTYPE_VIRTMEM,
|
||||
\t\t\t\t.type = CAP_TYPE_MAP_VIRTMEM | CAP_RTYPE_CONTAINER,
|
||||
\t\t\t\t.access = CAP_MAP_READ | CAP_MAP_WRITE | CAP_MAP_EXEC
|
||||
\t\t\t\t\t| CAP_MAP_CACHED | CAP_MAP_UNCACHED | CAP_MAP_UNMAP | CAP_MAP_UTCB,
|
||||
\t\t\t\t.start = __pfn(CONFIG_CONT%(cn)d_VIRT%(vn)d_START),
|
||||
@@ -88,7 +88,7 @@ cap_virtmem = \
|
||||
cap_physmem = \
|
||||
'''
|
||||
\t\t\t[%(capidx)d] = {
|
||||
\t\t\t\t.type = CAP_TYPE_MAP | CAP_RTYPE_PHYSMEM,
|
||||
\t\t\t\t.type = CAP_TYPE_MAP_PHYSMEM | CAP_RTYPE_CONTAINER,
|
||||
\t\t\t\t.access = CAP_MAP_READ | CAP_MAP_WRITE | CAP_MAP_EXEC |
|
||||
\t\t\t\t\tCAP_MAP_CACHED | CAP_MAP_UNCACHED | CAP_MAP_UNMAP | CAP_MAP_UTCB,
|
||||
\t\t\t\t.start = __pfn(CONFIG_CONT%(cn)d_PHYS%(pn)d_START),
|
||||
|
||||
Reference in New Issue
Block a user