Skip to contentSkip to conversation

are there any hidden domains inside Xen when it is running?

DISCUSSION Haifeng Fang 2 participants 2 messages Jun 4, 2008

lore
Share & tools
lore
#0 lore raw

hi, all:

i have programmed a little tool which can dump some information of key data-struct inside xen. with the tool, i obtained some data related to "frame_table" as follows:

page_offset, page_number, count_info, is_allocated, reference, inuse_domain_id, free_list_order

    502636KB,     125659,   80000002, allocated,          2,          1,          0
    516092KB,     129023,   80000002, allocated,          2,          0,          0
    516096KB,     129024,   80000001, allocated,          1,      32754,          0
    523248KB,     130812,   80000003, allocated,          3,      32753,          0

in my testing, i have brought up two domains, i.e. domain0(0), domainU(1). But from the list above, there are another two domains, who are they?

thanks in advance.
2008-06-04

Haifeng Fang

_______________________________________________
Xen-devel mailing list
[email protected]
http://lists.xensource.com/xen-devel

#1 lore raw
Quoted 9 lines · Haifeng Fang

hi, all:

i have programmed a little tool which can dump some information of key data-struct inside xen.
with the tool, i obtained some data related to "frame_table" as follows:

page_offset, page_number, count_info, is_allocated, reference, inuse_domain_id, free_list_order

Quoted 8 lines
    502636KB,     125659,   80000002, allocated,          2,          1,          0
    516092KB,     129023,   80000002, allocated,          2,          0,          0
    516096KB,     129024,   80000001, allocated,          1,      32754,          0
    523248KB,     130812,   80000003, allocated,          3,      32753,          0

in my testing, i have brought up two domains, i.e. domain0(0), domainU(1). But from the list above, there are another two domains, who are they?

They are DOMID_XEN and DOMID_IO. From xen/include/public/xen.h:
/*
* DOMID_IO is used to restrict page-table updates to mapping I/O memory.
* Although no Foreign Domain need be specified to map I/O pages, DOMID_IO
* is useful to ensure that no mappings to the OS's own heap are accidentally
* installed. (e.g., in Linux this could cause havoc as reference counts
* aren't adjusted on the I/O-mapping code path).
* This only makes sense in MMUEXT_SET_FOREIGNDOM, but in that context can
* be specified by any calling domain.
*/
#define DOMID_IO (0x7FF1U)

/*
* DOMID_XEN is used to allow privileged domains to map restricted parts of
* Xen's heap space (e.g., the machine_to_phys table).
* This only makes sense in MMUEXT_SET_FOREIGNDOM, and is only permitted if
* the caller is privileged.
*/
#define DOMID_XEN (0x7FF2U)

Ian.

Quoted 1 line