tbm_bufmgr: clean up internal functions