From nobody Sun Feb 8 14:56:32 2026 Delivered-To: importer@patchew.org Received-SPF: pass (zohomail.com: domain of redhat.com designates 170.10.133.124 as permitted sender) client-ip=170.10.133.124; envelope-from=libvir-list-bounces@redhat.com; helo=us-smtp-delivery-124.mimecast.com; Authentication-Results: mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of redhat.com designates 170.10.133.124 as permitted sender) smtp.mailfrom=libvir-list-bounces@redhat.com; dmarc=pass(p=none dis=none) header.from=redhat.com ARC-Seal: i=1; a=rsa-sha256; t=1692281168; cv=none; d=zohomail.com; s=zohoarc; b=ReOohTQTw1VY5LLbemnJbg1zpuw7gVTmUY1U3dlUlPvT5SG3JZzpVJQ8MzIz56rjkny0C+1XZhdxZ8QkTzbc4AYHPQfjocjAdnXPezbYjTj71v15cZkx7xBJXYLqL0ClFfugE9wD7LBlTURbKRtKzPLD40W4+Zy588e3MDbPOsE= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1692281168; h=Content-Type:Content-Transfer-Encoding:Date:From:In-Reply-To:List-Subscribe:List-Post:List-Id:List-Archive:List-Help:List-Unsubscribe:MIME-Version:Message-ID:References:Sender:Subject:To; bh=6x+hNxL/zY5ggGALgvVk//9EUxbzB8TtaY7z296C/Xs=; b=mUwBY0V/HUr4qj0s9IqOWEb/QtqGd6Au+ETVYhvifyNw/67n2po4PZON9lH15ahAIEL9u4MrHfiS6vXQRPy1PAHhr8iFBHQq88pfUcHvsTNZk0P6UhaicSsJbBpatm2dGoqpioipXUSn5rf1BJo1LVRP7GvSdbUvHnrw4f4WlEw= ARC-Authentication-Results: i=1; mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of redhat.com designates 170.10.133.124 as permitted sender) smtp.mailfrom=libvir-list-bounces@redhat.com; dmarc=pass header.from= (p=none dis=none) Return-Path: Received: from us-smtp-delivery-124.mimecast.com (us-smtp-delivery-124.mimecast.com [170.10.133.124]) by mx.zohomail.com with SMTPS id 1692281168900651.0726458084193; Thu, 17 Aug 2023 07:06:08 -0700 (PDT) Received: from mimecast-mx02.redhat.com (66.187.233.73 [66.187.233.73]) by relay.mimecast.com with ESMTP with STARTTLS (version=TLSv1.2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id us-mta-104-Fd1EAyb7PyyyodgZLIKZdg-1; Thu, 17 Aug 2023 10:06:04 -0400 Received: from smtp.corp.redhat.com (int-mx07.intmail.prod.int.rdu2.redhat.com [10.11.54.7]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mimecast-mx02.redhat.com (Postfix) with ESMTPS id A61302999B48; Thu, 17 Aug 2023 14:06:01 +0000 (UTC) Received: from mm-prod-listman-01.mail-001.prod.us-east-1.aws.redhat.com (mm-prod-listman-01.mail-001.prod.us-east-1.aws.redhat.com [10.30.29.100]) by smtp.corp.redhat.com (Postfix) with ESMTP id 89DD5140E963; Thu, 17 Aug 2023 14:06:01 +0000 (UTC) Received: from mm-prod-listman-01.mail-001.prod.us-east-1.aws.redhat.com (localhost [IPv6:::1]) by mm-prod-listman-01.mail-001.prod.us-east-1.aws.redhat.com (Postfix) with ESMTP id B704C1946A7A; Thu, 17 Aug 2023 14:05:30 +0000 (UTC) Received: from smtp.corp.redhat.com (int-mx08.intmail.prod.int.rdu2.redhat.com [10.11.54.8]) by mm-prod-listman-01.mail-001.prod.us-east-1.aws.redhat.com (Postfix) with ESMTP id 1A5591946A43 for ; Thu, 17 Aug 2023 14:05:25 +0000 (UTC) Received: by smtp.corp.redhat.com (Postfix) id 06E78C15E62; Thu, 17 Aug 2023 14:05:20 +0000 (UTC) Received: from localhost.localdomain (unknown [10.43.2.36]) by smtp.corp.redhat.com (Postfix) with ESMTP id 96BBAC159F2 for ; Thu, 17 Aug 2023 14:05:19 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1692281167; h=from:from:sender:sender:reply-to:subject:subject:date:date: message-id:message-id:to:to:cc:mime-version:mime-version: content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references:list-id:list-help: list-unsubscribe:list-subscribe:list-post; bh=6x+hNxL/zY5ggGALgvVk//9EUxbzB8TtaY7z296C/Xs=; b=Q33QM4JmNxLjPTvIu+HLlHV8ADzoSABn7OBUSRrzyHr/pcnz/T7CzRFL7JB6wjGz3lH63q 5SxoNAdC61DtVZ8oGFeOeKRIvxhLVfeJJDozogIJ6sR2VEqrHT0ZtEFCzimqA+xjZxsyh7 wILNWk8T6znJATmIv9uSeofE1recO0M= X-MC-Unique: Fd1EAyb7PyyyodgZLIKZdg-1 X-Original-To: libvir-list@listman.corp.redhat.com From: Michal Privoznik To: libvir-list@redhat.com Subject: [PATCH 2/9] virt-aa-helper: Set label on VIRTIO_PMEM device too Date: Thu, 17 Aug 2023 16:05:09 +0200 Message-ID: <30ae03b34f30ffe5ce487dbeb2ac437d4b1c3add.1692281096.git.mprivozn@redhat.com> In-Reply-To: References: MIME-Version: 1.0 X-Scanned-By: MIMEDefang 3.1 on 10.11.54.8 X-BeenThere: libvir-list@redhat.com X-Mailman-Version: 2.1.29 Precedence: list List-Id: Development discussions about the libvirt library & tools List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: libvir-list-bounces@redhat.com Sender: "libvir-list" X-Scanned-By: MIMEDefang 3.1 on 10.11.54.7 X-Mimecast-Spam-Score: 0 X-Mimecast-Originator: redhat.com Content-Transfer-Encoding: quoted-printable X-ZohoMail-DKIM: pass (identity @redhat.com) X-ZM-MESSAGEID: 1692281306101100001 Content-Type: text/plain; charset="utf-8"; x-default="true" Conceptually, from host POV there's no difference between NVDIMM and VIRTIO_PMEM. Both expose a file to the guest (which is used as a permanent storage). Other secdriver treat NVDIMM and VIRTIO_PMEM the same. Thus, modify virt-aa-helper so that is appends virtio-pmem backing path into the domain profile too. Signed-off-by: Michal Privoznik --- src/security/virt-aa-helper.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/security/virt-aa-helper.c b/src/security/virt-aa-helper.c index a0c76d24a8..23e3dba7f5 100644 --- a/src/security/virt-aa-helper.c +++ b/src/security/virt-aa-helper.c @@ -1151,11 +1151,11 @@ get_files(vahControl * ctl) =20 switch (mem->model) { case VIR_DOMAIN_MEMORY_MODEL_NVDIMM: + case VIR_DOMAIN_MEMORY_MODEL_VIRTIO_PMEM: if (vah_add_file(&buf, mem->nvdimmPath, "rw") !=3D 0) goto cleanup; break; case VIR_DOMAIN_MEMORY_MODEL_DIMM: - case VIR_DOMAIN_MEMORY_MODEL_VIRTIO_PMEM: case VIR_DOMAIN_MEMORY_MODEL_VIRTIO_MEM: case VIR_DOMAIN_MEMORY_MODEL_SGX_EPC: case VIR_DOMAIN_MEMORY_MODEL_NONE: --=20 2.41.0