|
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] Introduction of stable interface between Xenstore and hypervisor
Today Xenstore is using one unstable interface to retrieve the state
of a domain (existing, dying).
In order to decouple Xenstore further from the hypervisor, a stable
interface should be established. This new interface should cover the
following functionality:
- get the needed state of a domain (existing, dying)
- get a unique identifier per domain telling Xenstore that a domid
has been reused (today Xenstore could in theory miss this)
- provide a way to avoid having to get the state of all domains when
a state change of a domain has been signaled (there is only an event
"some domain has changed state" today: VIRQ_DOM_EXC)
I'm suggesting the following hypervisor modifications:
- Addition of a global 64 bit domain sequence counter. This counter
will be incremented each time a new domain is created.
- Addition of a sequence count to struct domain. It will be set to
the value of the new global domain sequence counter when the domain
is being created.
- Addition of a global bitmap with one bit for each possible domid
(resulting in a 4 kB page). Each time the state of a domain is changed
(domain creation, shutdown, deletion) the related bit is set.
When the VIRQ_DOM_EXC event is being registered the bitmap is reset to
have the bits set for all existing domains.
- Addition of a new stable hypercall ("get domain state") returning the
following information:
+ domid of a domain having the bit set in above bitmap
+ state of that domain (existing, dying)
+ sequence count of that domain
The related bit is reset in the bitmap as a side effect of the call.
Xenstore should be changed as follows:
- At startup of Xenstore the state of all domains is being queried via
the new hypercall. This will cover all existing domains as the bitmap
in the hypervisor has been reset to flag all existing domains to have
a changed state when the VIRQ_DOM_EXC has been registered by Xenstore.
- When receiving a VIRQ_DOM_EXC event the changed states of domains are
queried via the new hypercall.
I think those modifications will cover all requirements while being
rather limited in the needed effort.
Thoughts?
Juergen
Attachment:
OpenPGP_0xB0DE9DD628BF132F.asc Attachment:
OpenPGP_signature
|
![]() |
Lists.xenproject.org is hosted with RackSpace, monitoring our |