Received: from lists.xenproject.org (lists.xenproject.org [192.237.175.120]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange ECDHE (prime256v1) server-signature ECDSA (prime256v1) server-digest SHA256) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 0371F606A322 for ; Thu, 3 Dec 2026 10:53:10 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=suse.com header.i=@suse.com header.a=rsa-sha256 header.s=google header.b=ILJmW9IN Received: from list by lists.xenproject.org with outflank-mailman.1512057.1704365 (Exim 4.92) (envelope-from ) id 1xZ4Qu-0007bq-3Z; Thu, 03 Dec 2026 10:53:00 +0000 X-Outflank-Mailman: Message body and most headers restored to incoming version Received: by outflank-mailman (output) from mailman id 1512057.1704365; Thu, 03 Dec 2026 10:53:00 +0000 Received: from localhost ([127.0.0.1] helo=lists.xenproject.org) by lists.xenproject.org with esmtp (Exim 4.92) (envelope-from ) id 1xZ4Qu-0007bj-0T; Thu, 03 Dec 2026 10:53:00 +0000 Received: by outflank-mailman (input) for mailman id 1512057; Thu, 03 Dec 2026 10:52:58 +0000 Received: from mx.expurgate.net ([194.145.224.10]) by lists.xenproject.org with esmtp (Exim 4.92) (envelope-from ) id 1xZ4Qs-0007a6-MX for xen-devel@lists.xenproject.org; Thu, 03 Dec 2026 10:52:58 +0000 Received: from mx.expurgate.net (helo=localhost) by mx.expurgate.net with esmtp id 1xZ4Qs-003EKX-2o for xen-devel@lists.xenproject.org; Thu, 03 Dec 2026 11:52:58 +0100 Received: from [10.42.69.2] (helo=localhost) by localhost with ESMTP (eXpurgate MTA 0.9.1) (envelope-from ) id 6b1149f5-bab6-0a2a0a5309dd-0a2a4502ed98-42 for ; Thu, 03 Dec 2026 11:52:57 +0100 Received: from [209.85.128.51] (helo=mail-wm1-f51.google.com) by tlsNG-720697.mxtls.expurgate.net with ESMTPS (eXpurgate 4.57.1) (envelope-from ) id 6b114a06-4900-0a2a45020019-d1558033b45c-3 for ; Thu, 03 Dec 2026 11:52:54 +0100 Received: by mail-wm1-f51.google.com with SMTP id 5b1f17b1804b1-4bb69f5b161so92943865e9.0 for ; Thu, 03 Dec 2026 02:52:54 -0800 (PST) Received: from [10.156.60.236] (ip-037-024-206-209.um08.pools.vodafone-ip.de. [37.24.206.209]) by smtp.gmail.com with ESMTPSA id 5b1f17b1804b1-4bbe005f4bdsm60395665e9.9.2026.12.03.02.52.53 (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128); Thu, 03 Dec 2026 02:52:53 -0800 (PST) X-BeenThere: xen-devel@lists.xenproject.org List-Id: Xen developer discussion List-Post: List-Help: List-Subscribe: , Precedence: list Sender: "Xen-devel" Authentication-Results: eu.smtp.expurgate.cloud; dkim=pass header.s=google header.d=suse.com header.i="@suse.com" header.h="Content-Transfer-Encoding:Content-Type:In-Reply-To:Autocrypt:From:Content-Language:References:Cc:To:Subject:User-Agent:MIME-Version:Date:Message-ID" DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=suse.com; s=google; t=1796295174; x=1796899974; darn=lists.xenproject.org; h=content-transfer-encoding:content-type:in-reply-to:autocrypt:from :content-language:references:cc:to:subject:user-agent:mime-version :date:message-id:from:to:cc:subject:date:message-id:reply-to :content-type; bh=+/Kj8jwCdFJhgncVHrZn5TdQ0LgdCOCslrnbdPFP0W4=; b=ILJmW9INxv/BiYOVOOXzIAZLqIhqKTKd6eoAbvFhxLTXh0tnNB65TzK6GTJGTqWUbI nUCR8Fz6WVRC0/7Mvga4tstl5E+PPLs9Br6GPPkhlAjbweoaKkPiqwGdiYBPLJVaQvuY ias64C6nGdqxAvgY+rr88OvZrfpYqDL0jFa40jA7vf/ueFwHayyx2YAoxUNXIUMb7tbw VcgkPrY546wWgvoANyuwIoSgwODoZtFUgcvjL2QslhLj4YdyOQ6s0qynLpHYpEqnDiJ9 udn6YddzsqP5mKTDovJAD4MGcwRcpwE6Cus44t9yXaKLj+xNbuB/uBWqOWmAW0j69VyL R4Jg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20260707; t=1796295174; x=1796899974; h=content-transfer-encoding:content-type:in-reply-to:autocrypt:from :content-language:references:cc:to:subject:user-agent:mime-version :date:message-id:x-gm-gg:x-gm-message-state:from:to:cc:subject:date :message-id:reply-to:content-type; bh=+/Kj8jwCdFJhgncVHrZn5TdQ0LgdCOCslrnbdPFP0W4=; b=z/JIoWwtGdj6Wa94lthrO7DHDwHU8l983Ck+S39hgtNugJowmaGyYrdrTQ/HV8Nhij cBOuvID9jM6esA87IWHRkNy2CE/OmeYjSlk/uqXIIgsuh5RxzKj//OtRVKxr8T64pzo8 IpLI91/L+e5yqIdI93hEu/phTsikITgrB3jBc7QVDJYTjIkN3hj4nDn00/BhvTaqbx8W ZftfwHj+4+ih6UkX2LEniomvRKHh2KRpSYUJ47W2+guD8sihhKl3T4lJYckFegvAm7HX AXn14oUprD6iYLRorwdREFT2RbrhKa15UEep0FqSEy1cNRP8GG3FTqIOU5gxfw5IPbdg aHsw== X-Forwarded-Encrypted: i=1; AL+hErFbtDG0i8VkwknCP86oUYXGnT4F7sG6w8BpRCS99sy1RU9TbYRB4hE1QXliostWdiiAUYCaunFaOPA=@lists.xenproject.org X-Gm-Message-State: APuU4Z8/7pVZWSBJogFB1vAg+VISkfqHV4kREN0Hx9mu6gfuBXjhZwUx vkS00wZ0Afdiyf5pukaP4yypJAxgXMIZPWUO5Du9BR32y6qffblR97pXiTfUyDg3uw== X-Gm-Gg: AZFdTZdYI9vYLy0zeG8l2LbRRL/NT1/q9VT20kDGAPwua8udM5qlw2gFJJUyULH3erN sqdw6f0PR3MmFXZHrY0ULYbqEMpMpRBElt8RLzyQ0GWJ5+v55RhXylktd9crQJVwmTFfGXObTeI +BwupjMp16QjK9Q0guosgQX66x8qGb9tva3duOw65099KJbOVchpgZAUoHRb305JXcscftBaLuV 6OWyU7cUdWjTVFNA1Jm7GtXO/XYo9Nt5bRKYCRccTpjUH+qKQv3oQucyRI12pkOh4qd+eq1s7fI Au9m+PwQC9uyD7NIvsCFK+1JMGy213AG7O1D6IQYF1BqFfp24qIMi3L/j3yrY43vvNwqW/5Y7Gc 4hzHNrVCbPzUPP1DGwW1KNerx8SWiDIQjTe2r68J/8NXXjVih8kmGphf1+7zdVWUXN8zKItFaa8 s61DxT+KohNQiUBNN5akzSgAI+SQVuH29P7OXCMNNs481VLODqNZMcgP1SDhDi46KhFhc6G50jo qJ0tmNEGxkD2F8KnI1zUl1+nXu2tACg40loxCmQQArCv41Z8iqWTUGlrrzTCG9WJaY86l5mpXvb xy1u4sCg6ob5pLTMZ16iw7axbVweWksxMpiPC5GCNeAHSkmw1xKNIf/eUZV8t2jypwPr+Q8BgSi qEVDXIA61CzgPtOWtlrrXWw9T5ChqPZ/bDjTrvA== X-Received: by 2002:a05:600c:c4a6:b0:4bb:8701:a2df with SMTP id 5b1f17b1804b1-4bbe0c607c6mr35379185e9.17.1796295173864; Thu, 03 Dec 2026 02:52:53 -0800 (PST) Message-ID: Date: Thu, 3 Dec 2026 11:52:52 +0100 X-Archived-By: MIME-Version: 1.0 User-Agent: Mozilla Thunderbird Subject: Re: [PATCH v6 0/3] Support multiple ioreq pages To: Julian Vetter Cc: Andrew Cooper , =?UTF-8?Q?Roger_Pau_Monn=C3=A9?= , Michal Orzel , Julien Grall , Stefano Stabellini , xen-devel@lists.xenproject.org, Anthony PERARD References: <20260420093820.825969-1-julian.vetter@vates.tech> <23816f6d-57eb-4567-b6da-93269e6a1c23@suse.com> <1788509352.8631fc262581453bbf619ec5b2062170.1a06b76f0aa000c4f3@vates.tech> <98ea7e14-4787-43a2-81ef-a65493e3cd92@suse.com> <1796292648.8631fc262581453bbf619ec5b2062170.1a23b629fe40005c1a@vates.tech> Content-Language: en-US From: Jan Beulich Autocrypt: addr=jbeulich@suse.com; keydata= xsDiBFk3nEQRBADAEaSw6zC/EJkiwGPXbWtPxl2xCdSoeepS07jW8Ug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4XBJkfwBcpC/XcPzldjv+3 HYudvpdNK3lLujXeA5fLOH+Z/G9WBc5pFVSMocI71I8bT8lIAzreg0WvkWg5V2WZsUMlnDL9 mpwIGFhlbM3gfDMs7MPMu8YQRFVdUvtSpaAs8OFfGQ0ia3LGZcjA6Ik2+xcqscEJzNH+qh8V m5jjp28yZgaqTaRbg3M/+MTbMpicpZuqF4rnB0AQD12/3BNWDR6bmh+EkYSMcEIpQmBM51qM EKYTQGybRCjpnKHGOxG0rfFY1085mBDZCH5Kx0cl0HVJuQKC+dV2ZY5AqjcKwAxpE75MLFkr wkkEGBECAAkFAlk3nEQCGwwACgkQoDSui/t3IH7nnwCfcJWUDUFKdCsBH/E5d+0ZnMQi+G0A nAuWpQkjM1ASeQwSHEeAWPgskBQL In-Reply-To: <1796292648.8631fc262581453bbf619ec5b2062170.1a23b629fe40005c1a@vates.tech> Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 7bit X-purgate-ID: tlsNG-720697/1796295174-F972E6C6-741B0A00/0/0 X-purgate-type: clean X-purgate-size: 3904 X-Spam-Status: No, score=-7.3 required=3.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,HEADER_FROM_DIFFERENT_DOMAINS, MAILING_LIST_MULTI,SPF_HELO_PASS,SPF_PASS,UNPARSEABLE_RELAY, USER_AGENT_SANE_1 autolearn=no autolearn_force=no version=4.0.1 X-Spam-Checker-Version: SpamAssassin 4.0.1 (2024-03-26) on aws-us-west-2-korg-listserv-alma10-1 On 03.12.2026 11:10, Julian Vetter wrote: > > On 9/4/26 10:27 AM, Jan Beulich wrote: > >>> But it looks like both changes in QEMU are for having more vCPU, so >>> having both at the same time might be better. > > Hello Jan and Anthony, > thank you for your replies and sorry for my late reply. I agree, the two > are independent. The only thing they have in common is that each needs > QEMU to change how it maps the ioreq page(s). > >> Growing ioreq_t (in particular the data size it can hold) doesn't have >> anything to do with increased vCPU count, I think. >> >>> So yes, I'm all for less complexity, but I can't ask for this to be a >>> blocker, especially if the other change might takes years. So far, I >>> don't think I've seen any patches for QEMU. >> >> How exactly a new ioreq_t would want to look like remains to be discussed. >> Perhaps we could go an intermediate route here: Add provisions (e.g. a >> full page per vCPU, plus a format identifier at the start of that page), >> allowing the enlarged ioreq_t to be put on top, yet without needing any >> (further) changes to the map/unmap logic? > I understand the goal. We want to only change the map/unmap logic once. > But I'm not sure a full page per vCPU is the right way to get there. > > - It wastes most of each page. ioreq_t is 32 bytes, so a page per vCPU > leaves a lot of space unused. Even an ioreq_t two or four times as large > would still fit dozens of slots per page. With 256 vCPUs that's 256 > pages per ioreq server (and up to 8 servers per domain), where 2 pages > would be enough. ioreq_t can't stay at 32 bytes. When this was discussed, I think it was Andrew who suggested that if we bump, we might as well bump to a full page. While I dislike such wasting of memory / address space, I still indicated I could live with that. If you think bumping by less is better, you will need to make your case mainly with Andrew. > - The series already makes map/unmap independent of the number of pages. > Everything is driven by nr_ioreq_pages(), so a bigger ioreq_t only needs > that calculation to use the slot size. Allocation, vmap(), teardown, > is_ioreq_server_page() and the acquire_resource frame indexing would all > stay as they are. I think that meets your goal without the per-vCPU page > cost. > > - A page-per-vCPU layout can't be the default, since existing device > models expect the packed vcpu_ioreq[] array. It would have to be opt-in > at ioreq server creation, i.e. a new interface, and Xen would have to > support both layouts anyway. > > - On the Xen side it also means tracking up to HVM_MAX_VCPUS pages per > server. That breaks the bounded on-stack array you asked for in v6, so > we'd need a different tracking mechanism. > > Separately from that question, existing device models keep working > unchanged with the packed layout for up to 128 vCPUs. This of course needs to be a goal, no matter what. The reason for the request is that I think it would be better if we didn't need to consider two separate backwards compatibility aspects in qemu (one across your change, and another when we bump ioreq size). > Would you be OK with me sending v7 that keeps the packed layout (with > the remaining v6 comments addressed and nr_ioreq_pages() written in > terms of the slot size), and leaving the layout/format negotiation to > the ioreq_t to a later work? You're of course okay to resubmit in whatever shape you see fit. You may want to bring this up on e.g. a community call for wider discussion, as apparently discussing this on-list doesn't quite get all the input that would be needed. > If you'd prefer patch 3 to wait until the > APIC ID work is done, could patches 1 and 2 go in on their own meanwhile? I'm unsure there. Iirc they aren't very useful without the final patch. Jan