Page MenuHomeFreeBSD

D58574.id183161.diff
No OneTemporary

D58574.id183161.diff

diff --git a/sys/vm/uma_core.c b/sys/vm/uma_core.c
--- a/sys/vm/uma_core.c
+++ b/sys/vm/uma_core.c
@@ -635,8 +635,7 @@
size_t sz;
int i;
- if ((zone->uz_flags &
- (UMA_ZFLAG_CACHE | UMA_ZONE_SECONDARY | UMA_ZONE_MALLOC)) != 0) {
+ if ((zone->uz_flags & (UMA_ZFLAG_CACHE | UMA_ZONE_SECONDARY)) != 0) {
/*
* Cache zones should not be instrumented by default, as UMA
* does not have enough information to do so correctly.
@@ -645,9 +644,6 @@
*
* Items from secondary zones are initialized by the parent
* zone and thus cannot safely be marked by UMA.
- *
- * malloc zones are handled directly by malloc(9) and friends,
- * since they can provide more precise origin tracking.
*/
return;
}
@@ -662,7 +658,9 @@
sz = zone->uz_size;
if ((zone->uz_flags & UMA_ZONE_PCPU) == 0) {
- kmsan_orig(item, sz, KMSAN_TYPE_UMA, KMSAN_RET_ADDR);
+ /* malloc(9) updates the origin map itself. */
+ if ((zone->uz_flags & UMA_ZONE_MALLOC) == 0)
+ kmsan_orig(item, sz, KMSAN_TYPE_UMA, KMSAN_RET_ADDR);
kmsan_mark(item, sz, KMSAN_STATE_UNINIT);
} else {
pcpu_item = zpcpu_base_to_offset(item);

File Metadata

Mime Type
text/plain
Expires
Tue, Aug 4, 7:00 AM (1 h, 39 m)
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
35824192
Default Alt Text
D58574.id183161.diff (1 KB)

Event Timeline