From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from gate001.proxmox.com (gate001.proxmox.com [45.144.208.40]) by lore.proxmox.com (Postfix) with ESMTPS id D0B481FF0B7 for ; Fri, 02 Oct 2026 15:39:19 +0200 (CEST) Received: from gate001.proxmox.com (localhost.localdomain [127.0.0.1]) by gate001.proxmox.com (Proxmox) with ESMTP id CF7A3216FB; Fri, 02 Oct 2026 15:39:15 +0200 (CEST) Mime-Version: 1.0 Content-Transfer-Encoding: quoted-printable Content-Type: text/plain; charset=UTF-8 Date: Fri, 02 Oct 2026 15:39:09 +0200 Message-Id: Subject: Re: [PATCH docs/guest-common/qemu-server v5 0/9] add new pci passthrough specific hookscript phase From: "Elias Huhsovitz" To: "Dominik Csapak" , X-Mailer: aerc 0.20.0 References: <20260923070522.434715-1-d.csapak@proxmox.com> In-Reply-To: <20260923070522.434715-1-d.csapak@proxmox.com> X-Bm-Milter-Handled: 55990f41-d878-4baa-be0a-ee34c49e34d2 X-Bm-Transport-Timestamp: 1790948349991 X-SPAM-LEVEL: Spam detection results: 0 AWL 0.554 Adjusted score from AWL reputation of From: address DMARC_MISSING 0.1 Missing DMARC policy KAM_DMARC_STATUS 0.01 Test Rule for DKIM or SPF Failure with Strict Alignment (newer systems) RCVD_IN_DNSWL_MED -2.3 Sender listed at https://www.dnswl.org/, medium trust SPF_HELO_NONE 0.001 SPF: HELO does not publish an SPF Record SPF_PASS -0.001 SPF: sender matches SPF record Message-ID-Hash: R4YZUWGNHUOBFUJ37FWOW2LXNVUJ3P3S X-Message-ID-Hash: R4YZUWGNHUOBFUJ37FWOW2LXNVUJ3P3S X-MailFrom: e.huhsovitz@proxmox.com X-Mailman-Rule-Misses: dmarc-mitigation; no-senders; approved; loop; banned-address; emergency; member-moderation; nonmember-moderation; administrivia; implicit-dest; max-recipients; max-size; news-moderation; no-subject; digests; suspicious-header X-Mailman-Version: 3.3.10 Precedence: list List-Id: Proxmox VE development discussion List-Help: List-Owner: List-Post: List-Subscribe: List-Unsubscribe: Testing ------- Tested this by setting frame_rate_limiter=3D1 and frame_rate_limiter=3D0 on NVIDIA RTX A5000 with vGPU Driver Version: 595.91.04 With frame_rate_limiter=3D1: output of: nvidia-smi vgpu -q Frame Rate Limit : 45 FPS With frame_rate_limiter=3D0: output of: nvidia-smi vgpu -q Frame Rate Limit : N/A Changes v4->v5 -------------- Changes also seem sensible! Consider this: Reviewed-by: Elias Huhsovitz Tested-by: Elias Huhsovitz On Wed Sep 23, 2026 at 9:04 AM CEST, Dominik Csapak wrote: > this series adds a new phase to the guest hookscript that is called for e= ach > passed throug pci device after it's prepared, but before the qemu process= is > started. > > See the last qemu-server commit for why that is interesting. > > changes from v4: > * fixed code style > * improved comment for ENV copying > * added cleanup commit for renaming variable > * added commit to downgrade to warn for unknown phases in example hookscr= ipt > > changes from v3: > * rebase on current master > * fix `local %ENV` clearing the whole environment instead of > just shadowing it, so the hookscript keeps the inherited environment > * split the uuid handling out of the refactoring commit > * call the hookscript once for both the mdev and the plain passthrough > case instead of duplicating the call in both branches > * add missing `use PVE::GuestHelpers;` > * move the new phase before 'post-start' to match the actual call > order, document that PVE_HOOK_MDEV_UUID is only set for mdevs, and > mention what the phase is useful for > * fix typos > > changes from v2: > * rebase on current master > * prefix hook script env variables with 'PVE_HOOK_' > > > pve-guest-common: > > Dominik Csapak (1): > helpers: exec hookscript: add optional parameters > > src/PVE/GuestHelpers.pm | 12 +++++++++++- > 1 file changed, 11 insertions(+), 1 deletion(-) > > > qemu-server: > > Dominik Csapak (6): > pci: mdev preparation: always generate local uuid first > pci: nvidia vgpu: correct wrong comment about uuid > pci: factor 'prepare_pci_devices' out to PVE::QemuServer::PCI module > code cleanup: pci: rename 'd' variable to 'pci_device' > pci: preparation: mdev: only generate uuid once > pci: call hookscript for each prepared pci device > > src/PVE/QemuServer.pm | 45 ++++++--------------------------- > src/PVE/QemuServer/PCI.pm | 52 +++++++++++++++++++++++++++++++++++++++ > 2 files changed, 60 insertions(+), 37 deletions(-) > > > pve-docs: > > Dominik Csapak (2): > examples: add new hookscript phase to example hookscript > examples: downgrade 'die' in example hookscript to 'warn' > > examples/guest-example-hookscript.pl | 31 +++++++++++++++++++++++++++- > 1 file changed, 30 insertions(+), 1 deletion(-) > > > Summary over all repositories: > 4 files changed, 101 insertions(+), 39 deletions(-)