Page MenuHomeFreeBSD

dpaa2: Avoid dpaa2_cmd race conditions
ClosedPublic

Authored by dsl on Apr 11 2023, 5:30 PM.
Tags
None
Referenced Files
Unknown Object (File)
Sun, Feb 9, 1:00 PM
Unknown Object (File)
Sun, Feb 9, 1:00 PM
Unknown Object (File)
Sun, Feb 9, 12:54 PM
Unknown Object (File)
Sun, Feb 9, 12:52 PM
Unknown Object (File)
Sat, Feb 1, 12:33 AM
Unknown Object (File)
Fri, Jan 24, 5:52 PM
Unknown Object (File)
Fri, Jan 24, 5:50 PM
Unknown Object (File)
Fri, Jan 24, 9:04 AM
Subscribers

Details

Summary

struct dpaa2_cmd is no longer malloc'ed, but can be allocated on stack
and initialized with DPAA2_CMD_INIT() on demand. Drivers stopped caching
their DPAA2 command objects (and associated tokens) in the software
contexts in order to avoid using them concurrently.

Details: https://github.com/mcusim/freebsd-src/issues/14

Diff Detail

Repository
rG FreeBSD src repository
Lint
Lint Not Applicable
Unit
Tests Not Applicable

Event Timeline

dsl requested review of this revision.Apr 11 2023, 5:30 PM

diff has been updated to provide full context.

I had some simplifications when I merged your earlier work but merging those in into this would be complicated. I'll leave that to "code cleanup" at some point. Thanks a lot for doing the work!

This revision is now accepted and ready to land.Apr 15 2023, 12:27 PM
This revision was automatically updated to reflect the committed changes.