Patch Detail
get:
Show a patch.
patch:
Update a patch.
put:
Update a patch.
GET /api/patches/2195844/?format=api
{ "id": 2195844, "url": "http://patchwork.ozlabs.org/api/patches/2195844/?format=api", "web_url": "http://patchwork.ozlabs.org/project/qemu-devel/patch/20260212062522.99565-8-anisinha@redhat.com/", "project": { "id": 14, "url": "http://patchwork.ozlabs.org/api/projects/14/?format=api", "name": "QEMU Development", "link_name": "qemu-devel", "list_id": "qemu-devel.nongnu.org", "list_email": "qemu-devel@nongnu.org", "web_url": "", "scm_url": "", "webscm_url": "", "list_archive_url": "", "list_archive_url_format": "", "commit_url_format": "" }, "msgid": "<20260212062522.99565-8-anisinha@redhat.com>", "list_archive_url": null, "date": "2026-02-12T06:24:51", "name": "[v4,07/31] accel/kvm: notify when KVM VM file fd is about to be changed", "commit_ref": null, "pull_url": null, "state": "new", "archived": false, "hash": "a67e0d8dbf1bed70c12d1a93bbc177711ed794e8", "submitter": { "id": 86030, "url": "http://patchwork.ozlabs.org/api/people/86030/?format=api", "name": "Ani Sinha", "email": "anisinha@redhat.com" }, "delegate": null, "mbox": "http://patchwork.ozlabs.org/project/qemu-devel/patch/20260212062522.99565-8-anisinha@redhat.com/mbox/", "series": [ { "id": 491935, "url": "http://patchwork.ozlabs.org/api/series/491935/?format=api", "web_url": "http://patchwork.ozlabs.org/project/qemu-devel/list/?series=491935", "date": "2026-02-12T06:24:45", "name": "Introduce support for confidential guest reset (x86)", "version": 4, "mbox": "http://patchwork.ozlabs.org/series/491935/mbox/" } ], "comments": "http://patchwork.ozlabs.org/api/patches/2195844/comments/", "check": "pending", "checks": "http://patchwork.ozlabs.org/api/patches/2195844/checks/", "tags": {}, "related": [], "headers": { "Return-Path": "<qemu-devel-bounces+incoming=patchwork.ozlabs.org@nongnu.org>", "X-Original-To": "incoming@patchwork.ozlabs.org", "Delivered-To": "patchwork-incoming@legolas.ozlabs.org", "Authentication-Results": [ "legolas.ozlabs.org;\n\tdkim=pass (1024-bit key;\n unprotected) header.d=redhat.com header.i=@redhat.com header.a=rsa-sha256\n header.s=mimecast20190719 header.b=Z6OBh5Nk;\n\tdkim=pass (2048-bit key;\n unprotected) header.d=redhat.com header.i=@redhat.com header.a=rsa-sha256\n header.s=google header.b=ppkmw8/s;\n\tdkim-atps=neutral", "legolas.ozlabs.org;\n spf=pass (sender SPF authorized) smtp.mailfrom=nongnu.org\n (client-ip=209.51.188.17; helo=lists.gnu.org;\n envelope-from=qemu-devel-bounces+incoming=patchwork.ozlabs.org@nongnu.org;\n receiver=patchwork.ozlabs.org)" ], "Received": [ "from lists.gnu.org (lists.gnu.org [209.51.188.17])\n\t(using TLSv1.2 with cipher ECDHE-ECDSA-AES256-GCM-SHA384 (256/256 bits))\n\t(No client certificate requested)\n\tby legolas.ozlabs.org (Postfix) with ESMTPS id 4fBQP16sRJz1xvb\n\tfor <incoming@patchwork.ozlabs.org>; Thu, 12 Feb 2026 17:28:53 +1100 (AEDT)", "from localhost ([::1] helo=lists1p.gnu.org)\n\tby lists.gnu.org with esmtp (Exim 4.90_1)\n\t(envelope-from <qemu-devel-bounces@nongnu.org>)\n\tid 1vqQ9T-0007gW-J4; Thu, 12 Feb 2026 01:26:11 -0500", "from eggs.gnu.org ([2001:470:142:3::10])\n by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256)\n (Exim 4.90_1) (envelope-from <anisinha@redhat.com>)\n id 1vqQ9K-0007ae-Eu\n for qemu-devel@nongnu.org; Thu, 12 Feb 2026 01:26:02 -0500", "from us-smtp-delivery-124.mimecast.com ([170.10.133.124])\n by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256)\n (Exim 4.90_1) (envelope-from <anisinha@redhat.com>)\n id 1vqQ9J-0005Dl-1E\n for qemu-devel@nongnu.org; Thu, 12 Feb 2026 01:26:02 -0500", "from mail-pg1-f197.google.com (mail-pg1-f197.google.com\n [209.85.215.197]) by relay.mimecast.com with ESMTP with STARTTLS\n (version=TLSv1.3, cipher=TLS_AES_256_GCM_SHA384) id\n us-mta-624-PLXnubtUPxOf_Zz1lpyTpQ-1; Thu, 12 Feb 2026 01:25:58 -0500", "by mail-pg1-f197.google.com with SMTP id\n 41be03b00d2f7-c6dde310601so3630480a12.1\n for <qemu-devel@nongnu.org>; Wed, 11 Feb 2026 22:25:58 -0800 (PST)", "from rhel9-box.lan ([122.164.27.113])\n by smtp.googlemail.com with ESMTPSA id\n 98e67ed59e1d1-3567e7d95d8sm4894122a91.2.2026.02.11.22.25.54\n (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256);\n Wed, 11 Feb 2026 22:25:56 -0800 (PST)" ], "DKIM-Signature": [ "v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com;\n s=mimecast20190719; t=1770877560;\n h=from:from:reply-to:subject:subject:date:date:message-id:message-id:\n to:to:cc:cc:mime-version:mime-version:\n content-transfer-encoding:content-transfer-encoding:\n in-reply-to:in-reply-to:references:references;\n bh=+nJSPq641/KU7PW2uyxECihx9MetPiHgqWCX0M+BsoQ=;\n b=Z6OBh5NkH1u8KfS0XdznSciIGvUIGde1X0Io1I46G3mrUzZJxU2hH7lF7szIsXyLY2aAqZ\n 9576eFYMs4ayTqnrG5IpzSlKOAFgmcdSKpEGZq9uliaMclclleExTtgOnYwAuFXNkVAQ3V\n lYH8P0vGZvKjreuDtAZDT2m6bgh/1W0=", "v=1; a=rsa-sha256; c=relaxed/relaxed;\n d=redhat.com; s=google; t=1770877557; x=1771482357; darn=nongnu.org;\n h=content-transfer-encoding:mime-version:references:in-reply-to\n :message-id:date:subject:cc:to:from:from:to:cc:subject:date\n :message-id:reply-to;\n bh=+nJSPq641/KU7PW2uyxECihx9MetPiHgqWCX0M+BsoQ=;\n b=ppkmw8/sU/Ex71rOKqHkCups+Ll2QPadEmjbVWdX9tsWpajolH4jrgnC+24iZEt/FB\n RR/ixjAf/6yMJUI14fnrsvU+029rpd85uu+1gRZuHSAmHaXTbsFQitpmG0onP9BKnTNU\n R+Ep+sKXXz/iND6QL8/cmgMaBlEoS/fVSekhb2oJqRD3EGZ6IN3q1hhLh0HlxwbBF8mh\n LGRaVsm0bcnd/ZKTBAAa2Uw+NDu85GuCW43WaJ4OmWTRdu3qRsAVWVohQ/4wGqpzsFpc\n 9RyIoTRvYyubx4wS8+SLm8W+ZKx/SXUXCNnJs4fPDyc2rYjHi/7pixQqDQ/vTcmAc3Q0\n S+9g==" ], "X-MC-Unique": "PLXnubtUPxOf_Zz1lpyTpQ-1", "X-Mimecast-MFC-AGG-ID": "PLXnubtUPxOf_Zz1lpyTpQ_1770877557", "X-Google-DKIM-Signature": "v=1; a=rsa-sha256; c=relaxed/relaxed;\n d=1e100.net; s=20230601; t=1770877557; x=1771482357;\n h=content-transfer-encoding:mime-version:references:in-reply-to\n :message-id:date:subject:cc:to:from:x-gm-gg:x-gm-message-state:from\n :to:cc:subject:date:message-id:reply-to;\n bh=+nJSPq641/KU7PW2uyxECihx9MetPiHgqWCX0M+BsoQ=;\n b=SEZUuY9a50R3o2S/24VGVURLDYcchrsylTU//QXzT12ygTjxxk056cMqxGm6aqLkNJ\n iKwoORehpV6SlxUtVcWsakNXRc+E80GvnmODQgvDJLMhHj7Kcru1+Oce+pAlxCUBU0ab\n 3SLQAfzUm6AoMw3742AiDsZjSdor7rnjYCqwYB8dA8y8YOneIq+5pyY/HR06o5N2LS3N\n 7qY29C06xg5NXF0PfFhsqa6TqvYv1DaHQiZseTeoljX493Dww1mZl4PftBpIO7Rp+JRm\n GKcyaCNQy0hYYo2S//pUBjgfYmdjSHT96K6KkLSLOvxoU+CSyd9JkVrPwobg9G1fY1f9\n miBg==", "X-Forwarded-Encrypted": "i=1;\n AJvYcCVmn3KVZO9/AE+PGI0swxI5kTBu1RenuIYvNN0AHUFSXYKsl2cbHX0HBbFz5DlmwExrCn28C2MWiH7S@nongnu.org", "X-Gm-Message-State": "AOJu0Yz152RIXDKbv35WlB2VuY0jzzNcU2E9mXy/gWF+i7QIdaiiH2Q2\n be6adxN2GF3yKgh049FY6s3sj3aVyEg5DFoUDr2QyxkfFrfTXZgAxFHkwOzjiTmgfSx2gpfJ8Ng\n uSD6vgdDecIal5tMYZ7I1TfJ0O4V42qhoUECyIOr7gy2ooDH3uLV+COBB", "X-Gm-Gg": "AZuq6aJDYhqgOmMT+6rtz28fvEcWCJWSLQ6Tb7MAhRskpsyYZqyIsyN88JKjrEwdPR4\n tZnHs56D4HbYVyKqqd0Gpk5TqrxgF2xAPq2fYhAo3WSEcMKFIcOdTwXMnrP7vpxhKOknMqpwGVq\n bl40t71MRIne2V8rVhikGgCMphuM52fwEwVsz/Th465uF8Rd3bjYpOlzQYNeMfo9Ob72lMAS12M\n 6gABqAXXulXfcruMD6IJuLWKSk58fcWYTDyTXdMYza/IIDCVL+2MBpzqLCcybzXrEbfG4x/AuTe\n 5A4AJEIl7nja/lbRxMkNDqTqJB7pEnmiuBcejV5mG4u9n53kR2WDbTA6X/om64Osr7zMyHs+vgH\n VUbn8kCsKkfcUVvIzfBnYlW4Cb9b6CEcgiLt8xcD4nGIBKoGreen5TDY=", "X-Received": [ "by 2002:a05:6a20:6a28:b0:393:7575:a8d6 with SMTP id\n adf61e73a8af0-39448bae9femr2036472637.71.1770877557395;\n Wed, 11 Feb 2026 22:25:57 -0800 (PST)", "by 2002:a05:6a20:6a28:b0:393:7575:a8d6 with SMTP id\n adf61e73a8af0-39448bae9femr2036441637.71.1770877556999;\n Wed, 11 Feb 2026 22:25:56 -0800 (PST)" ], "From": "Ani Sinha <anisinha@redhat.com>", "To": "Paolo Bonzini <pbonzini@redhat.com>", "Cc": "kraxel@redhat.com, Ani Sinha <anisinha@redhat.com>, kvm@vger.kernel.org,\n qemu-devel@nongnu.org", "Subject": "[PATCH v4 07/31] accel/kvm: notify when KVM VM file fd is about to be\n changed", "Date": "Thu, 12 Feb 2026 11:54:51 +0530", "Message-ID": "<20260212062522.99565-8-anisinha@redhat.com>", "X-Mailer": "git-send-email 2.42.0", "In-Reply-To": "<20260212062522.99565-1-anisinha@redhat.com>", "References": "<20260212062522.99565-1-anisinha@redhat.com>", "MIME-Version": "1.0", "Content-Transfer-Encoding": "8bit", "Received-SPF": "pass client-ip=170.10.133.124;\n envelope-from=anisinha@redhat.com;\n helo=us-smtp-delivery-124.mimecast.com", "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, DKIMWL_WL_HIGH=-0.001,\n DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1,\n RCVD_IN_DNSWL_NONE=-0.0001, RCVD_IN_MSPIKE_H2=0.001,\n RCVD_IN_VALIDITY_RPBL_BLOCKED=0.001, RCVD_IN_VALIDITY_SAFE_BLOCKED=0.001,\n SPF_HELO_PASS=-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.29", "Precedence": "list", "List-Id": "qemu development <qemu-devel.nongnu.org>", "List-Unsubscribe": "<https://lists.nongnu.org/mailman/options/qemu-devel>,\n <mailto:qemu-devel-request@nongnu.org?subject=unsubscribe>", "List-Archive": "<https://lists.nongnu.org/archive/html/qemu-devel>", "List-Post": "<mailto:qemu-devel@nongnu.org>", "List-Help": "<mailto:qemu-devel-request@nongnu.org?subject=help>", "List-Subscribe": "<https://lists.nongnu.org/mailman/listinfo/qemu-devel>,\n <mailto:qemu-devel-request@nongnu.org?subject=subscribe>", "Errors-To": "qemu-devel-bounces+incoming=patchwork.ozlabs.org@nongnu.org", "Sender": "qemu-devel-bounces+incoming=patchwork.ozlabs.org@nongnu.org" }, "content": "Various subsystems might need to take some steps before the KVM file descriptor\nfor a virtual machine is changed. So a new boolean attribute is added to the\nvmfd_notifier structure which is passed to the notifier callbacks.\nvmfd_notifer.pre is true for pre-notification of vmfd change and false for\npost notification. Notifier callback implementations can simply check\nthe boolean value for (vmfd_notifer*)->pre and can take actions for pre or\npost vmfd change based on the value.\n\nSubsequent patches will add callback implementations for specific components\nthat need this pre-notification.\n\nSigned-off-by: Ani Sinha <anisinha@redhat.com>\n---\n accel/kvm/kvm-all.c | 9 +++++++++\n include/system/kvm.h | 6 ++++--\n 2 files changed, 13 insertions(+), 2 deletions(-)", "diff": "diff --git a/accel/kvm/kvm-all.c b/accel/kvm/kvm-all.c\nindex 30d6295f53..a6ff16a037 100644\n--- a/accel/kvm/kvm-all.c\n+++ b/accel/kvm/kvm-all.c\n@@ -2654,6 +2654,13 @@ static int kvm_reset_vmfd(MachineState *ms)\n memory_listener_unregister(&kml->listener);\n memory_listener_unregister(&kvm_io_listener);\n \n+ vmfd_notifier.pre = true;\n+ ret = kvm_vmfd_change_notify(&err);\n+ if (ret < 0) {\n+ return ret;\n+ }\n+ assert(!err);\n+\n if (s->vmfd >= 0) {\n close(s->vmfd);\n }\n@@ -2692,6 +2699,8 @@ static int kvm_reset_vmfd(MachineState *ms)\n * notify everyone that vmfd has changed.\n */\n vmfd_notifier.vmfd = s->vmfd;\n+ vmfd_notifier.pre = false;\n+\n ret = kvm_vmfd_change_notify(&err);\n if (ret < 0) {\n return ret;\ndiff --git a/include/system/kvm.h b/include/system/kvm.h\nindex f11729f432..fbe23608a1 100644\n--- a/include/system/kvm.h\n+++ b/include/system/kvm.h\n@@ -571,12 +571,14 @@ int kvm_convert_memory(hwaddr start, hwaddr size, bool to_private);\n /* argument to vmfd change notifier */\n typedef struct VmfdChangeNotifier {\n int vmfd;\n+ bool pre;\n } VmfdChangeNotifier;\n \n /**\n * kvm_vmfd_add_change_notifier - register a notifier to get notified when\n- * a KVM vm file descriptor changes as a part of the confidential guest \"reset\"\n- * process. Various subsystems should use this mechanism to take actions such\n+ * a KVM vm file descriptor changes or about to be changed as a part of the\n+ * confidential guest \"reset\" process.\n+ * Various subsystems should use this mechanism to take actions such\n * as creating new fds against this new vm file descriptor.\n * @n: notifier with return value.\n */\n", "prefixes": [ "v4", "07/31" ] }