Page MenuHomeFreeBSD

bhyve: Map the right BAR in init_msix_table()
ClosedPublic

Authored by markj on Jan 4 2022, 7:11 PM.
Tags
None
Referenced Files
F164862841: D33739.id100944.diff
Tue, Aug 4, 8:57 AM
F164826864: D33739.id100933.diff
Tue, Aug 4, 5:47 AM
F164804096: D33739.id100974.diff
Tue, Aug 4, 3:18 AM
Unknown Object (File)
Mon, Aug 3, 1:40 AM
Unknown Object (File)
Thu, Jul 30, 9:11 PM
Unknown Object (File)
Tue, Jul 28, 10:05 PM
Unknown Object (File)
Thu, Jul 23, 10:58 AM
Unknown Object (File)
Sat, Jul 18, 1:47 PM
Subscribers

Details

Summary

The PBA and MSI-X table can reside in different BARs.

Reported by: Andy Fiddaman <andy@omniosce.org>
Fixes: 7fa233534736 ("bhyve: Map the MSI-X table unconditionally for passthrough")
MFC after: 3 days

Diff Detail

Repository
rS FreeBSD src repository - subversion
Lint
Lint Passed
Unit
No Test Coverage
Build Status
Buildable 43709
Build 40597: arc lint + arc unit

Event Timeline

markj requested review of this revision.Jan 4 2022, 7:11 PM

Fix a second bug, also reported by Andy:

If the last page containing the table is not also the last page
of the BAR, then we would call mprotect(PROT_NONE) on the wrong
portion of the mapping.

This revision is now accepted and ready to land.Jan 4 2022, 10:35 PM