From mboxrd@z Thu Jan 1 00:00:00 1970 From: Vitaly Kuznetsov Subject: [PATCH v8 09/11] libxc: support XEN_DOMCTL_soft_reset operation Date: Tue, 23 Jun 2015 18:11:51 +0200 Message-ID: <1435075913-335-10-git-send-email-vkuznets@redhat.com> References: <1435075913-335-1-git-send-email-vkuznets@redhat.com> Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Return-path: Received: from mail6.bemta14.messagelabs.com ([193.109.254.103]) by lists.xen.org with esmtp (Exim 4.72) (envelope-from ) id 1Z7QoK-0008MR-BS for xen-devel@lists.xenproject.org; Tue, 23 Jun 2015 16:12:32 +0000 In-Reply-To: <1435075913-335-1-git-send-email-vkuznets@redhat.com> List-Unsubscribe: , List-Post: List-Help: List-Subscribe: , Sender: xen-devel-bounces@lists.xen.org Errors-To: xen-devel-bounces@lists.xen.org To: xen-devel@lists.xenproject.org Cc: Andrew Jones , Julien Grall , Keir Fraser , Ian Campbell , Stefano Stabellini , Andrew Cooper , Ian Jackson , Olaf Hering , Tim Deegan , David Vrabel , Jan Beulich , Wei Liu , Daniel De Graaf List-Id: xen-devel@lists.xenproject.org Introduce xc_domain_soft_reset() function supporting XEN_DOMCTL_soft_reset. Signed-off-by: Vitaly Kuznetsov --- tools/libxc/include/xenctrl.h | 3 +++ tools/libxc/xc_domain.c | 9 +++++++++ 2 files changed, 12 insertions(+) diff --git a/tools/libxc/include/xenctrl.h b/tools/libxc/include/xenctrl.h index d1d2ab3..7aa0e81 100644 --- a/tools/libxc/include/xenctrl.h +++ b/tools/libxc/include/xenctrl.h @@ -1301,6 +1301,9 @@ int xc_domain_setvnuma(xc_interface *xch, unsigned int *vcpu_to_vnode, unsigned int *vnode_to_pnode); +int xc_domain_soft_reset(xc_interface *xch, + uint32_t domid); + #if defined(__i386__) || defined(__x86_64__) /* * PC BIOS standard E820 types and structure. diff --git a/tools/libxc/xc_domain.c b/tools/libxc/xc_domain.c index ce51e69..a59d0b0 100644 --- a/tools/libxc/xc_domain.c +++ b/tools/libxc/xc_domain.c @@ -2452,6 +2452,15 @@ int xc_domain_setvnuma(xc_interface *xch, return rc; } + +int xc_domain_soft_reset(xc_interface *xch, + uint32_t domid) +{ + DECLARE_DOMCTL; + domctl.cmd = XEN_DOMCTL_soft_reset; + domctl.domain = (domid_t)domid; + return do_domctl(xch, &domctl); +} /* * Local variables: * mode: C -- 2.4.2