From nobody Mon Feb 9 13:38:27 2026 Delivered-To: importer@patchew.org Received-SPF: pass (zohomail.com: domain of redhat.com designates 63.128.21.124 as permitted sender) client-ip=63.128.21.124; envelope-from=libvir-list-bounces@redhat.com; helo=us-smtp-delivery-124.mimecast.com; Authentication-Results: mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of redhat.com designates 63.128.21.124 as permitted sender) smtp.mailfrom=libvir-list-bounces@redhat.com; dmarc=pass(p=none dis=none) header.from=redhat.com ARC-Seal: i=1; a=rsa-sha256; t=1612877194; cv=none; d=zohomail.com; s=zohoarc; b=eahcxUWLlatzSEDYQhwbsttgiIOLJpG0LL6rSq/SBXikwHyF2TaRjSv/va4HK3Dgq0mk8zCpnl6we34OTgsESw/JuSQspEr4p7oo0US878n1miMJMcjbY9SRawKOVUKiko/OwVimnPwbp9Tfy1opA+BE4G0KCwhjQerfBkVCRB0= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1612877194; h=Content-Type:Content-Transfer-Encoding:Date:From:In-Reply-To:List-Subscribe:List-Post:List-Id:List-Archive:List-Help:List-Unsubscribe:MIME-Version:Message-ID:References:Sender:Subject:To; bh=7MwQBdz6f3ocMdSeCSXxz58ocXD+ZREN2CM6QgOnqjs=; b=g7xOUX5JukOJqYjfbheUqIsZmHnr+manc6zPmZfqSgkc5xBZqL2Pcw0vq2TMUNQjSzxz3R8SOOryU3oF9tehJb+sp6UTyx+wld3+uu7d69in0tDPDoLCo8MewoCNgTK81eGGRh7QOsgciFUX7zBFwCR6SF2Vq7RLIJjzcKalPio= ARC-Authentication-Results: i=1; mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of redhat.com designates 63.128.21.124 as permitted sender) smtp.mailfrom=libvir-list-bounces@redhat.com; dmarc=pass header.from= (p=none dis=none) header.from= Return-Path: Received: from us-smtp-delivery-124.mimecast.com (us-smtp-delivery-124.mimecast.com [63.128.21.124]) by mx.zohomail.com with SMTPS id 1612877194447781.2107180046936; Tue, 9 Feb 2021 05:26:34 -0800 (PST) Received: from mimecast-mx01.redhat.com (mimecast-mx01.redhat.com [209.132.183.4]) (Using TLS) by relay.mimecast.com with ESMTP id us-mta-114-N9E_iMdaP8GsZoph4j51mg-1; Tue, 09 Feb 2021 08:26:30 -0500 Received: from smtp.corp.redhat.com (int-mx04.intmail.prod.int.phx2.redhat.com [10.5.11.14]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mimecast-mx01.redhat.com (Postfix) with ESMTPS id CFF391934105; Tue, 9 Feb 2021 13:26:24 +0000 (UTC) Received: from colo-mx.corp.redhat.com (colo-mx02.intmail.prod.int.phx2.redhat.com [10.5.11.21]) by smtp.corp.redhat.com (Postfix) with ESMTPS id DC9ED5D9CD; Tue, 9 Feb 2021 13:26:23 +0000 (UTC) Received: from lists01.pubmisc.prod.ext.phx2.redhat.com (lists01.pubmisc.prod.ext.phx2.redhat.com [10.5.19.33]) by colo-mx.corp.redhat.com (Postfix) with ESMTP id 8085449; Tue, 9 Feb 2021 13:26:22 +0000 (UTC) Received: from smtp.corp.redhat.com (int-mx04.intmail.prod.int.phx2.redhat.com [10.5.11.14]) by lists01.pubmisc.prod.ext.phx2.redhat.com (8.13.8/8.13.8) with ESMTP id 119DQKxK020388 for ; Tue, 9 Feb 2021 08:26:20 -0500 Received: by smtp.corp.redhat.com (Postfix) id 8DA775D9CD; Tue, 9 Feb 2021 13:26:20 +0000 (UTC) Received: from antique-laptop.redhat.com (unknown [10.40.208.58]) by smtp.corp.redhat.com (Postfix) with ESMTP id E99885D9C0 for ; Tue, 9 Feb 2021 13:26:19 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1612877192; h=from:from:sender:sender:reply-to:subject:subject:date:date: message-id:message-id:to:to:cc:mime-version:mime-version: content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references:list-id:list-help: list-unsubscribe:list-subscribe:list-post; bh=7MwQBdz6f3ocMdSeCSXxz58ocXD+ZREN2CM6QgOnqjs=; b=bh66PcIQlRjfS09TvP17SHfibZPh6a1wUGqK07jlx3VykLQ3sRpYZhoP82h32tcC5RrTiN 1byCW34Y9ZSic9Qz1x56HfJ7hW9SfIHgTGxRCPg/XMAL0piBfsDSKtWugKhFOhhgSEiuU0 8VA793Il+C3Fzdnd+oGARqNulo27wpQ= X-MC-Unique: N9E_iMdaP8GsZoph4j51mg-1 From: Pavel Hrdina To: libvir-list@redhat.com Subject: [libvirt PATCH 1/9] virsystemd: export virSystemdHasMachined Date: Tue, 9 Feb 2021 14:26:06 +0100 Message-Id: <8af523ac102f190da88671f37e3cd320193c3355.1612875677.git.phrdina@redhat.com> In-Reply-To: References: MIME-Version: 1.0 X-Scanned-By: MIMEDefang 2.79 on 10.5.11.14 X-loop: libvir-list@redhat.com X-BeenThere: libvir-list@redhat.com X-Mailman-Version: 2.1.12 Precedence: junk List-Id: Development discussions about the libvirt library & tools List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: libvir-list-bounces@redhat.com Errors-To: libvir-list-bounces@redhat.com X-Scanned-By: MIMEDefang 2.79 on 10.5.11.14 Authentication-Results: relay.mimecast.com; auth=pass smtp.auth=CUSA124A263 smtp.mailfrom=libvir-list-bounces@redhat.com X-Mimecast-Spam-Score: 0 X-Mimecast-Originator: redhat.com Content-Transfer-Encoding: quoted-printable X-ZohoMail-DKIM: pass (identity @redhat.com) Content-Type: text/plain; charset="utf-8" Signed-off-by: Pavel Hrdina --- src/libvirt_private.syms | 1 + src/util/virsystemd.c | 2 +- src/util/virsystemd.h | 2 ++ 3 files changed, 4 insertions(+), 1 deletion(-) diff --git a/src/libvirt_private.syms b/src/libvirt_private.syms index 0636b0d8c9..b2d2282ce0 100644 --- a/src/libvirt_private.syms +++ b/src/libvirt_private.syms @@ -3304,6 +3304,7 @@ virSystemdGetActivation; virSystemdGetMachineNameByPID; virSystemdHasLogind; virSystemdHasLogindResetCachedValue; +virSystemdHasMachined; virSystemdHasMachinedResetCachedValue; virSystemdMakeScopeName; virSystemdMakeSliceName; diff --git a/src/util/virsystemd.c b/src/util/virsystemd.c index 3f689365e4..58b5c650b5 100644 --- a/src/util/virsystemd.c +++ b/src/util/virsystemd.c @@ -147,7 +147,7 @@ void virSystemdHasLogindResetCachedValue(void) * -1 =3D error * 0 =3D machine1 is available */ -static int +int virSystemdHasMachined(void) { int ret; diff --git a/src/util/virsystemd.h b/src/util/virsystemd.h index dfea75948b..9ce16b7de1 100644 --- a/src/util/virsystemd.h +++ b/src/util/virsystemd.h @@ -57,6 +57,8 @@ int virSystemdTerminateMachine(const char *name); =20 void virSystemdNotifyStartup(void); =20 +int virSystemdHasMachined(void); + int virSystemdHasLogind(void); =20 int virSystemdCanSuspend(bool *result); --=20 2.29.2