[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [PATCH v3 6/6] xen/arm: ffa: Deliver VM-to-VM notifications locally
- To: Bertrand Marquis <bertrand.marquis@xxxxxxx>
- From: Volodymyr Babchuk <Volodymyr_Babchuk@xxxxxxxx>
- Date: Thu, 26 Nov 2026 01:50:02 +0000
- Accept-language: en-US
- Arc-authentication-results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=epam.com; dmarc=pass action=none header.from=epam.com; dkim=pass header.d=epam.com; arc=none
- Arc-message-signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector10001; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-AntiSpam-MessageData-ChunkCount:X-MS-Exchange-AntiSpam-MessageData-0:X-MS-Exchange-AntiSpam-MessageData-1; bh=UDjd4wNmgvxLG+iD9znl8jXjCP8RrUuJNF/Qo9gRu58=; b=khlTf/9p54myIbATI2F86SeCzKIpQ0uZMID//IuxyjFjn0m0/24f6V3f65itlEs3wOZmLnVu99SDh3PAmBXHBm6Qu2v4hvT6cGSHGt7SkRHxzTtLUWEloaK7yosaKoBIRWQNQfr06FpKvrfSBus6bX28/J+XHb/+7j1wblv04bVdPKNSUz+vTOZ/eJY2W06Gn0yLwC6+DRuyEc2k8YhfUZItI8oKemGBeZSbtN2xTw8oeKaKRhH69UZQgKduFX406gbksZEalEYY7ka5YlGEXdkz1B48ihWdXikEdIyC0SppUbRZ9VIfp4xl/DiBT+OE82zSlQllv69I+eFCnkkbFA==
- Arc-seal: i=1; a=rsa-sha256; s=arcselector10001; d=microsoft.com; cv=none; b=RbIP0MYh67wAlVmlVPXu6e+/ufb8aFNbtI0X0qnixy1rTYf0tur+ElBmSSGsGWBQu6bmK9Ebuwtk7a+tHmwX+d+YBXIWWc1t8nQrc8qfXmntHTETwdqwzlWMQg6gUagdP09ziDBG1Ri/4mahh4woP8DP5Z1OF3oO1e+YfL+67PBqYDEJMQPTayT/+2tuVdgrSnGCv4hp8WZas81t7Gqi3e2qtEDLU9x5vWhdz6KIeUJZolZQKCt5dMPvsb4B0vae1hZlncM7n7qZDn9hRbWfLNlgFC/Syp77dMmROZqhWpriZqMvlQM5VF/J4gruKeCqhhBbFzcUi6KcGnt0HGYqPQ==
- Authentication-results: eu.smtp.expurgate.cloud; dkim=pass header.s=selector1 header.d=epam.com header.i="@epam.com" header.h="From:Date:Subject:Message-ID:Content-Type:MIME-Version:x-ms-exchange-senderadcheck"
- Authentication-results: mx.microsoft.com 1; dkim=none (message not signed) header.d=none;dmarc=none action=none header.from=epam.com;
- Cc: "xen-devel@xxxxxxxxxxxxxxxxxxxx" <xen-devel@xxxxxxxxxxxxxxxxxxxx>, Jens Wiklander <jenswi@xxxxxxxxxx>, Stefano Stabellini <sstabellini@xxxxxxxxxx>, Julien Grall <julien@xxxxxxx>, Michal Orzel <michal.orzel@xxxxxxx>
- Delivery-date: Thu, 26 Nov 2026 01:50:14 +0000
- List-id: Xen developer discussion <xen-devel.lists.xenproject.org>
- Thread-index: AQHdO7KoPFvS+zi8yEulsuVRHLReJLdAGX8A
- Thread-topic: [PATCH v3 6/6] xen/arm: ffa: Deliver VM-to-VM notifications locally
Hi Bertrand,
Bertrand Marquis <bertrand.marquis@xxxxxxx> writes:
> VM notification binding and pending tracking exist for non-secure
> endpoints, but FFA_NOTIFICATION_SET still only forwards secure
> destinations to the SPMC. Non-secure VMs therefore cannot receive
> notifications from other VMs. Local NPI delivery also needs explicit
> re-arm tracking so repeated raises are not lost while the interrupt is
> already pending.
>
> Add a local VM notification delivery path for non-secure destinations.
> notification_set_vm() resolves the destination endpoint, verifies that
> every requested bit is bound to the sender, sets the receiver's
> vm_pending bitmap under notif_lock, and raises an NPI only when local
> pending state is not already armed.
>
> Track whether a local NPI is already armed with notif_irq_raised,
> clear that state once both VM and hypervisor pending bitmaps are
> drained, and keep notif_lock held across the VM notification injection
> attempt. If no destination vCPU is online, leave the pending bits set
> and keep notif_irq_raised clear so delivery can be retried later.
> Also expose firmware notification availability so FFA_FEATURES only
> advertises notification support when it is actually provided by the
> firmware or by CONFIG_FFA_VM_TO_VM.
>
> Functional impact: when CONFIG_FFA_VM_TO_VM is enabled, non-secure
> FFA_NOTIFICATION_SET delivers VM-to-VM notifications locally and keeps
> NPI delivery reliable across repeated raises.
>
> Signed-off-by: Bertrand Marquis <bertrand.marquis@xxxxxxx>
Reviewed-by: Volodymyr Babchuk <volodymyr_babchuk@xxxxxxxx>
[...]
--
WBR, Volodymyr
|