From nobody Mon Feb 9 19:07:28 2026 Delivered-To: importer@patchew.org Received-SPF: pass (zohomail.com: domain of lists.xenproject.org designates 192.237.175.120 as permitted sender) client-ip=192.237.175.120; envelope-from=xen-devel-bounces@lists.xenproject.org; helo=lists.xenproject.org; Authentication-Results: mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of lists.xenproject.org designates 192.237.175.120 as permitted sender) smtp.mailfrom=xen-devel-bounces@lists.xenproject.org; dmarc=pass(p=none dis=none) header.from=linaro.org ARC-Seal: i=1; a=rsa-sha256; t=1687450176; cv=none; d=zohomail.com; s=zohoarc; b=EncMf9ufYmNVZXEsmoN3R6Of2Zc6Oon3+iY/QXhNbS1ou/SVRA9e37++CGbPOh77bjdb4qicbpraMiMVJr1wDunZ0j/pY08Y0iHG8HKcRwxfpCNjWvnZn/DSSAPU6V/DMiwkF2+4n7W9xKRgLtimXtFmSPJLZ7dJNu9SQPKJBFg= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1687450176; h=Content-Type:Content-Transfer-Encoding:Cc:Date:From:In-Reply-To:List-Subscribe:List-Post:List-Id:List-Help:List-Unsubscribe:MIME-Version:Message-ID:References:Sender:Subject:To; bh=KWWds0uHrElgc22pSSxJ50tOp/lAV9kSI84s7Y2g/GM=; b=ghztn1KUOCGS1HOiXS4y7PBwUo7nymOMzlBMdsoZcRxKbApyKVg4AmdlIDsDf4RRU1lcYfFicbJKn3V9hlOC2xBvjFArVHZRZkUmDqFDy9d5Q7yjQ9IJSW3EUZnAUyffB/c4ogcouomiX5xc9iYUS4O86gHeIWbVwDsD5dUh30E= ARC-Authentication-Results: i=1; mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of lists.xenproject.org designates 192.237.175.120 as permitted sender) smtp.mailfrom=xen-devel-bounces@lists.xenproject.org; dmarc=pass header.from= (p=none dis=none) Return-Path: Received: from lists.xenproject.org (lists.xenproject.org [192.237.175.120]) by mx.zohomail.com with SMTPS id 1687450176684675.6094543880716; Thu, 22 Jun 2023 09:09:36 -0700 (PDT) Received: from list by lists.xenproject.org with outflank-mailman.553740.864501 (Exim 4.92) (envelope-from ) id 1qCMrx-0002rB-14; Thu, 22 Jun 2023 16:09:13 +0000 Received: by outflank-mailman (output) from mailman id 553740.864501; Thu, 22 Jun 2023 16:09:12 +0000 Received: from localhost ([127.0.0.1] helo=lists.xenproject.org) by lists.xenproject.org with esmtp (Exim 4.92) (envelope-from ) id 1qCMrw-0002r4-Tk; Thu, 22 Jun 2023 16:09:12 +0000 Received: by outflank-mailman (input) for mailman id 553740; Thu, 22 Jun 2023 16:09:12 +0000 Received: from se1-gles-flk1-in.inumbo.com ([94.247.172.50] helo=se1-gles-flk1.inumbo.com) by lists.xenproject.org with esmtp (Exim 4.92) (envelope-from ) id 1qCMrw-0001Yq-KL for xen-devel@lists.xenproject.org; Thu, 22 Jun 2023 16:09:12 +0000 Received: from mail-wm1-x32a.google.com (mail-wm1-x32a.google.com [2a00:1450:4864:20::32a]) by se1-gles-flk1.inumbo.com (Halon) with ESMTPS id 1fb5d7eb-1117-11ee-8611-37d641c3527e; Thu, 22 Jun 2023 18:09:11 +0200 (CEST) Received: by mail-wm1-x32a.google.com with SMTP id 5b1f17b1804b1-3fa71db41b6so9551795e9.1 for ; Thu, 22 Jun 2023 09:09:11 -0700 (PDT) Received: from localhost.localdomain (230.red-88-28-3.dynamicip.rima-tde.net. [88.28.3.230]) by smtp.gmail.com with ESMTPSA id n6-20020a05600c294600b003f7e4639aabsm19231418wmd.10.2023.06.22.09.09.05 (version=TLS1_3 cipher=TLS_CHACHA20_POLY1305_SHA256 bits=256/256); Thu, 22 Jun 2023 09:09:10 -0700 (PDT) X-Outflank-Mailman: Message body and most headers restored to incoming version X-BeenThere: xen-devel@lists.xenproject.org List-Id: Xen developer discussion List-Unsubscribe: , List-Post: List-Help: List-Subscribe: , Errors-To: xen-devel-bounces@lists.xenproject.org Precedence: list Sender: "Xen-devel" X-Inumbo-ID: 1fb5d7eb-1117-11ee-8611-37d641c3527e DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1687450150; x=1690042150; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to; bh=KWWds0uHrElgc22pSSxJ50tOp/lAV9kSI84s7Y2g/GM=; b=EbM780AWzavorYGjwE/j3EeJGIDw52NMRbKdS1s1/gZWniGA7sDBRZVP2QyfRqO47I 7X7B7xFYS297uGD3scmvxOmMiYP9OTll3eGFYcIQd4FpE0WW7V3oKBilIjfQT/k+/GPn V5BiCj2bgxxHGiIPvjbPJuQdy4VGi6sUnUZ8JyXtmAJEU6CrcXGXcSuxoa+cZFjfMKPW ZWhlpEG7XgwDT27Y537Y1ehWshHrG0ia2ToE68LsnrY1dFG/RpCqknDRqgAY2g/hC1Kd jf7UQOxMVQuZzQgTtEe05+aD9m+AbSf0u4R9D8Us4q4EE6ZIvJq/tj+t/EKcZaxvsqzH qQfw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20221208; t=1687450150; x=1690042150; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=KWWds0uHrElgc22pSSxJ50tOp/lAV9kSI84s7Y2g/GM=; b=eMPNnfVaa4IGtZ985Sayzdo8hXR0fbgfu00mlIf26yqT+Tre6hDjhx//nSYfM4cPwd IS6v/NnIUkicuQujmYM3qg8012p27O5Umm/j953tfS3EVKxXhhX5S2JabwEyMw+WboNB +Ac4TdafIqmTsKe4qZUWPD1SoKjdpchqbwlGJiySa+VHTdkmjj+3n2Ib1REqL+L9DT8+ bLrv6Hc8BWCyWFoTKrlYWXnw1pn+pbUuiIaiN4w2gB8TPigSUqzvse0i2Eccbqu9s40P 1uaSu530UNrwZTd1ojZcVM1G/9idgjeldNSdf8LNXu1kzPC51Gk4/8KX8/B6hUlFujah KrEg== X-Gm-Message-State: AC+VfDwprUWPgSm+sMjoy0Ub8W1fddfWnAOssIVwx3hIzvGr0Ww0zye1 N24xMp8zTAy4RV68eArBDTe3bg== X-Google-Smtp-Source: ACHHUZ51xfqu7ycVqyxzIHVhQQRD4BRESLxxv3gkwPL1UAb0nB49UkufaCFZkef5SDfT9giEDTGvXg== X-Received: by 2002:a1c:6a0e:0:b0:3fa:78d1:572 with SMTP id f14-20020a1c6a0e000000b003fa78d10572mr642130wmc.0.1687450150672; Thu, 22 Jun 2023 09:09:10 -0700 (PDT) From: =?UTF-8?q?Philippe=20Mathieu-Daud=C3=A9?= To: qemu-devel@nongnu.org Cc: Reinoud Zandijk , qemu-arm@nongnu.org, kvm@vger.kernel.org, Marcel Apfelbaum , Stefano Stabellini , Anthony Perard , Yanan Wang , =?UTF-8?q?Philippe=20Mathieu-Daud=C3=A9?= , Peter Maydell , Roman Bolshakov , Paolo Bonzini , Paul Durrant , Sunil Muthuswamy , Alexander Graf , Richard Henderson , xen-devel@lists.xenproject.org, Eduardo Habkost , Cameron Esfahani Subject: [PATCH v2 04/16] accel: Fix a leak on Windows HAX Date: Thu, 22 Jun 2023 18:08:11 +0200 Message-Id: <20230622160823.71851-5-philmd@linaro.org> X-Mailer: git-send-email 2.38.1 In-Reply-To: <20230622160823.71851-1-philmd@linaro.org> References: <20230622160823.71851-1-philmd@linaro.org> MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: quoted-printable X-ZohoMail-DKIM: pass (identity @linaro.org) X-ZM-MESSAGEID: 1687450177236100001 hThread is only used on the error path in hax_kick_vcpu_thread(). Fixes: b0cb0a66d6 ("Plumb the HAXM-based hardware acceleration support") Signed-off-by: Philippe Mathieu-Daud=C3=A9 Reviewed-by: Richard Henderson --- target/i386/hax/hax-all.c | 3 +++ 1 file changed, 3 insertions(+) diff --git a/target/i386/hax/hax-all.c b/target/i386/hax/hax-all.c index 3e5992a63b..a2321a1eff 100644 --- a/target/i386/hax/hax-all.c +++ b/target/i386/hax/hax-all.c @@ -205,6 +205,9 @@ int hax_vcpu_destroy(CPUState *cpu) */ hax_close_fd(vcpu->fd); hax_global.vm->vcpus[vcpu->vcpu_id] =3D NULL; +#ifdef _WIN32 + CloseHandle(cpu->hThread); +#endif g_free(vcpu); return 0; } --=20 2.38.1