Lines Matching full:gt

45 #include "gt/intel_gt.h"
46 #include "gt/intel_gt_pm.h"
432 const struct sseu_dev_info *sseu = &ee->engine->gt->info.sseu; in error_print_instdone()
683 struct intel_gt_coredump *gt) in err_print_gt_info() argument
687 intel_gt_info_print(&gt->info, &p); in err_print_gt_info()
688 intel_sseu_print_topology(&gt->info.sseu, &p); in err_print_gt_info()
692 struct intel_gt_coredump *gt) in err_print_gt() argument
697 err_printf(m, "GT awake: %s\n", yesno(gt->awake)); in err_print_gt()
698 err_printf(m, "EIR: 0x%08x\n", gt->eir); in err_print_gt()
699 err_printf(m, "IER: 0x%08x\n", gt->ier); in err_print_gt()
700 for (i = 0; i < gt->ngtier; i++) in err_print_gt()
701 err_printf(m, "GTIER[%d]: 0x%08x\n", i, gt->gtier[i]); in err_print_gt()
702 err_printf(m, "PGTBL_ER: 0x%08x\n", gt->pgtbl_er); in err_print_gt()
703 err_printf(m, "FORCEWAKE: 0x%08x\n", gt->forcewake); in err_print_gt()
704 err_printf(m, "DERRMR: 0x%08x\n", gt->derrmr); in err_print_gt()
706 for (i = 0; i < gt->nfence; i++) in err_print_gt()
707 err_printf(m, " fence[%d] = %08llx\n", i, gt->fence[i]); in err_print_gt()
710 err_printf(m, "ERROR: 0x%08x\n", gt->error); in err_print_gt()
711 err_printf(m, "DONE_REG: 0x%08x\n", gt->done_reg); in err_print_gt()
716 gt->fault_data1, gt->fault_data0); in err_print_gt()
719 err_printf(m, "ERR_INT: 0x%08x\n", gt->err_int); in err_print_gt()
722 err_printf(m, "GTT_CACHE_EN: 0x%08x\n", gt->gtt_cache); in err_print_gt()
725 err_printf(m, "AUX_ERR_DBG: 0x%08x\n", gt->aux_err); in err_print_gt()
732 gt->sfc_done[i]); in err_print_gt()
734 err_printf(m, " GAM_DONE: 0x%08x\n", gt->gam_done); in err_print_gt()
737 for (ee = gt->engine; ee; ee = ee->next) { in err_print_gt()
745 if (gt->uc) in err_print_gt()
746 err_print_uc(m, gt->uc); in err_print_gt()
748 err_print_gt_info(m, gt); in err_print_gt()
775 for (ee = error->gt ? error->gt->engine : NULL; ee; ee = ee->next) in __err_print_to_sgl()
804 if (error->gt) in __err_print_to_sgl()
805 err_print_gt(m, error->gt); in __err_print_to_sgl()
946 static void cleanup_gt(struct intel_gt_coredump *gt) in cleanup_gt() argument
948 while (gt->engine) { in cleanup_gt()
949 struct intel_engine_coredump *ee = gt->engine; in cleanup_gt()
951 gt->engine = ee->next; in cleanup_gt()
957 if (gt->uc) in cleanup_gt()
958 cleanup_uc(gt->uc); in cleanup_gt()
960 kfree(gt); in cleanup_gt()
968 while (error->gt) { in __i915_gpu_coredump_free()
969 struct intel_gt_coredump *gt = error->gt; in __i915_gpu_coredump_free() local
971 error->gt = gt->next; in __i915_gpu_coredump_free()
972 cleanup_gt(gt); in __i915_gpu_coredump_free()
985 i915_vma_coredump_create(const struct intel_gt *gt, in i915_vma_coredump_create() argument
990 struct i915_ggtt *ggtt = gt->ggtt; in i915_vma_coredump_create()
1086 static void gt_record_fences(struct intel_gt_coredump *gt) in gt_record_fences() argument
1088 struct i915_ggtt *ggtt = gt->_gt->ggtt; in gt_record_fences()
1089 struct intel_uncore *uncore = gt->_gt->uncore; in gt_record_fences()
1094 gt->fence[i] = in gt_record_fences()
1099 gt->fence[i] = in gt_record_fences()
1104 gt->fence[i] = in gt_record_fences()
1107 gt->nfence = i; in gt_record_fences()
1400 i915_vma_coredump_create(engine->gt, in intel_engine_coredump_add_vma()
1411 i915_vma_coredump_create(engine->gt, in intel_engine_coredump_add_vma()
1417 i915_vma_coredump_create(engine->gt, in intel_engine_coredump_add_vma()
1453 gt_record_engines(struct intel_gt_coredump *gt, in gt_record_engines() argument
1459 for_each_engine(engine, gt->_gt, id) { in gt_record_engines()
1469 gt->simulated |= ee->simulated; in gt_record_engines()
1475 ee->next = gt->engine; in gt_record_engines()
1476 gt->engine = ee; in gt_record_engines()
1481 gt_record_uc(struct intel_gt_coredump *gt, in gt_record_uc() argument
1484 const struct intel_uc *uc = &gt->_gt->uc; in gt_record_uc()
1501 i915_vma_coredump_create(gt->_gt, in gt_record_uc()
1508 static void gt_capture_prepare(struct intel_gt_coredump *gt) in gt_capture_prepare() argument
1510 struct i915_ggtt *ggtt = gt->_gt->ggtt; in gt_capture_prepare()
1515 static void gt_capture_finish(struct intel_gt_coredump *gt) in gt_capture_finish() argument
1517 struct i915_ggtt *ggtt = gt->_gt->ggtt; in gt_capture_finish()
1528 static void gt_record_regs(struct intel_gt_coredump *gt) in gt_record_regs() argument
1530 struct intel_uncore *uncore = gt->_gt->uncore; in gt_record_regs()
1545 gt->gtier[0] = intel_uncore_read(uncore, GTIER); in gt_record_regs()
1546 gt->ier = intel_uncore_read(uncore, VLV_IER); in gt_record_regs()
1547 gt->forcewake = intel_uncore_read_fw(uncore, FORCEWAKE_VLV); in gt_record_regs()
1551 gt->err_int = intel_uncore_read(uncore, GEN7_ERR_INT); in gt_record_regs()
1554 gt->fault_data0 = intel_uncore_read(uncore, in gt_record_regs()
1556 gt->fault_data1 = intel_uncore_read(uncore, in gt_record_regs()
1559 gt->fault_data0 = intel_uncore_read(uncore, in gt_record_regs()
1561 gt->fault_data1 = intel_uncore_read(uncore, in gt_record_regs()
1566 gt->forcewake = intel_uncore_read_fw(uncore, FORCEWAKE); in gt_record_regs()
1567 gt->gab_ctl = intel_uncore_read(uncore, GAB_CTL); in gt_record_regs()
1568 gt->gfx_mode = intel_uncore_read(uncore, GFX_MODE); in gt_record_regs()
1573 gt->forcewake = intel_uncore_read_fw(uncore, FORCEWAKE_MT); in gt_record_regs()
1576 gt->derrmr = intel_uncore_read(uncore, DERRMR); in gt_record_regs()
1578 gt->error = intel_uncore_read(uncore, ERROR_GEN6); in gt_record_regs()
1579 gt->done_reg = intel_uncore_read(uncore, DONE_REG); in gt_record_regs()
1585 gt->gam_ecochk = intel_uncore_read(uncore, GAM_ECOCHK); in gt_record_regs()
1586 gt->gac_eco = intel_uncore_read(uncore, GAC_ECO_BITS); in gt_record_regs()
1590 gt->gtt_cache = intel_uncore_read(uncore, HSW_GTT_CACHE_EN); in gt_record_regs()
1593 gt->aux_err = intel_uncore_read(uncore, GEN12_AUX_ERR_DBG); in gt_record_regs()
1597 gt->sfc_done[i] = in gt_record_regs()
1601 gt->gam_done = intel_uncore_read(uncore, GEN12_GAM_DONE); in gt_record_regs()
1606 gt->ier = intel_uncore_read(uncore, GEN8_DE_MISC_IER); in gt_record_regs()
1607 gt->gtier[0] = in gt_record_regs()
1610 gt->gtier[1] = in gt_record_regs()
1612 gt->gtier[2] = in gt_record_regs()
1614 gt->gtier[3] = in gt_record_regs()
1617 gt->gtier[4] = in gt_record_regs()
1620 gt->gtier[5] = in gt_record_regs()
1623 gt->ngtier = 6; in gt_record_regs()
1625 gt->ier = intel_uncore_read(uncore, GEN8_DE_MISC_IER); in gt_record_regs()
1627 gt->gtier[i] = in gt_record_regs()
1629 gt->ngtier = 4; in gt_record_regs()
1631 gt->ier = intel_uncore_read(uncore, DEIER); in gt_record_regs()
1632 gt->gtier[0] = intel_uncore_read(uncore, GTIER); in gt_record_regs()
1633 gt->ngtier = 1; in gt_record_regs()
1635 gt->ier = intel_uncore_read16(uncore, GEN2_IER); in gt_record_regs()
1637 gt->ier = intel_uncore_read(uncore, GEN2_IER); in gt_record_regs()
1639 gt->eir = intel_uncore_read(uncore, EIR); in gt_record_regs()
1640 gt->pgtbl_er = intel_uncore_read(uncore, PGTBL_ER); in gt_record_regs()
1643 static void gt_record_info(struct intel_gt_coredump *gt) in gt_record_info() argument
1645 memcpy(&gt->info, &gt->_gt->info, sizeof(struct intel_gt_info)); in gt_record_info()
1672 struct intel_gt_coredump *gt; in error_msg() local
1677 for (gt = error->gt; gt; gt = gt->next) { in error_msg()
1680 if (gt->engine && !first) in error_msg()
1681 first = gt->engine; in error_msg()
1683 for (cs = gt->engine; cs; cs = cs->next) in error_msg()
1743 error->uptime = ktime_sub(ktime_get(), i915->gt.last_init_time); in i915_gpu_coredump_alloc()
1754 intel_gt_coredump_alloc(struct intel_gt *gt, gfp_t gfp) in intel_gt_coredump_alloc() argument
1762 gc->_gt = gt; in intel_gt_coredump_alloc()
1763 gc->awake = intel_gt_pm_is_awake(gt); in intel_gt_coredump_alloc()
1772 i915_vma_capture_prepare(struct intel_gt_coredump *gt) in i915_vma_capture_prepare() argument
1785 gt_capture_prepare(gt); in i915_vma_capture_prepare()
1790 void i915_vma_capture_finish(struct intel_gt_coredump *gt, in i915_vma_capture_finish() argument
1796 gt_capture_finish(gt); in i915_vma_capture_finish()
1815 error->gt = intel_gt_coredump_alloc(&i915->gt, ALLOW_FAIL); in i915_gpu_coredump()
1816 if (error->gt) { in i915_gpu_coredump()
1819 compress = i915_vma_capture_prepare(error->gt); in i915_gpu_coredump()
1821 kfree(error->gt); in i915_gpu_coredump()
1826 gt_record_info(error->gt); in i915_gpu_coredump()
1827 gt_record_engines(error->gt, compress); in i915_gpu_coredump()
1830 error->gt->uc = gt_record_uc(error->gt, compress); in i915_gpu_coredump()
1832 i915_vma_capture_finish(error->gt, compress); in i915_gpu_coredump()
1834 error->simulated |= error->gt->simulated; in i915_gpu_coredump()