Page Menu
Home
FreeBSD
Search
Configure Global Search
Log In
Files
F109364764
D31312.diff
No One
Temporary
Actions
View File
Edit File
Delete File
View Transforms
Subscribe
Mute Notifications
Flag For Later
Award Token
Size
860 B
Referenced Files
None
Subscribers
None
D31312.diff
View Options
Index: sys/kern/subr_rman.c
===================================================================
--- sys/kern/subr_rman.c
+++ sys/kern/subr_rman.c
@@ -160,6 +160,11 @@
rm->rm_descr, start, end));
if (start < rm->rm_start || end > rm->rm_end)
return EINVAL;
+#if defined(INVARIANTS) || defined(_STANDALONE)
+ if (RMAN_IS_DEFAULT_RANGE(start, end))
+ printf("ERROR: %s: <%s> attempting to manage default range\n",
+ __func__, rm->rm_descr);
+#endif
r = int_alloc_resource(M_NOWAIT);
if (r == NULL)
return ENOMEM;
@@ -447,6 +452,8 @@
dev == NULL ? "<null>" : device_get_nameunit(dev)));
KASSERT((flags & RF_FIRSTSHARE) == 0,
("invalid flags %#x", flags));
+ KASSERT(count != 0, ("%s(): attempting to allocate empty range",
+ __func__));
new_rflags = (flags & ~RF_FIRSTSHARE) | RF_ALLOCATED;
mtx_lock(rm->rm_mtx);
File Metadata
Details
Attached
Mime Type
text/plain
Expires
Wed, Feb 5, 2:50 AM (20 h, 51 m)
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
16465586
Default Alt Text
D31312.diff (860 B)
Attached To
Mode
D31312: kern/rman: warn/KASSERT() on garbled reservations
Attached
Detach File
Event Timeline
Log In to Comment