From: Alyssa Rosenzweig Date: Tue, 31 Dec 2019 22:52:03 +0000 (-0500) Subject: panfrost: Handle RGB16F colour clear X-Git-Url: https://git.libre-soc.org/?a=commitdiff_plain;h=1b86e0927d4c829209a6134223b0ca5aff771c8d;p=mesa.git panfrost: Handle RGB16F colour clear We don't handle this format yet, but we will soon, and the abort in pan_pack_color is possible even without exposing the format... Handling this gracefully might not be required by the spec but let's not crash. Signed-off-by: Alyssa Rosenzweig --- diff --git a/src/gallium/drivers/panfrost/pan_job.c b/src/gallium/drivers/panfrost/pan_job.c index b193ce6fa76..208e287740a 100644 --- a/src/gallium/drivers/panfrost/pan_job.c +++ b/src/gallium/drivers/panfrost/pan_job.c @@ -1208,6 +1208,8 @@ pan_pack_color(uint32_t *packed, const union pipe_color_union *color, enum pipe_ pan_pack_color_32(packed, out.ui[0] | (out.ui[0] << 16)); else if (size == 3 || size == 4) pan_pack_color_32(packed, out.ui[0]); + else if (size == 6) + pan_pack_color_64(packed, out.ui[0], out.ui[1] | (out.ui[1] << 16)); /* RGB16F -- RGBB */ else if (size == 8) pan_pack_color_64(packed, out.ui[0], out.ui[1]); else if (size == 16)