From nobody Thu Dec 18 19:38:38 2025 Delivered-To: importer@patchew.org Authentication-Results: mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer=patchew.org@nongnu.org; dmarc=pass(p=none dis=none) header.from=linaro.org ARC-Seal: i=1; a=rsa-sha256; t=1595249856; cv=none; d=zohomail.com; s=zohoarc; b=hmyQCJtPJktbbsnM47kgjolJEFFkxLURJjMaXaXsivDtzU32EO8nXWvhhIB7OitIqm2r+IdRtypgDwLT6c4shItJhdYjz2voXwJda8Yh0k/3u637Z0gzvPXXD2lrx9zY3g758/vXGvguSOO0BjRTrc8cGvMKpURatucjXQwsfY4= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1595249856; h=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=8DHK7n8boT1yEvYZmR1ZTOA6F3ocx/EmfVnNFwz0uCw=; b=YltVX3NCRnSfhwTBYT+cgXD/Z4U2UDsd//B7WYFHvxqdgjn63gpWtqzE3Nual26yBuGzNN/yh8UQ4kbFch10wivqpVjsKnIaZaeyVBgWooX/8DWQuyqn3j+RouA+hbmNObZUljKT1DyY6NSABFViIEWVd60ExVHZkttcrR5LvDg= ARC-Authentication-Results: i=1; mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer=patchew.org@nongnu.org; dmarc=pass header.from= (p=none dis=none) header.from= Return-Path: Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) by mx.zohomail.com with SMTPS id 1595249856482691.4080119323073; Mon, 20 Jul 2020 05:57:36 -0700 (PDT) Received: from localhost ([::1]:42674 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1jxVMN-00040t-8Z for importer@patchew.org; Mon, 20 Jul 2020 08:57:35 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:55754) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1jxVLL-0002JG-Sh for qemu-devel@nongnu.org; Mon, 20 Jul 2020 08:56:31 -0400 Received: from mail-wm1-x336.google.com ([2a00:1450:4864:20::336]:51897) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1jxVLK-0007IV-Aq for qemu-devel@nongnu.org; Mon, 20 Jul 2020 08:56:31 -0400 Received: by mail-wm1-x336.google.com with SMTP id 22so22179888wmg.1 for ; Mon, 20 Jul 2020 05:56:29 -0700 (PDT) Received: from orth.archaic.org.uk (orth.archaic.org.uk. [81.2.115.148]) by smtp.gmail.com with ESMTPSA id p29sm34025403wmi.43.2020.07.20.05.56.27 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 20 Jul 2020 05:56:28 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=from:to:subject:date:message-id:in-reply-to:references:mime-version :content-transfer-encoding; bh=8DHK7n8boT1yEvYZmR1ZTOA6F3ocx/EmfVnNFwz0uCw=; b=hWSP1wPqdV3014Z/4f5laDJKphYuW23U3s4067+XuJSIwTRpyxT7rUVOJ5SezDdb3H 4w6go3U6NR9xnsu/g/tw0pY0uKA34ByzYnRWv0c13e8knDLApX/eJypZHJB4fz6P/GOM stmVIzEp5j/tvkXokP73YuABhMe2hB+yCOi/eBqCdsfc4Eqi1hbFQvhFmv0wA4r+aP76 jpoDUoqBEke+YbQTeyAWuZm50R6RDfaMSAWpfMyV8cMjlKSbSyQTtE4ZLNmfXKCpQJGY 2BfFXM0avZ84PuU2DGVYAX/ZjujB3qsuc2m6HP6Qfj+C5uEl/5cJfhrKOayFydJiHuIn w9ow== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:subject:date:message-id:in-reply-to :references:mime-version:content-transfer-encoding; bh=8DHK7n8boT1yEvYZmR1ZTOA6F3ocx/EmfVnNFwz0uCw=; b=K6fI968Fq5CfPSq9NMmKNXsFrCc8H2H6gBxezJcpGtl6ydL2u3K5/FaCW9ERynTLqf 0FAnmdxXWo9ackdySd869T/eFZvSg978+2SP3+7BiZQwFKtclB2JW3liIpZmRsv5KQON 8k/ERnHMu2FjFGW9LAf6mZWti7gLbBetffmvhkiTxVIwdDv/TvuMWKDxCzklpwJxk2Fc Kie7P1ohTNpucz6STi6Vo3Gistc6tRls9UctpLHZbS/KufkPzA552+2epSlChiGOo8fd r6adP0iVs3kwDB+PDLUF20S+uPpTT57A7KMB3OdwwNgqqkmay74WHPCPL6EabHU0CYQf qNew== X-Gm-Message-State: AOAM531ffeJfIDASApYMD2TvhyucN87iZRS6IytqWCKTv7ApFp8xW9si uzv6ddxoWs4gEh8muX4QDzKPdCVlEjFy6g== X-Google-Smtp-Source: ABdhPJzaOhWfY+IvSFWXftVWy1QAGmvLopASHEfxtS2KczVjZiIZO+eXJIrLIOWaQZji8/YzCPE0fQ== X-Received: by 2002:a1c:2392:: with SMTP id j140mr21081532wmj.6.1595249788625; Mon, 20 Jul 2020 05:56:28 -0700 (PDT) From: Peter Maydell To: qemu-devel@nongnu.org Subject: [PULL 04/12] util: Implement qemu_get_thread_id() for OpenBSD Date: Mon, 20 Jul 2020 13:56:13 +0100 Message-Id: <20200720125621.13460-5-peter.maydell@linaro.org> X-Mailer: git-send-email 2.20.1 In-Reply-To: <20200720125621.13460-1-peter.maydell@linaro.org> References: <20200720125621.13460-1-peter.maydell@linaro.org> MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable Received-SPF: pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; envelope-from=qemu-devel-bounces+importer=patchew.org@nongnu.org; helo=lists.gnu.org; Received-SPF: pass client-ip=2a00:1450:4864:20::336; envelope-from=peter.maydell@linaro.org; helo=mail-wm1-x336.google.com X-detected-operating-system: by eggs.gnu.org: No matching host in p0f cache. That's all we know. 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 autolearn=ham autolearn_force=no X-Spam_action: no action X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: qemu-devel-bounces+importer=patchew.org@nongnu.org Sender: "Qemu-devel" X-ZohoMail-DKIM: pass (identity @linaro.org) Content-Type: text/plain; charset="utf-8" From: David CARLIER Implement qemu_get_thread_id() for OpenBSD hosts, using getthrid(). Signed-off-by: David Carlier Reviewed-by: Brad Smith Message-id: CA+XhMqxD6gQDBaj8tX0CMEj3si7qYKsM8u1km47e_-U7MC37Pg@mail.gmail.= com Reviewed-by: Peter Maydell [PMM: tidied up commit message] Signed-off-by: Peter Maydell --- util/oslib-posix.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/util/oslib-posix.c b/util/oslib-posix.c index 36bf8593f8c..d9236746248 100644 --- a/util/oslib-posix.c +++ b/util/oslib-posix.c @@ -100,6 +100,8 @@ int qemu_get_thread_id(void) return (int)tid; #elif defined(__NetBSD__) return _lwp_self(); +#elif defined(__OpenBSD__) + return getthrid(); #else return getpid(); #endif --=20 2.20.1