From nobody Tue Aug 25 05:47:04 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=quarantine dis=none) header.from=suse.com ARC-Seal: i=1; a=rsa-sha256; t=1782904598; cv=none; d=zohomail.com; s=zohoarc; b=nz6AiVMnuWmLkwU8EuadytJoQOG1MwkLHqa5M26TaT0sn+Al7C8SIi5Ka9uU0jdW8t676Y4ZXH7S3upS1GsaVpihazBbHQpSog77FwfFxP56amNG54wOTjDJY/jkZOolxRnVCd+4vS/a8+mC9wL1ikRegvrYi9dd4wlfBIaG7I0= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1782904598; h=Content-Transfer-Encoding:Cc:Cc:Date:Date:From:From:In-Reply-To:List-Subscribe:List-Post:List-Id:List-Help:List-Unsubscribe:MIME-Version:Message-ID:References:Sender:Subject:Subject:To:To:Message-Id:Reply-To; bh=Zaxfdhd/2xyg/xgn5cvnR+sq5s7uLGSyRRwH/Mnptzo=; b=Otcw5lwFR5+hq/+xsLo0I1YZdTDGxAoCFYrz2HRX1c9jVP6Qc4gIWefCh/HLnQPnNHZu2B02HxGSf0W/1owGcyNUEfGSdk1fcPikXmiY0sXXIN7HM+vQk4BK7rf3CKghm+HDBNXgfKdQzbTBAIK4yWdYuRIWvtC7nHcOeDs6hUw= 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=quarantine dis=none) Return-Path: Received: from lists.xenproject.org (lists.xenproject.org [192.237.175.120]) by mx.zohomail.com with SMTPS id 1782904598566280.2318379672364; Wed, 1 Jul 2026 04:16:38 -0700 (PDT) Received: from list by lists.xenproject.org with outflank-mailman.1349771.1607420 (Exim 4.92) (envelope-from ) id 1wesvQ-00011j-RT; Wed, 01 Jul 2026 11:16:16 +0000 Received: by outflank-mailman (output) from mailman id 1349771.1607420; Wed, 01 Jul 2026 11:16:16 +0000 Received: from localhost ([127.0.0.1] helo=lists.xenproject.org) by lists.xenproject.org with esmtp (Exim 4.92) (envelope-from ) id 1wesvQ-00011c-NC; Wed, 01 Jul 2026 11:16:16 +0000 Received: by outflank-mailman (input) for mailman id 1349771; Wed, 01 Jul 2026 11:16:15 +0000 Received: from mx.expurgate.net ([195.190.135.20]) by lists.xenproject.org with esmtp (Exim 4.92) (envelope-from ) id 1wesvP-00010r-Ns for xen-devel@lists.xenproject.org; Wed, 01 Jul 2026 11:16:15 +0000 Received: from mx.expurgate.net (helo=localhost) by mx.expurgate.net with esmtp id 1wesvP-00AhOL-4G for xen-devel@lists.xenproject.org; Wed, 01 Jul 2026 13:16:15 +0200 Received: from [10.42.69.12] (helo=localhost) by localhost with ESMTP (eXpurgate MTA 0.9.1) (envelope-from ) id 6a44f6f4-e002-0a2a0a5209dd-0a2a450c89fa-44 for ; Wed, 01 Jul 2026 13:16:15 +0200 Received: from [195.135.223.130] (helo=smtp-out1.suse.de) by tlsNG-d25034.mxtls.expurgate.net with ESMTPS (eXpurgate 4.57.1) (envelope-from ) id 6a44f6fe-f399-0a2a450c0019-c387df82dc56-3 for ; Wed, 01 Jul 2026 13:16:14 +0200 Received: from imap1.dmz-prg2.suse.org (imap1.dmz-prg2.suse.org [IPv6:2a07:de40:b281:104:10:150:64:97]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (No client certificate requested) by smtp-out1.suse.de (Postfix) with ESMTPS id 84EC273A63; Wed, 1 Jul 2026 11:16:14 +0000 (UTC) Received: from imap1.dmz-prg2.suse.org (localhost [127.0.0.1]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (No client certificate requested) by imap1.dmz-prg2.suse.org (Postfix) with ESMTPS id 62023779AA; Wed, 1 Jul 2026 11:16:14 +0000 (UTC) Received: from dovecot-director2.suse.de ([2a07:de40:b281:106:10:150:64:167]) by imap1.dmz-prg2.suse.org with ESMTPSA id 8NijFv72RGrZAQAAD6G6ig (envelope-from ); Wed, 01 Jul 2026 11:16:14 +0000 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" Authentication-Results: eu.smtp.expurgate.cloud; dkim=pass header.s=susede1 header.d=suse.com header.i="@suse.com" header.h="From:Date:Message-ID:To:Cc:MIME-Version:Content-Transfer-Encoding:In-Reply-To:References"; dkim=pass header.s=susede1 header.d=suse.com header.i="@suse.com" header.h="From:Date:Message-ID:To:Cc:MIME-Version:Content-Transfer-Encoding:In-Reply-To:References" DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=suse.com; s=susede1; t=1782904574; h=from:from:reply-to:date:date:message-id:message-id:to:to:cc:cc: mime-version:mime-version: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=Zaxfdhd/2xyg/xgn5cvnR+sq5s7uLGSyRRwH/Mnptzo=; b=JhVt65x1JsQycqKDgFnCPOiZKlZvFyiIG+Yag8Eg2mF0F/RPNqYvuM3CoqLPktKDgc8RUh sWkv/C0Pu55RkUH+1tuE0R6syoBBdpE23T3/7GOrhi9yi6ugkKaOkudPF0ZQawwpR97Vw3 qQJrINcEdbhfiM8UIHMqIu6ZUgUaUjk= Authentication-Results: smtp-out1.suse.de; dkim=pass header.d=suse.com header.s=susede1 header.b=JhVt65x1 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=suse.com; s=susede1; t=1782904574; h=from:from:reply-to:date:date:message-id:message-id:to:to:cc:cc: mime-version:mime-version: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=Zaxfdhd/2xyg/xgn5cvnR+sq5s7uLGSyRRwH/Mnptzo=; b=JhVt65x1JsQycqKDgFnCPOiZKlZvFyiIG+Yag8Eg2mF0F/RPNqYvuM3CoqLPktKDgc8RUh sWkv/C0Pu55RkUH+1tuE0R6syoBBdpE23T3/7GOrhi9yi6ugkKaOkudPF0ZQawwpR97Vw3 qQJrINcEdbhfiM8UIHMqIu6ZUgUaUjk= From: Juergen Gross To: xen-devel@lists.xenproject.org Cc: Juergen Gross , Anthony PERARD Subject: [PATCH 1/3] tools/libxl: don't rely on xc_vcpu_setaffinity() returned cpumaps Date: Wed, 1 Jul 2026 13:16:04 +0200 Message-ID: <20260701111606.4063972-2-jgross@suse.com> X-Mailer: git-send-email 2.54.0 In-Reply-To: <20260701111606.4063972-1-jgross@suse.com> References: <20260701111606.4063972-1-jgross@suse.com> MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable X-Spam-Flag: NO X-Rspamd-Action: no action X-Spam-Level: X-Spamd-Result: default: False [-3.01 / 50.00]; BAYES_HAM(-3.00)[99.99%]; MID_CONTAINS_FROM(1.00)[]; NEURAL_HAM_LONG(-1.00)[-1.000]; R_MISSING_CHARSET(0.50)[]; R_DKIM_ALLOW(-0.20)[suse.com:s=susede1]; NEURAL_HAM_SHORT(-0.20)[-1.000]; MIME_GOOD(-0.10)[text/plain]; MX_GOOD(-0.01)[]; TO_MATCH_ENVRCPT_ALL(0.00)[]; FUZZY_RATELIMITED(0.00)[rspamd.com]; DKIM_SIGNED(0.00)[suse.com:s=susede1]; ARC_NA(0.00)[]; MIME_TRACE(0.00)[0:+]; RBL_SPAMHAUS_BLOCKED_OPENRESOLVER(0.00)[2a07:de40:b281:104:10:150:64:97:from]; RCVD_TLS_ALL(0.00)[]; DKIM_TRACE(0.00)[suse.com:+]; FROM_EQ_ENVFROM(0.00)[]; FROM_HAS_DN(0.00)[]; TO_DN_SOME(0.00)[]; RCVD_COUNT_TWO(0.00)[2]; RCVD_VIA_SMTP_AUTH(0.00)[]; RECEIVED_SPAMHAUS_BLOCKED_OPENRESOLVER(0.00)[2a07:de40:b281:106:10:150:64:167:received]; RCPT_COUNT_THREE(0.00)[3]; DBL_BLOCKED_OPENRESOLVER(0.00)[imap1.dmz-prg2.suse.org:helo,imap1.dmz-prg2.suse.org:rdns,suse.com:email,suse.com:dkim,suse.com:mid] X-Rspamd-Server: rspamd2.dmz-prg2.suse.org X-Rspamd-Queue-Id: 84EC273A63 X-Spam-Score: -3.01 X-purgate-ID: tlsNG-d25034/1782904574-A8AA8D51-0726AD08/0/0 X-purgate-type: clean X-purgate-size: 1341 X-ZohoMail-DKIM: pass (identity @suse.com) X-ZM-MESSAGEID: 1782904599392158500 Content-Type: text/plain; charset="utf-8" In order to prepare for XEN_DOMCTL_setvcpuaffinity no longer returning the effective affinity settings, use xc_vcpu_getaffinity() for getting the effective affinities after having set them. Signed-off-by: Juergen Gross --- tools/libs/light/libxl_sched.c | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/tools/libs/light/libxl_sched.c b/tools/libs/light/libxl_sched.c index 2d6635dae7..2f6a70aef5 100644 --- a/tools/libs/light/libxl_sched.c +++ b/tools/libs/light/libxl_sched.c @@ -69,6 +69,15 @@ static int libxl__set_vcpuaffinity(libxl_ctx *ctx, uint3= 2_t domid, * is possible that Xen will use something different from what we asked * for various reasons. If that's the case, report it. */ + if ((cpumap_hard || cpumap_soft) && + xc_vcpu_getaffinity(ctx->xch, domid, vcpuid, + cpumap_hard ? hard.map : NULL, + cpumap_soft ? soft.map : NULL, + flags & ~XEN_VCPUAFFINITY_FORCE)) { + LOGED(ERROR, domid, "Checking vcpu affinity"); + rc =3D ERROR_FAIL; + goto out; + } if (cpumap_hard && !libxl_bitmap_equal(cpumap_hard, &hard, 0)) LOGD(DEBUG, domid, "New hard affinity for vcpu %d has unreachable = cpus", vcpuid); --=20 2.54.0