Use the BUS_DMA_NOWRITE flag to expose and create the read-only VT-d
IOMMU mappings. Reviewed by: kib Sponsored by: Dell EMC Isilon Differential Revision: https://reviews.freebsd.org/D19729
This commit is contained in:
parent
a273e09cb2
commit
cec2287b6a
Notes:
svn2git
2020-12-20 02:59:44 +00:00
svn path=/head/; revision=345601
@ -527,7 +527,8 @@ dmar_bus_dmamap_load_something1(struct bus_dma_tag_dmar *tag,
|
||||
gas_flags |= DMAR_GM_CANSPLIT;
|
||||
|
||||
error = dmar_gas_map(domain, &tag->common, size, offset,
|
||||
DMAR_MAP_ENTRY_READ | DMAR_MAP_ENTRY_WRITE,
|
||||
DMAR_MAP_ENTRY_READ |
|
||||
((flags & BUS_DMA_NOWRITE) == 0 ? DMAR_MAP_ENTRY_WRITE : 0),
|
||||
gas_flags, ma + idx, &entry);
|
||||
if (error != 0)
|
||||
break;
|
||||
|
Loading…
Reference in New Issue
Block a user