[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Xen-devel] [PATCH 09/11] xen: Add DOMCTL to limit the number of event channels a domain may use



On 09/27/2013 06:55 AM, David Vrabel wrote:
From: David Vrabel <dvrabel@xxxxxxxxxx>

Add XEN_DOMCTL_set_max_evtchn which may be used during domain creation to
set the maximum event channel port a domain may use.  This may be used to
limit the amount of Xen resources (global mapping space and xenheap) that
a domain may use for event channels.

A domain that does not have a limit set may use all the event channels
supported by the event channel ABI in use.

Signed-off-by: David Vrabel <david.vrabel@xxxxxxxxxx>
Cc: Daniel De Graaf <dgdegra@xxxxxxxxxxxxx>
---
[...]
diff --git a/xen/xsm/flask/policy/access_vectors 
b/xen/xsm/flask/policy/access_vectors
index 5dfe13b..03a8e64 100644
--- a/xen/xsm/flask/policy/access_vectors
+++ b/xen/xsm/flask/policy/access_vectors
@@ -157,6 +157,8 @@ class domain
      set_misc_info
  # XEN_DOMCTL_set_virq_handler
      set_virq_handler
+# XEN_DOMCTL_set_max_evtchn
+    set_max_evtchn
  }

  # This is a continuation of class domain, since only 32 permissions can be
  # defined per class
  class domain2

The new domctl access vector must be added to the "domain2" class, not
"domain" which is full (already has 32 items). While the hypervisor
compilation does not currently report this as an error, attempting to
compile the policy (tools/flask/policy) will report it.

--
Daniel De Graaf
National Security Agency

_______________________________________________
Xen-devel mailing list
Xen-devel@xxxxxxxxxxxxx
http://lists.xen.org/xen-devel


 


Rackspace

Lists.xenproject.org is hosted with RackSpace, monitoring our
servers 24x7x365 and backed by RackSpace's Fanatical Support®.