/Linux-v5.4/drivers/gpu/drm/i915/ |
D | intel_uncore.c | 107 GEM_BUG_ON(d->uncore->fw_domains_timer & d->mask); in fw_domain_arm_timer() 108 d->uncore->fw_domains_timer |= d->mask; in fw_domain_arm_timer() 243 fw_domains_get(struct intel_uncore *uncore, enum forcewake_domains fw_domains) in fw_domains_get() argument 248 GEM_BUG_ON(fw_domains & ~uncore->fw_domains); in fw_domains_get() 250 for_each_fw_domain_masked(d, fw_domains, uncore, tmp) { in fw_domains_get() 255 for_each_fw_domain_masked(d, fw_domains, uncore, tmp) in fw_domains_get() 258 uncore->fw_domains_active |= fw_domains; in fw_domains_get() 262 fw_domains_get_with_fallback(struct intel_uncore *uncore, in fw_domains_get_with_fallback() argument 268 GEM_BUG_ON(fw_domains & ~uncore->fw_domains); in fw_domains_get_with_fallback() 270 for_each_fw_domain_masked(d, fw_domains, uncore, tmp) { in fw_domains_get_with_fallback() [all …]
|
D | intel_uncore.h | 75 void (*force_wake_get)(struct intel_uncore *uncore, 77 void (*force_wake_put)(struct intel_uncore *uncore, 80 enum forcewake_domains (*read_fw_domains)(struct intel_uncore *uncore, 82 enum forcewake_domains (*write_fw_domains)(struct intel_uncore *uncore, 85 u8 (*mmio_readb)(struct intel_uncore *uncore, 87 u16 (*mmio_readw)(struct intel_uncore *uncore, 89 u32 (*mmio_readl)(struct intel_uncore *uncore, 91 u64 (*mmio_readq)(struct intel_uncore *uncore, 94 void (*mmio_writeb)(struct intel_uncore *uncore, 96 void (*mmio_writew)(struct intel_uncore *uncore, [all …]
|
D | intel_sideband.c | 96 struct intel_uncore *uncore = &i915->uncore; in vlv_sideband_rw() local 105 if (intel_wait_for_register(uncore, in vlv_sideband_rw() 115 intel_uncore_write_fw(uncore, VLV_IOSF_ADDR, addr); in vlv_sideband_rw() 116 intel_uncore_write_fw(uncore, VLV_IOSF_DATA, is_read ? 0 : *val); in vlv_sideband_rw() 117 intel_uncore_write_fw(uncore, VLV_IOSF_DOORBELL_REQ, in vlv_sideband_rw() 125 if (__intel_wait_for_register_fw(uncore, in vlv_sideband_rw() 129 *val = intel_uncore_read_fw(uncore, VLV_IOSF_DATA); in vlv_sideband_rw() 278 struct intel_uncore *uncore = &i915->uncore; in intel_sbi_rw() local 283 if (intel_wait_for_register_fw(uncore, in intel_sbi_rw() 290 intel_uncore_write_fw(uncore, SBI_ADDR, (u32)reg << 16); in intel_sbi_rw() [all …]
|
D | i915_irq.h | 135 void gen2_irq_reset(struct intel_uncore *uncore); 136 void gen3_irq_reset(struct intel_uncore *uncore, i915_reg_t imr, 139 void gen2_irq_init(struct intel_uncore *uncore, 141 void gen3_irq_init(struct intel_uncore *uncore, 146 #define GEN8_IRQ_RESET_NDX(uncore, type, which) \ argument 149 gen3_irq_reset((uncore), GEN8_##type##_IMR(which_), \ 153 #define GEN3_IRQ_RESET(uncore, type) \ argument 154 gen3_irq_reset((uncore), type##IMR, type##IIR, type##IER) 156 #define GEN2_IRQ_RESET(uncore) \ argument 157 gen2_irq_reset(uncore) [all …]
|
D | i915_gem_fence_reg.c | 98 struct intel_uncore *uncore = &fence->i915->uncore; in i965_write_fence_reg() local 110 intel_uncore_write_fw(uncore, fence_reg_lo, 0); in i965_write_fence_reg() 111 intel_uncore_posting_read_fw(uncore, fence_reg_lo); in i965_write_fence_reg() 113 intel_uncore_write_fw(uncore, fence_reg_hi, upper_32_bits(val)); in i965_write_fence_reg() 114 intel_uncore_write_fw(uncore, fence_reg_lo, lower_32_bits(val)); in i965_write_fence_reg() 115 intel_uncore_posting_read_fw(uncore, fence_reg_lo); in i965_write_fence_reg() 151 struct intel_uncore *uncore = &fence->i915->uncore; in i915_write_fence_reg() local 154 intel_uncore_write_fw(uncore, reg, val); in i915_write_fence_reg() 155 intel_uncore_posting_read_fw(uncore, reg); in i915_write_fence_reg() 183 struct intel_uncore *uncore = &fence->i915->uncore; in i830_write_fence_reg() local [all …]
|
D | i915_irq.c | 178 void gen3_irq_reset(struct intel_uncore *uncore, i915_reg_t imr, in gen3_irq_reset() argument 181 intel_uncore_write(uncore, imr, 0xffffffff); in gen3_irq_reset() 182 intel_uncore_posting_read(uncore, imr); in gen3_irq_reset() 184 intel_uncore_write(uncore, ier, 0); in gen3_irq_reset() 187 intel_uncore_write(uncore, iir, 0xffffffff); in gen3_irq_reset() 188 intel_uncore_posting_read(uncore, iir); in gen3_irq_reset() 189 intel_uncore_write(uncore, iir, 0xffffffff); in gen3_irq_reset() 190 intel_uncore_posting_read(uncore, iir); in gen3_irq_reset() 193 void gen2_irq_reset(struct intel_uncore *uncore) in gen2_irq_reset() argument 195 intel_uncore_write16(uncore, GEN2_IMR, 0xffff); in gen2_irq_reset() [all …]
|
D | i915_vgpu.c | 222 struct intel_uncore *uncore = &ggtt->vm.i915->uncore; in intel_vgt_balloon() local 233 intel_uncore_read(uncore, vgtif_reg(avail_rs.mappable_gmadr.base)); in intel_vgt_balloon() 235 intel_uncore_read(uncore, vgtif_reg(avail_rs.mappable_gmadr.size)); in intel_vgt_balloon() 237 intel_uncore_read(uncore, vgtif_reg(avail_rs.nonmappable_gmadr.base)); in intel_vgt_balloon() 239 intel_uncore_read(uncore, vgtif_reg(avail_rs.nonmappable_gmadr.size)); in intel_vgt_balloon()
|
D | i915_gpu_error.c | 1041 struct intel_uncore *uncore = &dev_priv->uncore; in gem_record_fences() local 1047 intel_uncore_read64(uncore, in gem_record_fences() 1052 intel_uncore_read64(uncore, in gem_record_fences() 1057 intel_uncore_read(uncore, FENCE_REG(i)); in gem_record_fences() 1496 struct intel_uncore *uncore = &i915->uncore; in capture_reg_state() local 1509 error->gtier[0] = intel_uncore_read(uncore, GTIER); in capture_reg_state() 1510 error->ier = intel_uncore_read(uncore, VLV_IER); in capture_reg_state() 1511 error->forcewake = intel_uncore_read_fw(uncore, FORCEWAKE_VLV); in capture_reg_state() 1515 error->err_int = intel_uncore_read(uncore, GEN7_ERR_INT); in capture_reg_state() 1518 error->fault_data0 = intel_uncore_read(uncore, in capture_reg_state() [all …]
|
/Linux-v5.4/drivers/gpu/drm/i915/gt/ |
D | intel_gt_irq.c | 42 void __iomem * const regs = gt->uncore->regs; in gen11_gt_engine_identity() 127 void __iomem * const regs = gt->uncore->regs; in gen11_gt_bank_handler() 162 void __iomem * const regs = gt->uncore->regs; in gen11_gt_reset_one_iir() 191 struct intel_uncore *uncore = gt->uncore; in gen11_gt_irq_reset() local 194 intel_uncore_write(uncore, GEN11_RENDER_COPY_INTR_ENABLE, 0); in gen11_gt_irq_reset() 195 intel_uncore_write(uncore, GEN11_VCS_VECS_INTR_ENABLE, 0); in gen11_gt_irq_reset() 198 intel_uncore_write(uncore, GEN11_RCS0_RSVD_INTR_MASK, ~0); in gen11_gt_irq_reset() 199 intel_uncore_write(uncore, GEN11_BCS_RSVD_INTR_MASK, ~0); in gen11_gt_irq_reset() 200 intel_uncore_write(uncore, GEN11_VCS0_VCS1_INTR_MASK, ~0); in gen11_gt_irq_reset() 201 intel_uncore_write(uncore, GEN11_VCS2_VCS3_INTR_MASK, ~0); in gen11_gt_irq_reset() [all …]
|
D | intel_gt.c | 14 gt->uncore = &i915->uncore; in intel_gt_init_early() 32 static void rmw_set(struct intel_uncore *uncore, i915_reg_t reg, u32 set) in rmw_set() argument 34 intel_uncore_rmw(uncore, reg, 0, set); in rmw_set() 37 static void rmw_clear(struct intel_uncore *uncore, i915_reg_t reg, u32 clr) in rmw_clear() argument 39 intel_uncore_rmw(uncore, reg, clr, 0); in rmw_clear() 42 static void clear_register(struct intel_uncore *uncore, i915_reg_t reg) in clear_register() argument 44 intel_uncore_rmw(uncore, reg, 0, 0); in clear_register() 58 struct intel_uncore *uncore = gt->uncore; in intel_gt_clear_error_registers() local 62 clear_register(uncore, PGTBL_ER); in intel_gt_clear_error_registers() 65 clear_register(uncore, IPEIR(RENDER_RING_BASE)); in intel_gt_clear_error_registers() [all …]
|
D | intel_gt_pm_irq.c | 16 struct intel_uncore *uncore = gt->uncore; in write_pm_imr() local 29 intel_uncore_write(uncore, reg, mask); in write_pm_imr() 64 struct intel_uncore *uncore = gt->uncore; in gen6_gt_pm_reset_iir() local 69 intel_uncore_write(uncore, reg, reset_mask); in gen6_gt_pm_reset_iir() 70 intel_uncore_write(uncore, reg, reset_mask); in gen6_gt_pm_reset_iir() 71 intel_uncore_posting_read(uncore, reg); in gen6_gt_pm_reset_iir() 77 struct intel_uncore *uncore = gt->uncore; in write_pm_ier() local 90 intel_uncore_write(uncore, reg, mask); in write_pm_ier()
|
D | intel_reset.c | 30 static void rmw_set_fw(struct intel_uncore *uncore, i915_reg_t reg, u32 set) in rmw_set_fw() argument 32 intel_uncore_rmw_fw(uncore, reg, 0, set); in rmw_set_fw() 35 static void rmw_clear_fw(struct intel_uncore *uncore, i915_reg_t reg, u32 clr) in rmw_clear_fw() argument 37 intel_uncore_rmw_fw(uncore, reg, clr, 0); in rmw_clear_fw() 189 struct intel_uncore *uncore = gt->uncore; in g4x_do_reset() local 193 rmw_set_fw(uncore, VDECCLK_GATE_D, VCP_UNIT_CLOCK_GATE_DISABLE); in g4x_do_reset() 194 intel_uncore_posting_read_fw(uncore, VDECCLK_GATE_D); in g4x_do_reset() 215 rmw_clear_fw(uncore, VDECCLK_GATE_D, VCP_UNIT_CLOCK_GATE_DISABLE); in g4x_do_reset() 216 intel_uncore_posting_read_fw(uncore, VDECCLK_GATE_D); in g4x_do_reset() 225 struct intel_uncore *uncore = gt->uncore; in ironlake_do_reset() local [all …]
|
D | intel_mocs.c | 370 struct intel_uncore *uncore = gt->uncore; in intel_mocs_init_engine() local 380 assert_forcewakes_active(uncore, FORCEWAKE_ALL); in intel_mocs_init_engine() 391 intel_uncore_write_fw(uncore, in intel_mocs_init_engine() 398 intel_uncore_write_fw(uncore, in intel_mocs_init_engine() 405 struct intel_uncore *uncore = gt->uncore; in intel_mocs_init_global() local 418 intel_uncore_write(uncore, in intel_mocs_init_global() 428 intel_uncore_write(uncore, in intel_mocs_init_global() 542 struct intel_uncore *uncore = gt->uncore; in intel_mocs_init_l3cc_table() local 557 intel_uncore_write(uncore, in intel_mocs_init_l3cc_table() 566 intel_uncore_write(uncore, in intel_mocs_init_l3cc_table() [all …]
|
D | intel_engine_cs.c | 299 engine->uncore = gt->uncore; in intel_engine_setup() 856 struct intel_uncore *uncore = engine->uncore; in intel_engine_stop_cs() local 866 intel_uncore_write_fw(uncore, mode, _MASKED_BIT_ENABLE(STOP_RING)); in intel_engine_stop_cs() 869 if (__intel_wait_for_register_fw(uncore, in intel_engine_stop_cs() 878 intel_uncore_posting_read_fw(uncore, mode); in intel_engine_stop_cs() 906 struct intel_uncore *uncore = engine->uncore; in read_subslice_reg() local 918 fw_domains = intel_uncore_forcewake_for_reg(uncore, reg, in read_subslice_reg() 920 fw_domains |= intel_uncore_forcewake_for_reg(uncore, in read_subslice_reg() 924 spin_lock_irq(&uncore->lock); in read_subslice_reg() 925 intel_uncore_forcewake_get__locked(uncore, fw_domains); in read_subslice_reg() [all …]
|
/Linux-v5.4/drivers/gpu/drm/i915/gt/uc/ |
D | intel_guc_fw.c | 30 static void guc_prepare_xfer(struct intel_uncore *uncore) in guc_prepare_xfer() argument 40 intel_uncore_write(uncore, GUC_SHIM_CONTROL, shim_flags); in guc_prepare_xfer() 42 if (IS_GEN9_LP(uncore->i915)) in guc_prepare_xfer() 43 intel_uncore_write(uncore, GEN9LP_GT_PM_CONFIG, GT_DOORBELL_ENABLE); in guc_prepare_xfer() 45 intel_uncore_write(uncore, GEN9_GT_PM_CONFIG, GT_DOORBELL_ENABLE); in guc_prepare_xfer() 47 if (IS_GEN(uncore->i915, 9)) { in guc_prepare_xfer() 49 intel_uncore_rmw(uncore, GEN7_MISCCPCTL, in guc_prepare_xfer() 53 intel_uncore_write(uncore, GUC_ARAT_C6DIS, 0x1FF); in guc_prepare_xfer() 59 struct intel_uncore *uncore) in guc_xfer_rsa() argument 69 intel_uncore_write(uncore, UOS_RSA_SCRATCH(i), rsa[i]); in guc_xfer_rsa() [all …]
|
D | intel_guc.c | 16 intel_uncore_write(gt->uncore, GUC_SEND_INTERRUPT, GUC_SEND_TRIGGER); in gen8_guc_raise_irq() 23 intel_uncore_write(gt->uncore, GEN11_GUC_HOST_INTERRUPT, 0); in gen11_guc_raise_irq() 52 fw_domains |= intel_uncore_forcewake_for_reg(gt->uncore, in intel_guc_init_send_regs() 230 struct intel_uncore *uncore = guc_to_gt(guc)->uncore; in intel_guc_write_params() local 238 intel_uncore_forcewake_get(uncore, FORCEWAKE_BLITTER); in intel_guc_write_params() 240 intel_uncore_write(uncore, SOFT_SCRATCH(0), 0); in intel_guc_write_params() 243 intel_uncore_write(uncore, SOFT_SCRATCH(1 + i), guc->params[i]); in intel_guc_write_params() 245 intel_uncore_forcewake_put(uncore, FORCEWAKE_BLITTER); in intel_guc_write_params() 348 struct intel_uncore *uncore = guc_to_gt(guc)->uncore; in intel_guc_send_mmio() local 364 intel_uncore_forcewake_get(uncore, guc->send_regs.fw_domains); in intel_guc_send_mmio() [all …]
|
D | intel_uc.c | 33 guc_status = intel_uncore_read(gt->uncore, GUC_STATUS); in __intel_uc_reset_hw() 134 intel_uncore_write(guc_to_gt(guc)->uncore, SOFT_SCRATCH(15), 0); in guc_clear_mmio_msg() 143 val = intel_uncore_read(guc_to_gt(guc)->uncore, SOFT_SCRATCH(15)); in guc_get_mmio_msg() 353 struct intel_uncore *uncore = gt->uncore; in uc_init_wopcm() local 376 err = intel_uncore_write_and_verify(uncore, GUC_WOPCM_SIZE, size, mask, in uc_init_wopcm() 382 err = intel_uncore_write_and_verify(uncore, DMA_GUC_WOPCM_OFFSET, in uc_init_wopcm() 395 intel_uncore_read(uncore, DMA_GUC_WOPCM_OFFSET)); in uc_init_wopcm() 398 intel_uncore_read(uncore, GUC_WOPCM_SIZE)); in uc_init_wopcm() 406 struct intel_uncore *uncore = gt->uncore; in uc_is_wopcm_locked() local 408 return (intel_uncore_read(uncore, GUC_WOPCM_SIZE) & GUC_WOPCM_SIZE_LOCKED) || in uc_is_wopcm_locked() [all …]
|
D | intel_uc_fw.c | 444 struct intel_uncore *uncore = gt->uncore; in uc_fw_xfer() local 452 intel_uncore_forcewake_get(uncore, FORCEWAKE_ALL); in uc_fw_xfer() 457 intel_uncore_write_fw(uncore, DMA_ADDR_0_LOW, lower_32_bits(offset)); in uc_fw_xfer() 458 intel_uncore_write_fw(uncore, DMA_ADDR_0_HIGH, upper_32_bits(offset)); in uc_fw_xfer() 461 intel_uncore_write_fw(uncore, DMA_ADDR_1_LOW, wopcm_offset); in uc_fw_xfer() 462 intel_uncore_write_fw(uncore, DMA_ADDR_1_HIGH, DMA_ADDRESS_SPACE_WOPCM); in uc_fw_xfer() 468 intel_uncore_write_fw(uncore, DMA_COPY_SIZE, in uc_fw_xfer() 472 intel_uncore_write_fw(uncore, DMA_CTRL, in uc_fw_xfer() 476 ret = intel_wait_for_register_fw(uncore, DMA_CTRL, START_DMA, 0, 100); in uc_fw_xfer() 480 intel_uncore_read_fw(uncore, DMA_CTRL)); in uc_fw_xfer() [all …]
|
/Linux-v5.4/arch/x86/events/amd/ |
D | uncore.c | 129 struct amd_uncore *uncore = event_to_amd_uncore(event); in amd_uncore_add() local 133 if (hwc->idx != -1 && uncore->events[hwc->idx] == event) in amd_uncore_add() 136 for (i = 0; i < uncore->num_counters; i++) { in amd_uncore_add() 137 if (uncore->events[i] == event) { in amd_uncore_add() 145 for (i = 0; i < uncore->num_counters; i++) { in amd_uncore_add() 146 if (cmpxchg(&uncore->events[i], NULL, event) == NULL) { in amd_uncore_add() 156 hwc->config_base = uncore->msr_base + (2 * hwc->idx); in amd_uncore_add() 157 hwc->event_base = uncore->msr_base + 1 + (2 * hwc->idx); in amd_uncore_add() 158 hwc->event_base_rdpmc = uncore->rdpmc_base + hwc->idx; in amd_uncore_add() 170 struct amd_uncore *uncore = event_to_amd_uncore(event); in amd_uncore_del() local [all …]
|
/Linux-v5.4/drivers/gpu/drm/i915/selftests/ |
D | intel_uncore.c | 143 struct intel_uncore *uncore = &i915->uncore; in live_forcewake_ops() local 181 for_each_fw_domain(domain, uncore, tmp) { in live_forcewake_ops() 191 u32 __iomem *reg = uncore->regs + engine->mmio_base + r->offset; in live_forcewake_ops() 198 fw_domains = intel_uncore_forcewake_for_reg(uncore, mmio, in live_forcewake_ops() 203 for_each_fw_domain_masked(domain, fw_domains, uncore, tmp) { in live_forcewake_ops() 213 intel_uncore_forcewake_get(uncore, fw_domains); in live_forcewake_ops() 215 intel_uncore_forcewake_put(uncore, fw_domains); in live_forcewake_ops() 218 for_each_fw_domain_masked(domain, fw_domains, uncore, tmp) { in live_forcewake_ops() 258 struct intel_uncore *uncore = &dev_priv->uncore; in live_forcewake_domains() local 278 intel_uncore_forcewake_get(uncore, FORCEWAKE_ALL); in live_forcewake_domains() [all …]
|
D | mock_uncore.c | 29 nop_write##x(struct intel_uncore *uncore, i915_reg_t reg, u##x val, bool trace) { } 36 nop_read##x(struct intel_uncore *uncore, i915_reg_t reg, bool trace) { return 0; } 42 void mock_uncore_init(struct intel_uncore *uncore) in mock_uncore_init() argument 44 ASSIGN_RAW_WRITE_MMIO_VFUNCS(uncore, nop); in mock_uncore_init() 45 ASSIGN_RAW_READ_MMIO_VFUNCS(uncore, nop); in mock_uncore_init()
|
/Linux-v5.4/drivers/gpu/drm/i915/display/ |
D | intel_tc.c | 31 return intel_uncore_read(&i915->uncore, in has_modular_fia() 52 struct intel_uncore *uncore = &i915->uncore; in intel_tc_port_get_lane_mask() local 55 lane_mask = intel_uncore_read(uncore, in intel_tc_port_get_lane_mask() 100 struct intel_uncore *uncore = &i915->uncore; in intel_tc_port_set_fia_lane_count() local 105 val = intel_uncore_read(uncore, in intel_tc_port_set_fia_lane_count() 125 intel_uncore_write(uncore, in intel_tc_port_set_fia_lane_count() 154 struct intel_uncore *uncore = &i915->uncore; in tc_port_live_status_mask() local 158 val = intel_uncore_read(uncore, in tc_port_live_status_mask() 172 if (intel_uncore_read(uncore, SDEISR) & SDE_TC_HOTPLUG_ICP(tc_port)) in tc_port_live_status_mask() 186 struct intel_uncore *uncore = &i915->uncore; in icl_tc_phy_status_complete() local [all …]
|
D | intel_gmbus.c | 193 struct intel_uncore *uncore = &i915->uncore; in get_reserved() local 198 reserved = intel_uncore_read_notrace(uncore, bus->gpio_reg) & in get_reserved() 208 struct intel_uncore *uncore = &bus->dev_priv->uncore; in get_clock() local 211 intel_uncore_write_notrace(uncore, in get_clock() 214 intel_uncore_write_notrace(uncore, bus->gpio_reg, reserved); in get_clock() 216 return (intel_uncore_read_notrace(uncore, bus->gpio_reg) & in get_clock() 223 struct intel_uncore *uncore = &bus->dev_priv->uncore; in get_data() local 226 intel_uncore_write_notrace(uncore, in get_data() 229 intel_uncore_write_notrace(uncore, bus->gpio_reg, reserved); in get_data() 231 return (intel_uncore_read_notrace(uncore, bus->gpio_reg) & in get_data() [all …]
|
D | intel_crt.c | 643 struct intel_uncore *uncore = &dev_priv->uncore; in intel_crt_load_detect() local 664 save_bclrpat = intel_uncore_read(uncore, bclrpat_reg); in intel_crt_load_detect() 665 save_vtotal = intel_uncore_read(uncore, vtotal_reg); in intel_crt_load_detect() 666 vblank = intel_uncore_read(uncore, vblank_reg); in intel_crt_load_detect() 675 intel_uncore_write(uncore, bclrpat_reg, 0x500050); in intel_crt_load_detect() 678 u32 pipeconf = intel_uncore_read(uncore, pipeconf_reg); in intel_crt_load_detect() 679 intel_uncore_write(uncore, in intel_crt_load_detect() 682 intel_uncore_posting_read(uncore, pipeconf_reg); in intel_crt_load_detect() 686 st00 = intel_uncore_read8(uncore, _VGA_MSR_WRITE); in intel_crt_load_detect() 691 intel_uncore_write(uncore, pipeconf_reg, pipeconf); in intel_crt_load_detect() [all …]
|
/Linux-v5.4/arch/x86/events/intel/ |
D | Makefile | 7 obj-$(CONFIG_PERF_EVENTS_INTEL_UNCORE) += intel-uncore.o 8 intel-uncore-objs := uncore.o uncore_nhmex.o uncore_snb.o uncore_snbep.o
|