diff --git a/.pick_status.json b/.pick_status.json index 338de4cc3ff..25da11cf7d4 100644 --- a/.pick_status.json +++ b/.pick_status.json @@ -214,7 +214,7 @@ "description": "panfrost: avoid accidental aliasing", "nominated": true, "nomination_type": 2, - "resolution": 0, + "resolution": 1, "main_sha": null, "because_sha": "22985caf3ff3d5845d5c03c4516be12f6d004d5e", "notes": null diff --git a/src/gallium/drivers/panfrost/pan_mempool.c b/src/gallium/drivers/panfrost/pan_mempool.c index 4f5613297e6..31b638cf710 100644 --- a/src/gallium/drivers/panfrost/pan_mempool.c +++ b/src/gallium/drivers/panfrost/pan_mempool.c @@ -142,9 +142,9 @@ panfrost_pool_alloc_aligned(struct panfrost_pool *pool, size_t sz, #ifdef PAN_DBG_OVERFLOW if (unlikely(pool->dev->debug & PAN_DBG_OVERFLOW) && !(pool->create_flags & PAN_BO_INVISIBLE)) { - long alignment = sysconf(_SC_PAGESIZE); - assert(alignment > 0 && util_is_power_of_two_nonzero(alignment)); - unsigned aligned = ALIGN_POT(sz, alignment); + long page_size = sysconf(_SC_PAGESIZE); + assert(page_size > 0 && util_is_power_of_two_nonzero(page_size)); + unsigned aligned = ALIGN_POT(sz, page_size); unsigned bo_size = aligned + PAN_GUARD_SIZE; bo = panfrost_pool_alloc_backing(pool, bo_size);