radeonsi/gfx9: don't read back non-existent register SRBM_STATUS2
authorMarek Olšák <marek.olsak@amd.com>
Sun, 9 Jul 2017 23:33:38 +0000 (01:33 +0200)
committerMarek Olšák <marek.olsak@amd.com>
Mon, 17 Jul 2017 14:56:56 +0000 (10:56 -0400)
It looks like there is no way to monitor SDMA busyness on GFX9.

Reviewed-by: Nicolai Hähnle <nicolai.haehnle@amd.com>
src/gallium/drivers/radeon/r600_gpu_load.c

index 3b45545..d8f7c3d 100644 (file)
@@ -105,7 +105,7 @@ static void r600_update_mmio_counters(struct r600_common_screen *rscreen,
        UPDATE_COUNTER(gui, GUI_ACTIVE);
        gui_busy = GUI_ACTIVE(value);
 
-       if (rscreen->chip_class >= CIK) {
+       if (rscreen->chip_class == CIK || rscreen->chip_class == VI) {
                /* SRBM_STATUS2 */
                rscreen->ws->read_registers(rscreen->ws, SRBM_STATUS2, 1, &value);