summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorEric Engestrom <[email protected]>2017-09-04 13:54:52 +0100
committerEric Engestrom <[email protected]>2017-09-14 09:56:00 +0100
commit412ab3f6fdd91019bc9ceecba80e10eb1d522f94 (patch)
tree0e6079b505851064ac28ad7302f5ff5e2ab88700
parent49c72d84c27b698bca73978869e15cad4414ab7e (diff)
dri/radeon: use ARRAY_SIZE macro
Signed-off-by: Eric Engestrom <[email protected]> Reviewed-by: Ian Romanick <[email protected]>
-rw-r--r--src/mesa/drivers/dri/radeon/radeon_tcl.c4
1 files changed, 3 insertions, 1 deletions
diff --git a/src/mesa/drivers/dri/radeon/radeon_tcl.c b/src/mesa/drivers/dri/radeon/radeon_tcl.c
index 3e2f4261600..61ff2311e95 100644
--- a/src/mesa/drivers/dri/radeon/radeon_tcl.c
+++ b/src/mesa/drivers/dri/radeon/radeon_tcl.c
@@ -39,6 +39,8 @@ WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
#include "main/enums.h"
#include "main/state.h"
+#include "util/macros.h"
+
#include "vbo/vbo.h"
#include "tnl/tnl.h"
#include "tnl/t_pipeline.h"
@@ -297,7 +299,7 @@ static GLuint radeonEnsureEmitSize( struct gl_context * ctx , GLuint inputs )
VERT_BIT_FOG
};
/* predict number of aos to emit */
- for (i=0; i < sizeof(flags_to_check)/sizeof(flags_to_check[0]); ++i)
+ for (i=0; i < ARRAY_SIZE(flags_to_check); ++i)
{
if (inputs & flags_to_check[i])
++nr_aos;