firmware: arm_ffa: Fix cleanup, notification, and discovery paths
Status from this message: Applied to sudeep.holla/linux (for-next/ffa/fixes), thanks!
Get series with b4
b4 am [email protected] change-id 20260423-ffa_fixes-4ad33f0ee250Versions newest first
- v2 Latest11 patches 1 replyApplied
- v18 patches 2 repliesSuperseded
Changes in v2 from the cover letter
- Addressed valid comments from sashiko
(https://sashiko.dev/#/patchset/[email protected])
- Added couple of new fixes based on the review
- Link to v1: https://patch.msgid.link/[email protected]
Patches in v2 Applied
Reviews trailers per patch
1 of 11 patches has a Reviewed-by or Acked-by.
| Patch | Sebastian Ene |
|---|---|
| 1/11 | |
| 2/11 | |
| 3/11 | |
| 4/11 | |
| 5/11 | |
| 6/11 | |
| 7/11 | |
| 8/11 | |
| 9/11 | R-b |
| 10/11 | |
| 11/11 |
Trailers given in replies are filled; those carried in the patches from earlier versions are outlined with dashes.
Cover letter [PATCH v2 00/11] firmware: arm_ffa: Fix cleanup, notification, and discovery paths
Hi all,
This series fixes a set of issues in the FF-A driver around init cleanup, framework notification handling, v1.0 notifier lifetime, and partition discovery.
The fixes are all small and localized, but together they tighten a few important paths:
- fix the early init unwind path when RX buffer allocation fails
- align the stored RX/TX buffer size with the size actually mapped to firmware
- ensure the framework notification handler always releases the RX buffer correctly
- validate framework notification payload bounds before copying data out of the shared RX buffer
- fix the partition lookup used for sched-recv callback registration
- unregister the FF-A v1.0 bus notifier during teardown
- bound the register-based partition discovery copies against the caller buffer
- reject FF-A driver registration without an ID table
- fix per-vcpu drivers own notifications handling in workqueue
- make NPI per cpu work item to avoid collapsing already queued work
This is the outcome of the self-initiated review of the entire driver following the oversight of Sashiko’s review on one of the patches that was merged.
https://sashiko.dev/#/patchset/[email protected]
---
Changes in v2:
- Addressed valid comments from sashiko
(https://sashiko.dev/#/patchset/[email protected])
- Added couple of new fixes based on the review
- Link to v1: https://patch.msgid.link/[email protected]
---
Sudeep Holla (11):
firmware: arm_ffa: Check for NULL FF-A ID table while driver registration
firmware: arm_ffa: Skip free_pages on RX buffer alloc failure
firmware: arm_ffa: Avoid collapsing NPI work from different CPUs
firmware: arm_ffa: Fix per-vcpu self notifications handling in workqueue
firmware: arm_ffa: Unregister bus notifier on teardown for FF-A v1.0
firmware: arm_ffa: Bound PARTITION_INFO_GET_REGS copies
firmware: arm_ffa: Keep framework RX release under lock
firmware: arm_ffa: Validate framework notification message layout
firmware: arm_ffa: Align RxTx buffer size before mapping
firmware: arm_ffa: Snapshot notifier callbacks under lock
firmware: arm_ffa: Fix sched-recv callback partition lookup
drivers/firmware/arm_ffa/bus.c | 4 +- drivers/firmware/arm_ffa/driver.c | 138 +++++++++++++++++++++++++++----------- 2 files changed, 102 insertions(+), 40 deletions(-)
---
base-commit: 254f49634ee16a731174d2ae34bc50bd5f45e731
change-id: 20260423-ffa_fixes-4ad33f0ee250
Signature · 2 lines
Regards, Sudeep