diff options
author | Keir Fraser <keir@xen.org> | 2011-03-08 16:30:30 +0000 |
---|---|---|
committer | Keir Fraser <keir@xen.org> | 2011-03-08 16:30:30 +0000 |
commit | f544bf377ee829e1342abd818ac30478c6f3a134 (patch) | |
tree | b640746961aa9452786c09c5f0555d7e8710291b /xen/include/xen/grant_table.h | |
parent | 076eae8bef9fcbc18b7541a56b3d897ea16b3865 (diff) | |
download | xen-f544bf377ee829e1342abd818ac30478c6f3a134.tar.gz xen-f544bf377ee829e1342abd818ac30478c6f3a134.tar.bz2 xen-f544bf377ee829e1342abd818ac30478c6f3a134.zip |
Fix rcu domain locking for transitive grants
When acquiring a transitive grant for copy then the owning domain
needs to be locked down as well as the granting domain. This was being
done, but the unlocking was not. The acquire code now stores the
struct domain * of the owning domain (rather than the domid) in the
active entry in the granting domain. The release code then does the
unlock on the owning domain. Note that I believe I also fixed a bug
where, for non-transitive grants the active entry contained a
reference to the acquiring domain rather than the granting
domain. From my reading of the code this would stop the release code
for transitive grants from terminating its recursion correctly.
Signed-off-by: Paul Durrant <paul.durrant@citrix.com>
Diffstat (limited to 'xen/include/xen/grant_table.h')
-rw-r--r-- | xen/include/xen/grant_table.h | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/xen/include/xen/grant_table.h b/xen/include/xen/grant_table.h index 20c8354b3b..c161705ca9 100644 --- a/xen/include/xen/grant_table.h +++ b/xen/include/xen/grant_table.h @@ -32,7 +32,7 @@ struct active_grant_entry { u32 pin; /* Reference count information. */ domid_t domid; /* Domain being granted access. */ - domid_t trans_dom; + struct domain *trans_domain; uint32_t trans_gref; unsigned long frame; /* Frame being granted. */ unsigned long gfn; /* Guest's idea of the frame being granted. */ |