radeon_bo: align size of bo to page size.

This is really required for the VRAM allocator upload function.
This commit is contained in:
Dave Airlie 2009-02-03 09:48:27 +10:00
parent 75762a8219
commit dbf72bdd3d

View file

@ -260,6 +260,9 @@ static struct bo_legacy *bo_allocate(struct bo_manager_legacy *boml,
uint32_t flags)
{
struct bo_legacy *bo_legacy;
uint32_t pgsize = getpagesize() - 1;
size = (size + pgsize) & ~pgsize;
bo_legacy = (struct bo_legacy*)calloc(1, sizeof(struct bo_legacy));
if (bo_legacy == NULL) {