summaryrefslogtreecommitdiff
path: root/include
diff options
context:
space:
mode:
authorDennis Zhou <dennis@kernel.org>2019-02-22 09:03:16 -0800
committerDennis Zhou <dennis@kernel.org>2019-03-13 12:25:31 -0700
commitb89462a9c5f4a3ac5160e7b3599bb09c94b94880 (patch)
treed35565be3b9b664080870d8f034ed8fe24f9859e /include
parent382b88e961c7a4196e01cef3249297583d02d608 (diff)
downloadlwn-b89462a9c5f4a3ac5160e7b3599bb09c94b94880.tar.gz
lwn-b89462a9c5f4a3ac5160e7b3599bb09c94b94880.zip
percpu: remember largest area skipped during allocation
Percpu allocations attempt to do first fit by scanning forward from the first_free of a block. However, fragmentation from allocation requests can cause holes not seen by block hint update functions. To address this, create a local version of bitmap_find_next_zero_area_off() that remembers the largest area skipped over. The caveat is that it only sees regions skipped over due to not fitting, not regions skipped due to alignment. Prior to updating the scan_hint, a scan backwards is done to try and recover free bits skipped due to alignment. While this can cause scanning to miss earlier possible free areas, smaller allocations will eventually fill those holes due to first fit. Signed-off-by: Dennis Zhou <dennis@kernel.org>
Diffstat (limited to 'include')
0 files changed, 0 insertions, 0 deletions