diff options
author | Jonathan Gray <jsg@cvs.openbsd.org> | 2022-09-02 05:18:14 +0000 |
---|---|---|
committer | Jonathan Gray <jsg@cvs.openbsd.org> | 2022-09-02 05:18:14 +0000 |
commit | 5f66494d31f735486b8222ecfa0a0c9046e92543 (patch) | |
tree | f699ac8d7f6d510c30bded04f96a1209344f6a47 /lib/mesa/src/broadcom/cle | |
parent | 17a5b543e3479aaa779cc68345c46d437edd05d8 (diff) |
Import Mesa 22.1.7
Diffstat (limited to 'lib/mesa/src/broadcom/cle')
-rw-r--r-- | lib/mesa/src/broadcom/cle/v3d_decoder.c | 45 | ||||
-rw-r--r-- | lib/mesa/src/broadcom/cle/v3d_packet_v33.xml | 7 |
2 files changed, 6 insertions, 46 deletions
diff --git a/lib/mesa/src/broadcom/cle/v3d_decoder.c b/lib/mesa/src/broadcom/cle/v3d_decoder.c index 97dd8ce84..46cd152e5 100644 --- a/lib/mesa/src/broadcom/cle/v3d_decoder.c +++ b/lib/mesa/src/broadcom/cle/v3d_decoder.c @@ -267,51 +267,6 @@ get_register_offset(const char **atts, uint32_t *offset) return; } -static void -get_start_end_pos(int *start, int *end) -{ - /* start value has to be mod with 32 as we need the relative - * start position in the first DWord. For the end position, add - * the length of the field to the start position to get the - * relative postion in the 64 bit address. - */ - if (*end - *start > 32) { - int len = *end - *start; - *start = *start % 32; - *end = *start + len; - } else { - *start = *start % 32; - *end = *end % 32; - } - - return; -} - -static inline uint64_t -mask(int start, int end) -{ - uint64_t v; - - v = ~0ULL >> (63 - end + start); - - return v << start; -} - -static inline uint64_t -field(uint64_t value, int start, int end) -{ - get_start_end_pos(&start, &end); - return (value & mask(start, end)) >> (start); -} - -static inline uint64_t -field_address(uint64_t value, int start, int end) -{ - /* no need to right shift for address/offset */ - get_start_end_pos(&start, &end); - return (value & mask(start, end)); -} - static struct v3d_type string_to_type(struct parser_context *ctx, const char *s) { diff --git a/lib/mesa/src/broadcom/cle/v3d_packet_v33.xml b/lib/mesa/src/broadcom/cle/v3d_packet_v33.xml index de80a6b64..2533fc06f 100644 --- a/lib/mesa/src/broadcom/cle/v3d_packet_v33.xml +++ b/lib/mesa/src/broadcom/cle/v3d_packet_v33.xml @@ -309,6 +309,11 @@ <value name="tf_overflow" value="6"/> </enum> + <enum name="Line Rasterization" prefix="V3D_LINE_RASTERIZATION"> + <value name="diamond exit" value="0"/> + <value name="perp end caps" value="1"/> + </enum> + <packet code="0" name="Halt"/> <packet code="1" name="NOP"/> <packet code="4" name="Flush"/> @@ -834,7 +839,7 @@ <field name="Depth-Test Function" size="3" start="12" type="Compare Function"/> <field name="Direct3D Wireframe triangles mode" size="1" start="11" type="bool"/> <field name="Rasterizer Oversample Mode" size="2" start="6" type="uint"/> - <field name="Line Rasterization" size="2" start="4" type="uint"/> + <field name="Line Rasterization" size="2" start="4" type="Line Rasterization"/> <field name="Enable Depth Offset" size="1" start="3" type="bool"/> <field name="Clockwise Primitives" size="1" start="2" type="bool"/> <field name="Enable Reverse Facing Primitive" size="1" start="1" type="bool"/> |