vfio: Fix racy bitfields and tighten struct layout
Get series with b4
b4 am [email protected]Versions newest first · linked by author and title
- v2 Latest2 patches 5 repliesIn review
- v12 patches 0 repliesSuperseded
Patches in v2 No applies recorded yet
| # | Subject and files | Size | Replies | Applied |
|---|---|---|---|---|
| 1/2 | vfio/pci: Fix racy bitfields and tighten struct layoutinclude/ | +4 | 5 replies | |
| 2/2 | vfio/mlx5: Fix racy bitfields and tighten struct layoutdrivers/ | +4 | 0 replies |
Reviews trailers per patch
No Reviewed-by, Acked-by or Tested-by trailers for v2 yet.
Cover letter [PATCH v2 0/2] vfio: Fix racy bitfields and tighten struct layout
A recent patch[1] proposed by Raghavendra triggered a Sashiko review[2] flagging that the proposed new bitfield shares storage with neighbors and that concurrent updates via RMW may clobber adjacent fields.
Auditing bitfield users in vfio_pci_core_device finds several pre-existing fields with the same hazard, and an analogous pattern in mlx5_vhca_page_tracker / mlx5vf_pci_core_device. This series splits all such fields out of their shared storage words, resolving the existing cases.
v2: Uncouple from Raghavendra's patch so that Sashiko can apply
and review (new field dropped), we can handle merge on commit.
Thanks,
Alex
[1] https://lore.kernel.org/all/[email protected]/
[2] https://sashiko.dev/#/patchset/[email protected]
Alex Williamson (2):
vfio/pci: Fix racy bitfields and tighten struct layout vfio/mlx5: Fix racy bitfields and tighten struct layout
drivers/vfio/pci/mlx5/cmd.h | 8 ++++---- include/linux/vfio_pci_core.h | 8 ++++---- 2 files changed, 8 insertions(+), 8 deletions(-)
Signature · 1 line
2.51.0