Do not set M_BESTFIT if a strategy has already been provided. This

fixes problems when using M_FIRSTFIT.

Reviewed by:	jeff@
MFC after:	1 week
This commit is contained in:
Navdeep Parhar 2014-04-16 21:39:43 +00:00
parent 7a0397fc3b
commit c7a3775adf

View File

@ -502,7 +502,8 @@ qc_import(void *arg, void **store, int cnt, int flags)
int i;
qc = arg;
flags |= M_BESTFIT;
if ((flags & VMEM_FITMASK) == 0)
flags |= M_BESTFIT;
for (i = 0; i < cnt; i++) {
if (vmem_xalloc(qc->qc_vmem, qc->qc_size, 0, 0, 0,
VMEM_ADDR_MIN, VMEM_ADDR_MAX, flags, &addr) != 0)