freedreno: Reuse u_math.h instead of open coding ALIGN/ARRAY_SIZE.
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/6360>
This commit is contained in:
@@ -24,6 +24,8 @@
|
||||
#ifndef REDUMP_H_
|
||||
#define REDUMP_H_
|
||||
|
||||
#include "util/u_math.h"
|
||||
|
||||
enum rd_sect_type {
|
||||
RD_NONE,
|
||||
RD_TEST, /* ascii text */
|
||||
@@ -79,12 +81,6 @@ void rd_write_section(enum rd_sect_type type, const void *buf, int sz)
|
||||
rd_write_section(t, b, s); \
|
||||
} while (0)
|
||||
|
||||
#ifndef ARRAY_SIZE
|
||||
#define ARRAY_SIZE(arr) (sizeof(arr) / sizeof((arr)[0]))
|
||||
#endif
|
||||
#undef ALIGN
|
||||
#define ALIGN(v, a) (((v) + (a)-1) & ~((a)-1))
|
||||
|
||||
#define min(a, b) (((a) < (b)) ? (a) : (b))
|
||||
#define max(a, b) (((a) > (b)) ? (a) : (b))
|
||||
|
||||
|
||||
Reference in New Issue
Block a user