From 6db51261126cfaf84c0c1b771ea5f8d116e8389e Mon Sep 17 00:00:00 2001 From: Lin Ming Date: Mon, 2 Apr 2012 17:32:39 +0100 Subject: libxl: support for "rtc_timeoffset" and "localtime" Implement "rtc_timeoffset" and "localtime" options compatible as xm. rtc_timeoffset is the offset between host time and guest time. localtime means to specify whether the emulted RTC appears as UTC or is offset by the host. Acked-by: Ian Campbell Signed-off-by: Lin Ming Committed-by: Ian Jackson --- docs/man/xl.cfg.pod.5 | 8 ++++++++ tools/libxl/libxl_create.c | 11 +++++++++++ tools/libxl/libxl_dom.c | 3 +++ tools/libxl/libxl_types.idl | 2 ++ tools/libxl/xl_cmdimpl.c | 5 +++++ 5 files changed, 29 insertions(+), 0 deletions(-) --- tools/libxl/libxl_dom.c | 3 +++ 1 file changed, 3 insertions(+) (limited to 'tools/libxl/libxl_dom.c') diff --git a/tools/libxl/libxl_dom.c b/tools/libxl/libxl_dom.c index 9b33267353..0bdd654745 100644 --- a/tools/libxl/libxl_dom.c +++ b/tools/libxl/libxl_dom.c @@ -91,6 +91,9 @@ int libxl__build_pre(libxl__gc *gc, uint32_t domid, if (libxl_defbool_val(info->disable_migrate)) xc_domain_disable_migrate(ctx->xch, domid); + if (info->rtc_timeoffset) + xc_domain_set_time_offset(ctx->xch, domid, info->rtc_timeoffset); + if (info->type == LIBXL_DOMAIN_TYPE_HVM) { unsigned long shadow; shadow = (info->shadow_memkb + 1023) / 1024; -- cgit v1.2.3