projects
/
xen.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
9c46139
)
xsm/flask: Use correct flag to detect writable grant mappings
author
Daniel De Graaf
<dgdegra@tycho.nsa.gov>
Tue, 22 Nov 2011 13:29:01 +0000
(13:29 +0000)
committer
Daniel De Graaf
<dgdegra@tycho.nsa.gov>
Tue, 22 Nov 2011 13:29:01 +0000
(13:29 +0000)
The flags passed to xsm_grant_mapref are the flags from the map
operation (GNTMAP_*), not status flags (GTF_*).
Signed-off-by: Daniel De Graaf <dgdegra@tycho.nsa.gov>
Committed-by: Keir Fraser <keir@xen.org>
xen/xsm/flask/hooks.c
patch
|
blob
|
history
diff --git
a/xen/xsm/flask/hooks.c
b/xen/xsm/flask/hooks.c
index e70feda5a4c80dd91d0dd96c98661ef4a8bd9187..a17f02ab78d3c339b9984b34b12170048a743f50 100644
(file)
--- a/
xen/xsm/flask/hooks.c
+++ b/
xen/xsm/flask/hooks.c
@@
-279,7
+279,7
@@
static int flask_grant_mapref(struct domain *d1, struct domain *d2,
{
u32 perms = GRANT__MAP_READ;
- if (
flags & GTF_writing
)
+ if (
!(flags & GNTMAP_readonly)
)
perms |= GRANT__MAP_WRITE;
return domain_has_perm(d1, d2, SECCLASS_GRANT, perms);