Actions
Bug #4673
openkmdb should panic when it can't allocate during setup
Status:
New
Priority:
Normal
Assignee:
-
Category:
-
Start date:
2014-03-07
Due date:
% Done:
0%
Estimated time:
Difficulty:
Medium
Tags:
needs-triage
Gerrit CR:
Description
If kmdb can't allocate memory while setting itself up, it allocates again KM_SLEEP
http://src.illumos.org/source/xref/illumos-gate/usr/src/cmd/mdb/common/kmdb/kctl/kctl_main.c#188
The comment claims we'll hang, but of course we won't, because at that point we're single threaded and the dispatcher hasn't been set up. We'll panic, but we'll do so in a way far more confusing than if that cmn_err had actually just panicked in the first place.
You may think to yourself "But surely kmdb then won't work?" That might be true, but the current way panics anyway, just really annoyingly, and kmdb worked sufficiently then to discover this.
kmdb should panic, and use a message that clearly says "Out of memory" or "allocation failed".
No data to display
Actions