From patchwork Wed Apr 20 18:05:44 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: Richard Henderson X-Patchwork-Id: 563973 Delivered-To: patch@linaro.org Received: by 2002:a05:7000:6886:0:0:0:0 with SMTP id m6csp4402869map; Wed, 20 Apr 2022 11:13:21 -0700 (PDT) X-Google-Smtp-Source: ABdhPJxz9X9W9KlhnIHa6NhJbX5j7fAvFnOof4sEpTyf/LqSzVWZL6RfqCC+ew9GbyWSAR7xhqQV X-Received: by 2002:a25:f505:0:b0:624:f6f9:7bf3 with SMTP id a5-20020a25f505000000b00624f6f97bf3mr20074383ybe.465.1650478401383; Wed, 20 Apr 2022 11:13:21 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1650478401; cv=none; d=google.com; s=arc-20160816; b=kBSlUck+cZ+kxFSH+MJnwVsXrZF4AXkcCwsDN+ri0K7GMNWPlnKS/gNj8P+9mga0nb rJytLUN32zObCui/FEmwBRc19LA3POWiDvgb96rH7IEHf1rlMV6a8s97IsFzlXTOcpM8 IqksmXCI7C3r63d1xA0osUNUiyWFW9IoOL9Gu38tjUKb5ZqhrS7WDYVZ9whQLbhbkyxw yVmxgPxApE+O7s3olKstceLPx4uBw/lLYy3jJSP3CkUWteTObytVlK5+4xSsqA8xkpj/ Zf/dp4Mg3lz4t1S/UNJSVmPueJQJbstm8Fs1DG/mh6CWfZMyuKqKGCGuJBPt2KhKoK3q qDSw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=sender:errors-to:cc:list-subscribe:list-help:list-post:list-archive :list-unsubscribe:list-id:precedence:content-transfer-encoding :mime-version:references:in-reply-to:message-id:date:subject:to:from :dkim-signature; bh=9Acrdd8Fm08SC2Pv9DkKl+01rcq3tkQdmCCMEajfWbE=; b=bb5XGuuUm0l6hg0qgk2HADaLa+PcdO095fVZqMZPPgPNcyTGdVK2hZtmishHB5lzqX 7oPPKR1vU0ORvImn6UFExNVtpSxUc1KQqDCDoCrteL7X6iqLvh4jydPTmxAbgVLkkldf MGjWJtrbmS8+7w1QUWsT0fbDjO4cktM8kZ9Z5JYnkmD3D06sr63jiU8LCHmXIZ+Ex3oO C7TrVVlH4YGk5q4uXeG3OtikyziBrvF2FLQ7R7Jd1oAlf9ZwsqCq84a9pbb0lpZtkwzC FCbTTKwf7cJ54gw4wDarUVef6qLm52FWVXT0TJ3U7JhqgsPdbT1eVbThboJQwFkcgz/6 wkQQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=v4Wr19uf; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from lists.gnu.org (lists.gnu.org. [209.51.188.17]) by mx.google.com with ESMTPS id u125-20020a0dd283000000b002ec34074889si565415ywd.344.2022.04.20.11.13.21 for (version=TLS1_2 cipher=ECDHE-ECDSA-CHACHA20-POLY1305 bits=256/256); Wed, 20 Apr 2022 11:13:21 -0700 (PDT) Received-SPF: pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; Authentication-Results: mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=v4Wr19uf; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: from localhost ([::1]:42734 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1nhEpM-0001Yk-Re for patch@linaro.org; Wed, 20 Apr 2022 14:13:20 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:53116) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1nhEih-0005Kd-I4 for qemu-devel@nongnu.org; Wed, 20 Apr 2022 14:06:30 -0400 Received: from mail-pl1-x630.google.com ([2607:f8b0:4864:20::630]:35435) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1nhEig-0001B6-3r for qemu-devel@nongnu.org; Wed, 20 Apr 2022 14:06:27 -0400 Received: by mail-pl1-x630.google.com with SMTP id b7so2525366plh.2 for ; Wed, 20 Apr 2022 11:06:25 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=9Acrdd8Fm08SC2Pv9DkKl+01rcq3tkQdmCCMEajfWbE=; b=v4Wr19ufbUX3KmnVoQbvzqg5KQkDOfHvzNLNIXrerpRLPtDD9WRWpuZTY3xm9RKMJh iB6Di7Dkr3+ZprDgnnaP7IOCdL8H5iLI0KYuDvqi7ejHuNquYypZJLNWcn7zzQjFRbDp 9EOsIWF0e3YruvngcE5IFbC7u9Zat1E8cou/sAZZTsbwVhGmVGpW8Ag3QhedjDqOL9jX HjowrYmPJ1t7Lap+0DVnlAZvdoqyhIuT+4N8dwMi/IXKcWzkU0ycvp13Rr0AH9KhCxu2 r/oUOsxit18INI+EeKtkXuxIhCy5I7jyL4SYqHayYYFVQaBrYyfmz7eR/5DD+LRIYMeR MEhA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references:mime-version:content-transfer-encoding; bh=9Acrdd8Fm08SC2Pv9DkKl+01rcq3tkQdmCCMEajfWbE=; b=bq8FUYWRZMjgzinLDhFX9mIqFUMUVcfjyCN22Xzi81stc30WfPGDHRRb0kRLOMbzgz UHFHA5tCFHad9yJ6XtuqAQuMeH55t+BIZup7JsaLU9+Rw4VtihhOU+JI76esY3lO111y AAWy1Hbl7w5k5Iu5VisWeMYEz8e7Cstnm8Sg/9hTYbzwaZhW1Fr7vGnwJMOTdKvIjTda bMBOWG0JeMdFvgUPVo7ps4BZSIdQlQ3bJyZv6G4LwuMXu93g0AIAYdO7SxzSQwSoqgf2 GUWJWLEF+1iXRflLEeTu6w+cCAl6o7syfJl4fEdE1QLdyw9MSoo0Cb31UJ6dyV8Ho/rI 6nkg== X-Gm-Message-State: AOAM530NDr+A8LCsyTZGXN4Z/vYYC6WxLnSRK/CEh3+1KH+kkoPO7IKt 68snt633cYoSidcWvo2cCZ+Bak0mgAr5WA== X-Received: by 2002:a17:903:2487:b0:159:bce:4e1a with SMTP id p7-20020a170903248700b001590bce4e1amr12182604plw.4.1650477984860; Wed, 20 Apr 2022 11:06:24 -0700 (PDT) Received: from stoup.. (174-21-142-130.tukw.qwest.net. [174.21.142.130]) by smtp.gmail.com with ESMTPSA id i2-20020a17090a058200b001d2fc489b8asm56681pji.25.2022.04.20.11.06.24 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 20 Apr 2022 11:06:24 -0700 (PDT) From: Richard Henderson To: qemu-devel@nongnu.org Subject: [PULL 05/39] os-posix: Use qemu_log_enabled Date: Wed, 20 Apr 2022 11:05:44 -0700 Message-Id: <20220420180618.1183855-6-richard.henderson@linaro.org> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20220420180618.1183855-1-richard.henderson@linaro.org> References: <20220420180618.1183855-1-richard.henderson@linaro.org> MIME-Version: 1.0 Received-SPF: pass client-ip=2607:f8b0:4864:20::630; envelope-from=richard.henderson@linaro.org; helo=mail-pl1-x630.google.com X-Spam_score_int: -20 X-Spam_score: -2.1 X-Spam_bar: -- X-Spam_report: (-2.1 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, RCVD_IN_DNSWL_NONE=-0.0001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001, T_SCC_BODY_TEXT_LINE=-0.01 autolearn=ham autolearn_force=no X-Spam_action: no action X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: =?utf-8?q?Alex_Benn=C3=A9e?= , =?utf-8?q?Philipp?= =?utf-8?q?e_Mathieu-Daud=C3=A9?= Errors-To: qemu-devel-bounces+patch=linaro.org@nongnu.org Sender: "Qemu-devel" Do not reference qemu_logfile directly; use the predicate provided by qemu/log.h. Reviewed-by: Alex Bennée Reviewed-by: Philippe Mathieu-Daudé Signed-off-by: Richard Henderson Message-Id: <20220417183019.755276-6-richard.henderson@linaro.org> --- os-posix.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/os-posix.c b/os-posix.c index ee765f047d..faf6e6978b 100644 --- a/os-posix.c +++ b/os-posix.c @@ -291,7 +291,7 @@ void os_setup_post(void) dup2(fd, 0); dup2(fd, 1); /* In case -D is given do not redirect stderr to /dev/null */ - if (!qemu_logfile) { + if (!qemu_log_enabled()) { dup2(fd, 2); }