diff options
author | Zbigniew Kempczyński <zbigniew.kempczynski@intel.com> | 2022-06-10 09:07:48 +0200 |
---|---|---|
committer | Zbigniew Kempczyński <zbigniew.kempczynski@intel.com> | 2022-06-13 17:28:24 +0200 |
commit | 899ff3663841eba92aa503d760b5d316b2e972df (patch) | |
tree | c0ed2019c11bc61fba4e2579f7753efd53c0fb4d /tests/i915/gen7_exec_parse.c | |
parent | dfc7ef0b191b45056a6006555cf0a70ae55886d8 (diff) |
lib/intel_reg: Add common MI_* macros to remove duplicates
In few tests we got some MI_* duplicates (MI_MATH for example).
Add common definitions in intel_reg.h and remove local definitions
in the tests.
v2: Definitions MI_LOAD_REGISTER_MEM_GEN8 was removed so from now
on user will need to encode length on it own. :
Signed-off-by: Zbigniew Kempczyński <zbigniew.kempczynski@intel.com>
Reviewed-by: Petri Latvala <petri.latvala@intel.com>
Diffstat (limited to 'tests/i915/gen7_exec_parse.c')
-rw-r--r-- | tests/i915/gen7_exec_parse.c | 6 |
1 files changed, 2 insertions, 4 deletions
diff --git a/tests/i915/gen7_exec_parse.c b/tests/i915/gen7_exec_parse.c index c83a7911..69b768ed 100644 --- a/tests/i915/gen7_exec_parse.c +++ b/tests/i915/gen7_exec_parse.c @@ -48,8 +48,6 @@ #define INSTR_CLIENT_SHIFT 29 #define INSTR_INVALID_CLIENT 0x7 -#define MI_LOAD_REGISTER_REG (0x2a << 23) -#define MI_STORE_REGISTER_MEM (0x24 << 23) #define MI_ARB_ON_OFF (0x8 << 23) #define MI_DISPLAY_FLIP ((0x14 << 23) | 1) @@ -374,7 +372,7 @@ static void test_allocations(int fd) static void hsw_load_register_reg(void) { uint32_t init_gpr0[16] = { - MI_LOAD_REGISTER_IMM | (3 - 2), + MI_LOAD_REGISTER_IMM, HSW_CS_GPR0, 0xabcdabc0, /* leave [1:0] zero */ MI_BATCH_BUFFER_END, @@ -386,7 +384,7 @@ static void hsw_load_register_reg(void) MI_BATCH_BUFFER_END, }; uint32_t do_lrr[16] = { - MI_LOAD_REGISTER_REG | (3 - 2), + MI_LOAD_REGISTER_REG, 0, /* [1] = src */ HSW_CS_GPR0, /* dst */ MI_BATCH_BUFFER_END, |