HomeFreeBSD

sym(4): Employ memory barriers also on x86

Description

sym(4): Employ memory barriers also on x86

In an MP world, it doesn't hold that x86 requires no memory barriers.

This change should also fix panics due to out-of-sync data seen with
FreeBSD VMs on top of OpenStack and HBAs of type lsiLogic. [1]

While at it:

  • Improve the granularity somewhat by distinguishing between read and write memory barriers as well as refer to existing *mb(9) functions instead of duplicating these [2], unless IO barriers are also used.
  • Nuke the unused SYM_DRIVER_NAME macro.

PR: 270816 [1]
Obtained from: BSD-licensed Linux sym53c8xx driver [2]
MFC after: 1 week

Details

Provenance
mariusAuthored on Jan 26 2026, 1:58 PM
Parents
rG518c01b31e96: sym(4): Provide a DEVICE_DETACH(9) method
Branches
Unknown
Tags
Unknown
Reverted By
rGbfbcd310bd49: Revert "sym(4): Employ memory barriers also on x86"