From nobody Mon Feb 9 15:10:30 2026 Delivered-To: importer@patchew.org Received-SPF: pass (zohomail.com: domain of redhat.com designates 216.205.24.124 as permitted sender) client-ip=216.205.24.124; envelope-from=philmd@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 216.205.24.124 as permitted sender) smtp.mailfrom=philmd@redhat.com; dmarc=pass(p=none dis=none) header.from=redhat.com ARC-Seal: i=1; a=rsa-sha256; t=1610378437; cv=none; d=zohomail.com; s=zohoarc; b=LB7mmI8zLbK16mTtnAUoyCxiAuchZb1CArveTlrYitakokN9cAgfSJrq1E68o3iQG3G1Az7kQ36T6bOAG1bKTz7XedsoKZM10xk0w1EBHAfYADqkBAVuToUhfoHwqDj3WsW2C3gSj37NxjD2MWXp7xNt1Kb927HP3b95d2xb1QA= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1610378437; h=Content-Type:Content-Transfer-Encoding:Cc:Date:From:In-Reply-To:MIME-Version:Message-ID:References:Subject:To; bh=97BNT6jh6NRO0TVk+TL23RreQDhzFRma0TINePq+NK8=; b=CLl4jfWIIRflxkxPoSOOO9VJtGiP8JoO+qLZ9gqrXXx1HdPglpzqrgGf2RpXb8MLFozqMb+kDuc3iqmonUkq4NKCdoSNi+SnGzcZXK9qymxLM5sLQXV9b3LAt2EHOscIGxdDRYptsXtrkrHw/yIXdhIJDjMToIx64Oqn3qEFIig= ARC-Authentication-Results: i=1; mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of redhat.com designates 216.205.24.124 as permitted sender) smtp.mailfrom=philmd@redhat.com; dmarc=pass header.from= (p=none dis=none) header.from= Received: from us-smtp-delivery-124.mimecast.com (us-smtp-delivery-124.mimecast.com [216.205.24.124]) by mx.zohomail.com with SMTPS id 161037843720264.84300906971714; Mon, 11 Jan 2021 07:20:37 -0800 (PST) Received: from mail-ed1-f69.google.com (mail-ed1-f69.google.com [209.85.208.69]) (Using TLS) by relay.mimecast.com with ESMTP id us-mta-565-gJJF8iiVMiqlLKMKcAEHgw-1; Mon, 11 Jan 2021 10:20:32 -0500 Received: by mail-ed1-f69.google.com with SMTP id dc6so8358941edb.14 for ; Mon, 11 Jan 2021 07:20:32 -0800 (PST) Return-Path: Return-Path: Received: from x1w.redhat.com (129.red-88-21-205.staticip.rima-tde.net. [88.21.205.129]) by smtp.gmail.com with ESMTPSA id c12sm76932edw.55.2021.01.11.07.20.28 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 11 Jan 2021 07:20:30 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1610378436; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=97BNT6jh6NRO0TVk+TL23RreQDhzFRma0TINePq+NK8=; b=WmrD/QMLLe6mMlP9odwpyo3CG/WprmCO3tuHBOCOnFr5nKsyybD7J8lFKV398L+OslpC5T k2U7+AjUbAeco4+MvOBuSrrnulaYnN53YwinaYfDDo9g0cjm0QjFwHDySsIZZhcJrgT8sR EkSNuvQjbOH01Ut1W9TpfFYuPNYBAu0= X-MC-Unique: gJJF8iiVMiqlLKMKcAEHgw-1 X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references:mime-version:content-transfer-encoding; bh=97BNT6jh6NRO0TVk+TL23RreQDhzFRma0TINePq+NK8=; b=LzQxo00Ue3xG111+pwKjz63uHR9z+ufoXSJACXMSRM1crynJ9QrocrnZkjql4nX5oI hO+LmLOYjLkED2JCFHy9+0vlnwC4ow5y6frmo4voGhRCx0YNkOcTCb0+3++Etvwpd3w5 NPftrXEOxfw6AQiHPcRm1q3biVWbgeacp9CRatVeXBS00YxSkpzXXguK64juVp6GVnVB 7nXVdkx2LZCHADvKH5PiOxnxpPN1Do/kX4mH4j7qdQGViSVYkGi9waOuRmoKD/KSQx25 QxIgZ/Mu58Iq8SIRpSo/IjW9z/kiDtsaK0P55tJOUqAJ2RopJz7Sj/BkFrJxcYkWs1de ampQ== X-Gm-Message-State: AOAM532I0EXw2C4TIo+eOQH2yyIuGvujQ9FLiySbev+CVPaUuAa1FbtL tCASfAbc2cQLqYH78P4v2LQgWahpEo3fAvHcuzeUYmpO7VTeUdmDzorUCrpd3RsVUWyJqv4iZu2 JxvkTM0mE5yR2QA== X-Received: by 2002:aa7:cdc3:: with SMTP id h3mr14237012edw.52.1610378431357; Mon, 11 Jan 2021 07:20:31 -0800 (PST) X-Google-Smtp-Source: ABdhPJxfzQ4g/Xi77uXbjKsyJn2nZrlWGnmTOg2kIy8FkRbXj1BTf3rxwC5MxkZMkcW73D4xDrLEXw== X-Received: by 2002:aa7:cdc3:: with SMTP id h3mr14236981edw.52.1610378431207; Mon, 11 Jan 2021 07:20:31 -0800 (PST) From: =?UTF-8?q?Philippe=20Mathieu-Daud=C3=A9?= To: qemu-devel@nongnu.org Cc: Huacai Chen , Greg Kurz , "Michael S. Tsirkin" , qemu-trivial@nongnu.org, Amit Shah , Dmitry Fleytman , qemu-arm@nongnu.org, John Snow , qemu-s390x@nongnu.org, Paul Durrant , Anthony Perard , Eduardo Habkost , =?UTF-8?q?Philippe=20Mathieu-Daud=C3=A9?= , Gerd Hoffmann , Kevin Wolf , Marcelo Tosatti , Max Reitz , Alex Williamson , Aurelien Jarno , Aleksandar Rikalo , Marcel Apfelbaum , Jason Wang , Peter Maydell , =?UTF-8?q?C=C3=A9dric=20Le=20Goater?= , Halil Pasic , Fam Zheng , qemu-ppc@nongnu.org, Paolo Bonzini , kvm@vger.kernel.org, Stefano Stabellini , xen-devel@lists.xenproject.org, Cornelia Huck , David Hildenbrand , qemu-block@nongnu.org, Christian Borntraeger , Sunil Muthuswamy , David Gibson , Richard Henderson , =?UTF-8?q?Alex=20Benn=C3=A9e?= , Laurent Vivier , Thomas Huth , Stefan Hajnoczi , Jiaxun Yang Subject: [PATCH 1/2] sysemu/runstate: Let runstate_is_running() return bool Date: Mon, 11 Jan 2021 16:20:19 +0100 Message-Id: <20210111152020.1422021-2-philmd@redhat.com> X-Mailer: git-send-email 2.26.2 In-Reply-To: <20210111152020.1422021-1-philmd@redhat.com> References: <20210111152020.1422021-1-philmd@redhat.com> MIME-Version: 1.0 Authentication-Results: relay.mimecast.com; auth=pass smtp.auth=CUSA124A263 smtp.mailfrom=philmd@redhat.com X-Mimecast-Spam-Score: 0 X-Mimecast-Originator: redhat.com Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: quoted-printable X-ZohoMail-DKIM: pass (identity @redhat.com) runstate_check() returns a boolean. runstate_is_running() returns what runstate_check() returns, also a boolean. Signed-off-by: Philippe Mathieu-Daud=C3=A9 Reviewed-by: Alex Benn=C3=A9e Reviewed-by: David Hildenbrand --- include/sysemu/runstate.h | 2 +- softmmu/runstate.c | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/include/sysemu/runstate.h b/include/sysemu/runstate.h index e557f470d42..3ab35a039a0 100644 --- a/include/sysemu/runstate.h +++ b/include/sysemu/runstate.h @@ -6,7 +6,7 @@ =20 bool runstate_check(RunState state); void runstate_set(RunState new_state); -int runstate_is_running(void); +bool runstate_is_running(void); bool runstate_needs_reset(void); bool runstate_store(char *str, size_t size); =20 diff --git a/softmmu/runstate.c b/softmmu/runstate.c index 636aab0addb..c7a67147d17 100644 --- a/softmmu/runstate.c +++ b/softmmu/runstate.c @@ -217,7 +217,7 @@ void runstate_set(RunState new_state) current_run_state =3D new_state; } =20 -int runstate_is_running(void) +bool runstate_is_running(void) { return runstate_check(RUN_STATE_RUNNING); } --=20 2.26.2