Page MenuHomeFreeBSD

uma: Check the full bucket cache before short-circuiting.
ClosedPublic

Authored by markj on Aug 6 2020, 7:01 PM.
Tags
None
Referenced Files
Unknown Object (File)
Feb 20 2024, 4:38 AM
Unknown Object (File)
Dec 20 2023, 7:46 AM
Unknown Object (File)
Aug 28 2023, 5:25 AM
Unknown Object (File)
Aug 28 2023, 5:23 AM
Unknown Object (File)
Aug 28 2023, 5:22 AM
Unknown Object (File)
Aug 28 2023, 5:06 AM
Unknown Object (File)
Jul 1 2023, 1:58 PM
Unknown Object (File)
Jul 1 2023, 1:55 PM
Subscribers

Details

Summary

The global bucketdisable flag indicates that we are in a low-memory
situation and should avoid allocating buckets. However, in the
allocation path we were checking it before the full bucket cache. Defer
the check so that we have a shot at allocating from the cache.

This came up because allocations from buf_trie_zone must always succeed.
In one scenario, all of the preallocated trie nodes were in the bucket
list, and a new slab allocation could not succeed due to a memory
shortage. The short-circuiting caused an allocation failure which
triggered a panic.

Diff Detail

Repository
rS FreeBSD src repository - subversion
Lint
Lint Not Applicable
Unit
Tests Not Applicable