summary | shortlog | log | commit | commitdiff | tree
raw | patch | inline | side by side (parent: 97c2ce1)
raw | patch | inline | side by side (parent: 97c2ce1)
author | David Lide <a0216552@gtudci01.(none)> | |
Fri, 22 May 2015 13:44:55 +0000 (09:44 -0400) | ||
committer | David Lide <a0216552@gtudci01.(none)> | |
Fri, 22 May 2015 13:44:55 +0000 (09:44 -0400) |
ti/runtime/hplib/src/bm_alloc.c | patch | blob | history |
index a5decbb01c0be7c53eeca7bffa8ce7d7a2f2beee..0a7dd14131483794a3ebce7eb1c529f810b85cd0 100755 (executable)
unsigned int off = p-pCtx->pBase;
int wpos, bpos;
int ewpos, ebpos;
+ int szinpages = size/pCtx->PSZ;
if (off > pCtx->maxsize) return;
+ if (szinpages*pCtx->PSZ != sz) sz = (szinpages+1)*pCtx->PSZ;
wpos= bmToWordBit(pCtx, off, &bpos);
ewpos= bmToWordBit(pCtx, off+size, &ebpos);
//adjust by 1