[PATCH umr] Fix VMID of chained IBs
Christian König
ckoenig.leichtzumerken at gmail.com
Tue Apr 10 15:29:24 UTC 2018
Am 10.04.2018 um 17:23 schrieb Tom St Denis:
> We were using the VMID field literally when inside an IB it's inherited instead
>
> Signed-off-by: Tom St Denis <tom.stdenis at amd.com>
Acked-by: Christian König <christian.koenig at amd.com>
> ---
> src/lib/dump_ib.c | 8 ++++----
> src/lib/ring_decode.c | 2 +-
> 2 files changed, 5 insertions(+), 5 deletions(-)
>
> diff --git a/src/lib/dump_ib.c b/src/lib/dump_ib.c
> index 74a3241c309e..cbf859e3633b 100644
> --- a/src/lib/dump_ib.c
> +++ b/src/lib/dump_ib.c
> @@ -39,10 +39,10 @@ void umr_dump_ib(struct umr_asic *asic, struct umr_ring_decoder *decoder)
> if (decoder->src.ib_addr == 0)
> printf("ring[%s%u%s]", BLUE, (unsigned)decoder->src.addr, RST);
> else
> - printf("IB[%s%u%s] at %s%d%s@%s0x%llx%s",
> - BLUE, (unsigned)decoder->src.addr, RST,
> - YELLOW, (int)decoder->src.vmid, RST,
> - YELLOW, (unsigned long long)decoder->src.ib_addr, RST);
> + printf("IB[%s%u%s@%s0x%llx%s + %s0x%x%s]",
> + BLUE, (int)decoder->src.vmid, RST,
> + YELLOW, (unsigned long long)decoder->src.ib_addr, RST,
> + YELLOW, (unsigned)decoder->src.addr * 4, RST);
>
> printf("\n");
>
> diff --git a/src/lib/ring_decode.c b/src/lib/ring_decode.c
> index c1d6bcb98bae..42265e0a74c9 100644
> --- a/src/lib/ring_decode.c
> +++ b/src/lib/ring_decode.c
> @@ -540,7 +540,7 @@ static void print_decode_pm4_pkt3(struct umr_asic *asic, struct umr_ring_decoder
> break;
> case 2: printf("IB_SIZE:%s%lu%s, VMID: %s%lu%s", BLUE, BITS(ib, 0, 20), RST, BLUE, BITS(ib, 24, 32), RST);
> decoder->pm4.next_ib_state.ib_size = BITS(ib, 0, 20) * 4;
> - decoder->pm4.next_ib_state.ib_vmid = BITS(ib, 24, 32);
> + decoder->pm4.next_ib_state.ib_vmid = decoder->next_ib_info.vmid ? decoder->next_ib_info.vmid : BITS(ib, 24, 32);
> add_ib_pm4(decoder);
> break;
> default: printf("Invalid word for opcode 0x%02lx", (unsigned long)decoder->pm4.cur_opcode);
More information about the amd-gfx
mailing list