Commit 2cede98e authored by Alyssa Rosenzweig's avatar Alyssa Rosenzweig 💜

Further simplify fb algorithm

parent ef284b63
......@@ -80,11 +80,7 @@ trans_set_framebuffer_msaa(struct panfrost_context *ctx, bool enabled)
static int
trans_compute_fb_resolution_check(int width, int height)
{
/* Round each dimension to the nearest multiple of 64 */
int rw = width >> 6;
int rh = height >> 6;
return 0x200 * (2*(rw + rh) / 3);
return ((width + height) / 3) << 4;
}
static void
......@@ -93,7 +89,6 @@ trans_set_framebuffer_resolution(struct mali_single_framebuffer *fb, int w, int
fb->width = MALI_POSITIVE(w);
fb->height = MALI_POSITIVE(h);
fb->resolution_check = trans_compute_fb_resolution_check(w, h);
printf("%d, %d -> %X\n", w, h, fb->resolution_check);
}
struct mali_single_framebuffer
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment