1. 17 3月, 2020 1 次提交
  2. 06 3月, 2020 2 次提交
  3. 24 2月, 2020 2 次提交
  4. 06 2月, 2020 1 次提交
  5. 31 1月, 2020 1 次提交
  6. 29 12月, 2019 1 次提交
  7. 17 12月, 2019 1 次提交
  8. 27 11月, 2019 2 次提交
  9. 08 11月, 2019 1 次提交
  10. 30 10月, 2019 1 次提交
  11. 23 8月, 2019 1 次提交
    • J
      drm/i915/psr: Make PSR registers relative to transcoders · 4ab4fa10
      José Roberto de Souza 提交于
      PSR registers are a mess, some have the full address while others just
      have the additional offset from psr_mmio_base.
      
      For BDW+ psr_mmio_base is nothing more than TRANSCODER_EDP_OFFSET +
      0x800 and using it makes more difficult for people with an PSR
      register address or PSR register name from from BSpec as i915 also
      don't match the BSpec names.
      For HSW psr_mmio_base is _DDI_BUF_CTL_A + 0x800 and PSR registers are
      only available in DDIA.
      
      Other reason to make relative to transcoder is that since BDW every
      transcoder have PSR registers, so in theory it should be possible to
      have PSR enabled in a non-eDP transcoder.
      
      So for BDW+ we can use _TRANS2() to get the register offset of any
      PSR register in any transcoder while for HSW we have _HSW_PSR_ADJ
      that will calculate the register offset for the single PSR instance,
      noting that we are already guarded about trying to enable PSR in other
      port than DDIA on HSW by the 'if (dig_port->base.port != PORT_A)' in
      intel_psr_compute_config(), this check should only be valid for HSW
      and will be changed in future.
      PSR2 registers and PSR_EVENT was added after Haswell so that is why
      _PSR_ADJ() is not used in some macros.
      
      The only registers that can not be relative to transcoder are
      PSR_IMR and PSR_IIR that are not relative to anything, so keeping it
      hardcoded. That changed for TGL but it will be handled in another
      patch.
      
      Also removing BDW_EDP_PSR_BASE from GVT because it is not used as it
      is the only PSR register that GVT have.
      
      v5:
      - Macros changed to be more explicit about HSW (Dhinakaran)
      - Squashed with the patch that added the tran parameter to the
      macros (Dhinakaran)
      
      v6:
      - Checking for interruption errors after module reload in the
      transcoder that will be used (Dhinakaran)
      - Using lowercase to the registers offsets
      
      v7:
      - Removing IS_HASWELL() from registers macros(Jani)
      
      Cc: Dhinakaran Pandiyan <dhinakaran.pandiyan@intel.com>
      Cc: Rodrigo Vivi <rodrigo.vivi@intel.com>
      Cc: Jani Nikula <jani.nikula@linux.intel.com>
      Cc: Ville Syrjälä <ville.syrjala@linux.intel.com>
      Cc: Zhi Wang <zhi.a.wang@intel.com>
      Reviewed-by: NLucas De Marchi <lucas.demarchi@intel.com>
      Signed-off-by: NJosé Roberto de Souza <jose.souza@intel.com>
      Signed-off-by: NLucas De Marchi <lucas.demarchi@intel.com>
      Link: https://patchwork.freedesktop.org/patch/msgid/20190820223325.27490-1-jose.souza@intel.com
      4ab4fa10
  12. 17 6月, 2019 1 次提交
    • W
      drm/i915/gvt: ignore unexpected pvinfo write · 971afec3
      Weinan Li 提交于
      There is pvinfo writing come from vgpu might be unexpected, like
      writing to one unknown address, GVT-g should do as reserved register
      to discard any invalid write. Now GVT-g lets it write to the vreg
      without prompt error message, should ignore the unexpected pvinfo
      write access and leave the vreg as the default value.
      
      For possible guest query GVT-g host feature, this returned proper
      value instead of wrong guest setting.
      
      v2: ignore unexpected pvinfo write instead of return predefined value
      
      Fixes: e39c5add ("drm/i915/gvt: vGPU MMIO virtualization")
      Cc: Zhenyu Wang <zhenyuw@linux.intel.com>
      Reviewed-by: NZhenyu Wang <zhenyuw@linux.intel.com>
      Signed-off-by: NWeinan Li <weinan.z.li@intel.com>
      Signed-off-by: NZhenyu Wang <zhenyuw@linux.intel.com>
      971afec3
  13. 03 6月, 2019 1 次提交
    • W
      drm/i915/gvt: add F_CMD_ACCESS flag for wa regs · 3fcb01f8
      Weinan Li 提交于
      Instead of updating by MMIO write, all of the wa regs are initialized by
      wa_ctx. From host side, it should make this behavior as expected, add
      'F_CMD_ACCESS' flag to these regs and allow access by commands.
      
      [  123.557608] gvt: vgpu 2: srm access to non-render register (b11c)
      [  123.563728] gvt: vgpu 2: MI_STORE_REGISTER_MEM handler error
      [  123.569409] gvt: vgpu 2: cmd parser error
      [  123.573424] 0x0
      [  123.573425] 0x24
      
      [  123.578686] gvt: vgpu 2: scan workload error
      [  123.582958] GVT Internal error  for the guest
      [  123.587317] Now vgpu 2 will enter failsafe mode.
      [  123.591938] gvt: vgpu 2: failed to submit desc 0
      [  123.596557] gvt: vgpu 2: fail submit workload on ring 0
      [  123.601786] gvt: vgpu 2: fail to emulate MMIO write 00002230 len 4
      Acked-by: NYan Zhao <yan.y.zhao@intel.com>
      Signed-off-by: NWeinan Li <weinan.z.li@intel.com>
      Signed-off-by: NZhenyu Wang <zhenyuw@linux.intel.com>
      3fcb01f8
  14. 30 5月, 2019 3 次提交
  15. 21 5月, 2019 1 次提交
  16. 29 4月, 2019 1 次提交
  17. 25 4月, 2019 1 次提交
  18. 02 4月, 2019 1 次提交
  19. 29 3月, 2019 2 次提交
  20. 27 3月, 2019 1 次提交
  21. 11 3月, 2019 1 次提交
  22. 06 3月, 2019 1 次提交
  23. 20 2月, 2019 1 次提交
  24. 23 1月, 2019 1 次提交
  25. 14 1月, 2019 1 次提交
  26. 10 1月, 2019 3 次提交
  27. 07 12月, 2018 1 次提交
  28. 31 10月, 2018 1 次提交
    • L
      drm/i915/gvt: Handle values of EDP_PSR_IMR and EDP_PSR_IIR · 5e7154ff
      Longhe Zheng 提交于
      GVT-g only simulates DP port for guest and leaves EDP_PSR_IMR
      and EDP_PSR_IIR registers as default MMIO read/write.
      So guest won't get expected initial values of these registers when
      initializing the gpu driver, which results in following warning and logs.
      
      --------
      Interrupt register 0x64838 is not zero: 0xffffffff
      WARNING: CPU: 1 PID: 157 at drivers/gpu/drm/i915/i915_irq.c:177
      gen3_assert_iir_is_zero+0x38/0xa0
      
      Call Trace:
      gen8_de_irq_postinstall+0xa7/0x400
      gen8_irq_postinstall+0x27/0x80
      drm_irq_install+0xbc/0x140
      i915_driver_load+0xa9d/0xd50
      --------
      Because GVT-g does not handle EDP(embedded DP) simulation for guests,
      always set EDP_PSR_IMR and EDP_PSR_IIR to value 0.
      Signed-off-by: NLonghe Zheng <longhe.zheng@intel.com>
      Signed-off-by: NZhenyu Wang <zhenyuw@linux.intel.com>
      5e7154ff
  29. 18 9月, 2018 1 次提交
  30. 30 8月, 2018 3 次提交
    • C
      drm/i915/gvt: Handle GEN9_WM_CHICKEN3 with F_CMD_ACCESS. · b9b824a5
      Colin Xu 提交于
      Recent patch introduce strict check on scanning cmd:
      Commit 8d458ea0 ("drm/i915/gvt: return error on cmd access")
      
      Before 8d458ea0, if cmd_reg_handler() checks that a cmd access a mmio
      that not marked as F_CMD_ACCESS, it simply returns 0 and log an error.
      Now it will return -EBADRQC which will cause the workload fail to submit.
      
      On BXT, i915 applies WaClearHIZ_WM_CHICKEN3 which will program
      GEN9_WM_CHICKEN3 by LRI when init wa ctx. If it has no F_CMD_ACCESS flag,
      vgpu will fail to start. Also add F_MODE_MASK since it's mode mask reg.
      
      v2: Refresh commit message to elaborate issue symptom in detail.
      v3: Make SKL_PLUS share same handling since GEN9_WM_CHICKEN3 should be
          F_CMD_ACCESS from HW aspect. (yan, zhenyu)
      Signed-off-by: NColin Xu <colin.xu@intel.com>
      Acked-by: NZhao Yan <yan.y.zhao@intel.com>
      Signed-off-by: NZhenyu Wang <zhenyuw@linux.intel.com>
      b9b824a5
    • C
      drm/i915/gvt: Make correct handling to vreg BXT_PHY_CTL_FAMILY · c8ab5ac3
      Colin Xu 提交于
      Guest kernel will write to BXT_PHY_CTL_FAMILY to reset DDI PHY
      and pull BXT_PHY_CTL to check PHY status. Previous handling will
      set/reset BXT_PHY_CTL of all PHYs at same time on receiving vreg
      write to some BXT_PHY_CTL_FAMILY. If some BXT_PHY_CTL is already
      enabled, following reset to another BXT_PHY_CTL_FAMILY will clear
      the enabled BXT_PHY_CTL, which result in guest kernel print:
      
      -----------------------------------
      [drm:intel_ddi_get_hw_state [i915]]
      *ERROR* Port B enabled but PHY powered down? (PHY_CTL 00000000)
      -----------------------------------
      
      The correct handling should operate BXT_PHY_CTL_FAMILY and
      BXT_PHY_CTL on the same DDI.
      
      v2: Use correct reg define. The naming looks confusing, however
          current i915_reg.h bind DPIO_PHY0 to _PHY_CTL_FAMILY_DDI and
          bind DPIO_PHY1 to _PHY_CTL_FAMILY_EDP, pairing to
          _BXT_PHY_CTL_DDI_A and _BXT_PHY_CTL_DDI_B respectively.
      v3: v2 incorrectly map _PHY_CTL_FAMILY_EDP to _BXT_PHY_CTL_DDI_A.
          BXT_PHY_CTL() looks up DDI using PORTx but not PHYx. Based on
          DPIO_PHY to DDI mapping, make correct vreg handle to BXT_PHY_CTL
          on receiving vreg write to BXT_PHY_CTL_FAMILY. (He, Min)
      
      Current mapping according to bxt_power_wells:
      dpio-common-a:
          >>> DPIO_PHY1
          >>> BXT_DPIO_CMN_A_POWER_DOMAINS
          >>> POWER_DOMAIN_PORT_DDI_A_LANES
          >>> PORT_A
      
      dpio-common-bc:
          >>> DPIO_PHY0
          >>> BXT_DPIO_CMN_BC_POWER_DOMAINS
          >>> POWER_DOMAIN_PORT_DDI_B_LANES | POWER_DOMAIN_PORT_DDI_C_LANES
          >>> PORT_B or PORT_C
      Signed-off-by: NColin Xu <colin.xu@intel.com>
      Reviewed-by: NHe, Min <min.he@intel.com>
      Signed-off-by: NZhenyu Wang <zhenyuw@linux.intel.com>
      c8ab5ac3
    • X
      drm/i915/gvt: emulate gen9 dbuf ctl register access · 9174c1d6
      Xiaolin Zhang 提交于
      there is below call track at boot time when booting guest
      with kabylake vgpu with specifal configuration and this try to fix it.
      
      [drm:gen9_dbuf_enable [i915]] *ERROR* DBuf power enable timeout
      ------------[ cut here ]------------
      WARNING: gen9_dc_off_power_well_enable+0x224/0x230 [i915]
      Unexpected DBuf power power state (0x8000000a)
      Hardware name: Red Hat KVM, BIOS 1.11.0-2.el7 04/01/2014
      Call Trace:
       [<ffffffff99d24408>] dump_stack+0x19/0x1b
       [<ffffffff996926d8>] __warn+0xd8/0x100
       [<ffffffff9969275f>] warn_slowpath_fmt+0x5f/0x80
       [<ffffffffc07bbae4>] gen9_dc_off_power_well_enable+0x224/0x230 [i915]
       [<ffffffffc07ba9d2>] intel_power_well_enable+0x42/0x50 [i915]
       [<ffffffffc07baa6a>] __intel_display_power_get_domain+0x8a/0xb0 [i915]
       [<ffffffffc07bdb93>] intel_display_power_get+0x33/0x50 [i915]
       [<ffffffffc07bdf95>] intel_display_set_init_power+0x45/0x50 [i915]
       [<ffffffffc07be003>] intel_power_domains_init_hw+0x63/0x8a0 [i915]
       [<ffffffffc07995c3>] i915_driver_load+0xae3/0x1760 [i915]
       [<ffffffff99bd6580>] ? nvmem_register+0x500/0x500
       [<ffffffffc07a476c>] i915_pci_probe+0x2c/0x50 [i915]
       [<ffffffff9999cfea>] local_pci_probe+0x4a/0xb0
       [<ffffffff9999e729>] pci_device_probe+0x109/0x160
       [<ffffffff99a79aa5>] driver_probe_device+0xc5/0x3e0
       [<ffffffff99a79ea3>] __driver_attach+0x93/0xa0
       [<ffffffff99a79e10>] ? __device_attach+0x50/0x50
       [<ffffffff99a77645>] bus_for_each_dev+0x75/0xc0
       [<ffffffff99a7941e>] driver_attach+0x1e/0x20
       [<ffffffff99a78ec0>] bus_add_driver+0x200/0x2d0
       [<ffffffff99a7a534>] driver_register+0x64/0xf0
       [<ffffffff9999df65>] __pci_register_driver+0xa5/0xc0
       [<ffffffffc0929000>] ? 0xffffffffc0928fff
       [<ffffffffc0929059>] i915_init+0x59/0x5c [i915]
       [<ffffffff9960210a>] do_one_initcall+0xba/0x240
       [<ffffffff9971108c>] load_module+0x272c/0x2bc0
       [<ffffffff9997b990>] ? ddebug_proc_write+0xf0/0xf0
       [<ffffffff997115e5>] SyS_init_module+0xc5/0x110
       [<ffffffff99d36795>] system_call_fastpath+0x1c/0x21
      Signed-off-by: NXiaolin Zhang <xiaolin.zhang@intel.com>
      Signed-off-by: NZhenyu Wang <zhenyuw@linux.intel.com>
      9174c1d6