From patchwork Sun Jul 3 03:33:01 2016 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Rusty Bird X-Patchwork-Id: 9211157 Return-Path: Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork.web.codeaurora.org (Postfix) with ESMTP id 746D06075F for ; Sun, 3 Jul 2016 03:35:44 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 5EC0A28513 for ; Sun, 3 Jul 2016 03:35:44 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 52FFA28537; Sun, 3 Jul 2016 03:35:44 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on pdx-wl-mail.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-3.3 required=2.0 tests=BAYES_00,DKIM_ADSP_ALL, DKIM_SIGNED, RCVD_IN_DNSWL_MED, T_DKIM_INVALID autolearn=ham version=3.3.1 Received: from lists.xenproject.org (lists.xenproject.org [192.237.175.120]) (using TLSv1.2 with cipher AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by mail.wl.linuxfoundation.org (Postfix) with ESMTPS id 7F26128513 for ; Sun, 3 Jul 2016 03:35:42 +0000 (UTC) Received: from localhost ([127.0.0.1] helo=lists.xenproject.org) by lists.xenproject.org with esmtp (Exim 4.84_2) (envelope-from ) id 1bJY9h-0005UQ-Kn; Sun, 03 Jul 2016 03:33:13 +0000 Received: from mail6.bemta14.messagelabs.com ([193.109.254.103]) by lists.xenproject.org with esmtp (Exim 4.84_2) (envelope-from ) id 1bJY9g-0005UK-Fu for xen-devel@lists.xen.org; Sun, 03 Jul 2016 03:33:12 +0000 Received: from [193.109.254.147] by server-7.bemta-14.messagelabs.com id 92/D1-09881-77788775; Sun, 03 Jul 2016 03:33:11 +0000 X-Brightmail-Tracker: H4sIAAAAAAAAA+NgFvrDLMWRWlGSWpSXmKPExsVix8KopFvWXhF ucHOejcWSj4tZHBg9ju7+zRTAGMWamZeUX5HAmrFs9gTWgteCFTvb/zI1MF7j72Lk5BASKJP4 cPsWUxcjFweLwFsmicez3zGDJCQEbCWW7ZvACmHzSVx88QOsSEJgEqPEpN1d7CAJNgEdiZs7N rPDdX/c38cIkhARkJa49vkymM0sUCIxtRvCFhbwkvi/4D8biM0ioCpx/+wcsG28Ap4SVw5fgt osJ7Ftyx7GCYy8CxgZVjFqFKcWlaUW6Rob6CUVZaZnlOQmZuboGhqa6OWmFhcnpqfmJCYV6yX n525iBIZEPQMD4w7G/Zf8DjFKcjApifJyOZeHC/El5adUZiQWZ8QXleakFh9ilOHgUJLgfdRW ES4kWJSanlqRlpkDDE6YtAQHj5II7zmQNG9xQWJucWY6ROoUoy7HlgU31jIJseTl56VKifN6g xQJgBRllObBjYBFyiVGWSlhXkYGBgYhnoLUotzMElT5V4ziHIxKwrwRIFN4MvNK4Da9AjqCCe gI1thykCNKEhFSUg2MlVlyknMnxZmFlN775v1y7fVnz9fMe3hk0YMzDf33sq12y58/5Z3TeVH zlevttONGWrxJId1r7is0LFJPPRlf6MhXUbrc9MSt5/mhm7pid79RqTukr3ef+crKvEg5y56J F8svmTGrv2NL2bxdYNLHuV7zvmu/+/Hti5jcnelnV9QLtR7ZZXQ1SomlOCPRUIu5qDgRAGsAx TKPAgAA X-Env-Sender: rustybird@openmailbox.org X-Msg-Ref: server-10.tower-27.messagelabs.com!1467516790!51565511!1 X-Originating-IP: [62.4.1.34] X-SpamReason: No, hits=0.0 required=7.0 tests= X-StarScan-Received: X-StarScan-Version: 8.46; banners=-,-,- X-VirusChecked: Checked Received: (qmail 15681 invoked from network); 3 Jul 2016 03:33:10 -0000 Received: from mail.openmailbox.org (HELO mail.openmailbox.org) (62.4.1.34) by server-10.tower-27.messagelabs.com with DHE-RSA-AES256-GCM-SHA384 encrypted SMTP; 3 Jul 2016 03:33:10 -0000 Received: by mail.openmailbox.org (Postfix, from userid 20002) id 1E85120283B; Sun, 3 Jul 2016 05:33:10 +0200 (CEST) DKIM-Signature: v=1; a=rsa-sha256; c=simple/simple; d=openmailbox.org; s=openmailbox; t=1467516790; bh=2GBrfjo3a7hO6lfF8bRIOc/VDumNIq63jgJtSBg8fOM=; h=From:To:Cc:Subject:Date:From; b=E6FuqGugotJG3Gj06ibLPNj9wX5YqXoPRVl8PHwv+bKLGxzOKBEaA2OgHXgcw6uOs Sa9XGHhXI9PZ7BxckDBRYKeYIwImgaac6o8Ml1pXgAaaHVTlxfMV+EGJU9zx3mr1/a +xtu1oVSvdFgcjmLArfSOjaH1BiUzeJzR+hEpEmA= From: Rusty Bird DKIM-Signature: v=1; a=rsa-sha256; c=simple/simple; d=openmailbox.org; s=openmailbox; t=1467516788; bh=2GBrfjo3a7hO6lfF8bRIOc/VDumNIq63jgJtSBg8fOM=; h=From:To:Cc:Subject:Date:From; b=oW8ypTLF4jVzVE9JTwt9UylBqR0ecCmhqsG2celWWj8xdG4O6Wo8LLa55+rFYnCCA qhQU99i2nmdStVsCtxjtynVw8SsMkQScRDcAbEm+zokH4lbjsokoMzmoO2qAsJPjuH fQRk0qDpgeJPekBSpphrzWle4p+jBx7XepMuBDaI= To: xen-devel@lists.xen.org Date: Sun, 3 Jul 2016 03:33:01 +0000 Message-Id: <1467516781-12830-1-git-send-email-rustybird@openmailbox.org> X-Mailer: git-send-email 2.5.5 Cc: Wei Liu , Ian Jackson , Rusty Bird Subject: [Xen-devel] [PATCH] tools/hotplug: Add native systemd xendriverdomain.service X-BeenThere: xen-devel@lists.xen.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: Xen developer discussion List-Unsubscribe: , List-Post: List-Help: List-Subscribe: , MIME-Version: 1.0 Errors-To: xen-devel-bounces@lists.xen.org Sender: "Xen-devel" X-Virus-Scanned: ClamAV using ClamSMTP Uses ConditionVirtualization=xen, which evaluates to false in dom0 since systemd 214 (released 2014-06-11). An alternative would be this line: ExecStartPre=/bin/sh -c "! grep -q control_d /proc/xen/capabilities" (Please rerun autogen.sh) Signed-off-by: Rusty Bird Cc: Ian Jackson Cc: Wei Liu --- tools/configure.ac | 1 + tools/hotplug/Linux/systemd/Makefile | 1 + tools/hotplug/Linux/systemd/xendriverdomain.service.in | 14 ++++++++++++++ 3 files changed, 16 insertions(+) create mode 100644 tools/hotplug/Linux/systemd/xendriverdomain.service.in diff --git a/tools/configure.ac b/tools/configure.ac index 8704927..e08fa8e 100644 --- a/tools/configure.ac +++ b/tools/configure.ac @@ -437,6 +437,7 @@ AS_IF([test "x$systemd" = "xy"], [ hotplug/Linux/systemd/xenconsoled.service hotplug/Linux/systemd/xendomains.service hotplug/Linux/systemd/xenstored.service + hotplug/Linux/systemd/xendriverdomain.service hotplug/Linux/systemd/xenstored.socket hotplug/Linux/systemd/xenstored_ro.socket ]) diff --git a/tools/hotplug/Linux/systemd/Makefile b/tools/hotplug/Linux/systemd/Makefile index 83e3b32..558e459 100644 --- a/tools/hotplug/Linux/systemd/Makefile +++ b/tools/hotplug/Linux/systemd/Makefile @@ -15,6 +15,7 @@ XEN_SYSTEMD_SERVICE += xen-qemu-dom0-disk-backend.service XEN_SYSTEMD_SERVICE += xendomains.service XEN_SYSTEMD_SERVICE += xen-watchdog.service XEN_SYSTEMD_SERVICE += xen-init-dom0.service +XEN_SYSTEMD_SERVICE += xendriverdomain.service ALL_XEN_SYSTEMD = $(XEN_SYSTEMD_MODULES) \ $(XEN_SYSTEMD_MOUNT) \ diff --git a/tools/hotplug/Linux/systemd/xendriverdomain.service.in b/tools/hotplug/Linux/systemd/xendriverdomain.service.in new file mode 100644 index 0000000..c0cd454 --- /dev/null +++ b/tools/hotplug/Linux/systemd/xendriverdomain.service.in @@ -0,0 +1,14 @@ +[Unit] +Description=Xen driver domain device daemon +DefaultDependencies=no +Requires=proc-xen.mount +After=proc-xen.mount +ConditionVirtualization=xen + +[Service] +Type=forking +ExecStart=@sbindir@/xl devd --pidfile=/var/run/xldevd.pid +PIDFile=/var/run/xldevd.pid + +[Install] +WantedBy=multi-user.target