Remove the offset parameter from i830_allocator_init()

offset is redundant.  i830_allocator_init() is only called
in one place with offset=0.

Acked-by: Magnus Kessler <Magnus.Kessler@gmx.net>
Signed-off-by: Wu Fengguang <fengguang.wu@intel.com>
Signed-off-by: Eric Anholt <eric@anholt.net>
This commit is contained in:
Wu Fengguang 2009-04-30 18:42:18 +08:00 committed by Eric Anholt
parent b1f5cc3349
commit 660bd745c2
3 changed files with 5 additions and 6 deletions

View File

@ -692,8 +692,7 @@ extern void I830SetupForSolidFill(ScrnInfoPtr pScrn, int color, int rop,
extern void I830SubsequentSolidFillRect(ScrnInfoPtr pScrn, int x, int y,
int w, int h);
Bool i830_allocator_init(ScrnInfoPtr pScrn, unsigned long offset,
unsigned long size);
Bool i830_allocator_init(ScrnInfoPtr pScrn, unsigned long size);
void i830_allocator_fini(ScrnInfoPtr pScrn);
i830_memory * i830_allocate_memory(ScrnInfoPtr pScrn, const char *name,
unsigned long size, unsigned long pitch,

View File

@ -2319,7 +2319,7 @@ i830_memory_init(ScrnInfoPtr pScrn)
tiled = i830_tiled_width(pI830, &pScrn->displayWidth, pI830->cpp);
/* Set up our video memory allocator for the chosen videoRam */
if (!i830_allocator_init(pScrn, 0, pScrn->videoRam * KB(1))) {
if (!i830_allocator_init(pScrn, pScrn->videoRam * KB(1))) {
xf86DrvMsg(pScrn->scrnIndex, X_ERROR,
"Couldn't initialize video memory allocator\n");
PreInitCleanup(pScrn);

View File

@ -364,7 +364,7 @@ i830_reset_allocations(ScrnInfoPtr pScrn)
* addresses to reference.
*/
Bool
i830_allocator_init(ScrnInfoPtr pScrn, unsigned long offset, unsigned long size)
i830_allocator_init(ScrnInfoPtr pScrn, unsigned long size)
{
I830Ptr pI830 = I830PTR(pScrn);
i830_memory *start, *end;
@ -395,12 +395,12 @@ i830_allocator_init(ScrnInfoPtr pScrn, unsigned long offset, unsigned long size)
}
start->key = -1;
start->offset = offset;
start->offset = 0;
start->end = start->offset;
start->size = 0;
start->next = end;
end->key = -1;
end->offset = offset + size;
end->offset = size;
end->end = end->offset;
end->size = 0;
end->prev = start;