From: Andre Przywara <andre.przywara@amd.com>
To: Keir Fraser <keir.fraser@eu.citrix.com>,
Stefano Stabellini <stefano.stabellini@eu.citrix.com>,
Ian.Jackson@eu.citrix.com
Cc: "xen-devel@lists.xensource.com" <xen-devel@lists.xensource.com>
Subject: [PATCH 1/4] libxl: extend physinfo structure
Date: Sun, 18 Apr 2010 23:23:21 +0200 [thread overview]
Message-ID: <4BCB7849.9030302@amd.com> (raw)
In-Reply-To: <4BCB76FD.1020103@amd.com>
[-- Attachment #1: Type: text/plain, Size: 345 bytes --]
The libxl version of the physinfo sysctl does not contain some
fields like nr_nodes or capabilities needed for xl info output.
Add them to the structure and the retrieving function.
Signed-off-by: Andre Przywara <andre.przywara@amd.com>
--
Andre Przywara
AMD-Operating System Research Center (OSRC), Dresden, Germany
Tel: +49 351 488-3567-12
[-- Attachment #2: libxl_physinfo_ext.patch --]
[-- Type: text/plain, Size: 1185 bytes --]
diff -r 7ee8bb40200a tools/libxl/libxl.c
--- a/tools/libxl/libxl.c Thu Apr 15 19:11:16 2010 +0100
+++ b/tools/libxl/libxl.c Sun Apr 18 14:34:32 2010 +0200
@@ -2344,6 +2344,10 @@
physinfo->total_pages = xcphysinfo.total_pages;
physinfo->free_pages = xcphysinfo.free_pages;
physinfo->scrub_pages = xcphysinfo.scrub_pages;
+ physinfo->nr_nodes = xcphysinfo.nr_nodes;
+ memcpy(physinfo->hw_cap,xcphysinfo.hw_cap, sizeof(physinfo->hw_cap));
+ physinfo->phys_cap = xcphysinfo.capabilities;
+
return 0;
}
diff -r 7ee8bb40200a tools/libxl/libxl.h
--- a/tools/libxl/libxl.h Thu Apr 15 19:11:16 2010 +0100
+++ b/tools/libxl/libxl.h Sun Apr 18 14:34:32 2010 +0200
@@ -415,6 +415,9 @@
uint64_t *cpumap; /* current cpu's affinities */
};
+#define PHYS_CAP_HVM 1
+#define PHYS_CAP_HVM_DIRECTIO 2
+
struct libxl_physinfo {
uint32_t threads_per_core;
uint32_t cores_per_socket;
@@ -426,6 +429,10 @@
uint64_t total_pages;
uint64_t free_pages;
uint64_t scrub_pages;
+
+ uint32_t nr_nodes;
+ uint32_t hw_cap[8];
+ uint32_t phys_cap;
};
int libxl_get_physinfo(struct libxl_ctx *ctx, struct libxl_physinfo *physinfo);
[-- Attachment #3: Type: text/plain, Size: 138 bytes --]
_______________________________________________
Xen-devel mailing list
Xen-devel@lists.xensource.com
http://lists.xensource.com/xen-devel
next prev parent reply other threads:[~2010-04-18 21:23 UTC|newest]
Thread overview: 19+ messages / expand[flat|nested] mbox.gz Atom feed top
2010-04-18 21:17 [PATCH 0/4] Add "xl info" command Andre Przywara
2010-04-18 21:23 ` Andre Przywara [this message]
2010-04-19 7:50 ` [PATCH 1/4] libxl: extend physinfo structure Vincent Hanquez
2010-04-19 15:27 ` [PATCH 1/4] libxl: extend physinfo structure [and 1 more messages] Ian Jackson
2010-04-18 21:25 ` [PATCH 2/4] libxl: add sched_get_id function Andre Przywara
2010-04-19 7:50 ` Vincent Hanquez
2010-04-19 15:29 ` [PATCH 2/4] libxl: add sched_get_id function [and 1 more messages] Ian Jackson
2010-04-18 21:26 ` [PATCH 3/4] libxl: add version_info function Andre Przywara
2010-04-19 8:08 ` Vincent Hanquez
2010-04-19 15:36 ` [PATCH 3/4] libxl: add version_info function [and 1 more messages] Ian Jackson
2010-04-19 16:07 ` Vincent Hanquez
2010-04-19 16:21 ` Ian Jackson
2010-04-19 16:41 ` Vincent Hanquez
2010-04-19 20:43 ` Andre Przywara
2010-04-20 8:36 ` Vincent Hanquez
2010-04-21 12:10 ` Andre Przywara
2010-04-21 12:53 ` Vincent Hanquez
2010-04-18 21:28 ` [PATCH 4/4] xl: add "xl info" command Andre Przywara
2010-04-19 15:38 ` Ian Jackson
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=4BCB7849.9030302@amd.com \
--to=andre.przywara@amd.com \
--cc=Ian.Jackson@eu.citrix.com \
--cc=keir.fraser@eu.citrix.com \
--cc=stefano.stabellini@eu.citrix.com \
--cc=xen-devel@lists.xensource.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.