Page Menu
Home
FreeBSD
Search
Configure Global Search
Log In
Files
F107356658
D36597.id110682.diff
No One
Temporary
Actions
View File
Edit File
Delete File
View Transforms
Subscribe
Mute Notifications
Flag For Later
Award Token
Size
1 KB
Referenced Files
None
Subscribers
None
D36597.id110682.diff
View Options
diff --git a/sys/dev/iommu/iommu_gas.c b/sys/dev/iommu/iommu_gas.c
--- a/sys/dev/iommu/iommu_gas.c
+++ b/sys/dev/iommu/iommu_gas.c
@@ -580,7 +580,6 @@
iommu_gas_free_region(struct iommu_map_entry *entry)
{
struct iommu_domain *domain;
- struct iommu_map_entry *next, *prev;
domain = entry->domain;
KASSERT((entry->flags & (IOMMU_MAP_ENTRY_PLACE | IOMMU_MAP_ENTRY_RMRR |
@@ -588,15 +587,10 @@
("non-RMRR entry %p %p", domain, entry));
IOMMU_DOMAIN_LOCK(domain);
- prev = RB_PREV(iommu_gas_entries_tree, &domain->rb_root, entry);
- next = RB_NEXT(iommu_gas_entries_tree, &domain->rb_root, entry);
- iommu_gas_rb_remove(domain, entry);
+ if (entry != domain->first_place &&
+ entry != domain->last_place)
+ iommu_gas_rb_remove(domain, entry);
entry->flags &= ~IOMMU_MAP_ENTRY_RMRR;
-
- if (prev == NULL)
- iommu_gas_rb_insert(domain, domain->first_place);
- if (next == NULL)
- iommu_gas_rb_insert(domain, domain->last_place);
IOMMU_DOMAIN_UNLOCK(domain);
}
@@ -608,7 +602,7 @@
IOMMU_DOMAIN_ASSERT_LOCKED(domain);
MPASS(start <= end);
- MPASS(end <= domain->last_place->end);
+ MPASS(end <= domain->end);
/*
* Find an entry which contains the supplied guest's address
File Metadata
Details
Attached
Mime Type
text/plain
Expires
Mon, Jan 13, 11:50 PM (9 h, 6 m)
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
15788828
Default Alt Text
D36597.id110682.diff (1 KB)
Attached To
Mode
D36597: iommu_gas: don't remove and reinsert boundary entry
Attached
Detach File
Event Timeline
Log In to Comment