Page MenuHomeFreeBSD

Assert that malloc(9) and uma_zalloc_arg(9) are not called from non-sleepable threads or interrupts.
Needs ReviewPublic

Authored by bdrewery on Sep 25 2014, 1:05 AM.
This revision needs review, but there are no reviewers specified.

Details

Reviewers
None
Summary

KASSERT_WARN() is used for now since the impact is not known.

This is based on the patch and report from https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=193696

A problem I know of is that malloc(9) calls uma_zalloc(9) and due to the non-panic KASSERT_WARN, it shows the same message again. It would not make sense to only place the KASSERT_WARN only in uma_zalloc_arg(9) for now as then memguard and redzone would be missing the check.

Diff Detail

Repository
rS FreeBSD src repository - subversion
Lint
No Linters Available
Unit
No Unit Test Coverage

Event Timeline

bdrewery retitled this revision from to Assert that malloc(9) and uma_zalloc_arg(9) are not called from non-sleepable threads or interrupts..
bdrewery updated this object.
bdrewery edited the test plan for this revision. (Show Details)

Remove use of KASSERT_WARN for interrupt check in uma_zallog_arg() and move
the KASSERTS for interrupt contexts outside of the M_WAITOK check.

Updating D830: Assert that malloc(9) and uma_zalloc_arg(9) are not called from non-sleepable

threads or interrupts.

Whitespace

Updating D830: Assert that malloc(9) and uma_zalloc_arg(9) are not called from non-sleepable

threads or interrupts.