1. 11 3月, 2014 4 次提交
  2. 08 3月, 2014 2 次提交
  3. 04 3月, 2014 1 次提交
  4. 14 2月, 2014 1 次提交
    • I
      drm/i915: add unregister callback to connector · 4932e2c3
      Imre Deak 提交于
      Since
      
      commit d9255d57
      Author: Paulo Zanoni <paulo.r.zanoni@intel.com>
      Date:   Thu Sep 26 20:05:59 2013 -0300
      
      it became clear that we need to separate the unload sequence into two
      parts:
      
      1. remove all interfaces through which new operations on some object
         (crtc, encoder, connector) can be started and make sure all pending
         operations are completed
      2. do the actual tear down of the internal representation of the above
         objects
      
      The above commit achieved this separation for connectors by splitting
      out the sysfs removal part from the connector's destroy callback and
      doing this removal before calling drm_mode_config_cleanup() which does
      the actual tear-down of all the drm objects.
      
      Since we'll have to customize the interface removal part for different
      types of connectors in the upcoming patches, add a new unregister
      callback and move the interface removal part to it.
      
      No functional change.
      Signed-off-by: NImre Deak <imre.deak@intel.com>
      Reviewed-by: NAntti Koskipää <antti.koskipaa@linux.intel.com>
      Signed-off-by: NDaniel Vetter <daniel.vetter@ffwll.ch>
      4932e2c3
  5. 13 2月, 2014 1 次提交
  6. 05 2月, 2014 1 次提交
    • A
      drm/i915: Reorganize display pipe register accesses · a57c774a
      Antti Koskipaa 提交于
      RFCv2: Reorganize array indexing so that full offsets can be used as
      is. It makes grepping for registers in i915_reg.h much easier. Also
      move offset arrays to intel_device_info.
      
      v1: Fixed offsets for VLV, proper eDP handling
      
      v2: Fixed BCLRPAT, PIPESRC, PIPECONF and DSP* macros.
      
      v3: Added EDP pipe comment, removed redundant offset arrays for
          MSA_MISC and DDI_FUNC_CTL.
      
      v4: Rename patch and report object size increase.
      
      v5: Change location of commas, add PIPE_EDP into enum pipe
      
      v6: Insert PIPE_EDP_OFFSET into pipe offset array
      
      v7: Set I915_MAX_PIPES back to 3, change more registers accessors
          to use the new macros, get rid of _PIPE_INC and add dev_priv
          as a parameter where required by the new macros.
      
      Upcoming hardware will not have the various display pipe register
      ranges evenly spaced in memory. Change register address calculations
      into array lookups.
      
      Tested on SNB, VLV, IVB, Gen2 and HSW w/eDP.
      
      I left the UMS cruft untouched.
      
      Size differences:
         text    data     bss     dec     hex filename
       596431    4634      56  601121   92c21 i915.ko (new)
       593199    4634      56  597889   91f81 i915.ko (old)
      Signed-off-by: NAntti Koskipaa <antti.koskipaa@linux.intel.com>
      Reviewed-by: NVille Syrjälä <ville.syrjala@linux.intel.com>
      Tested-by: NVille Syrjälä <ville.syrjala@linux.intel.com>
      Signed-off-by: NDaniel Vetter <daniel.vetter@ffwll.ch>
      a57c774a
  7. 10 12月, 2013 1 次提交
  8. 28 11月, 2013 1 次提交
  9. 11 11月, 2013 1 次提交
  10. 09 11月, 2013 2 次提交
  11. 16 10月, 2013 1 次提交
  12. 01 10月, 2013 4 次提交
  13. 17 9月, 2013 2 次提交
    • V
      drm/i915: Use adjusted_mode in HDMI 12bpc clock check · d68e7c3c
      Ville Syrjälä 提交于
      The pixel clock should come from adjusted_mode not requested_mode.
      In this case the two should be the same as we don't currently
      overwrite the clock in the case of HDMI. But let's make the code
      safe against such things happening in the future.
      Signed-off-by: NVille Syrjälä <ville.syrjala@linux.intel.com>
      Reviewed-by: NDamien Lespiau <damien.lespiau@intel.com>
      Signed-off-by: NDaniel Vetter <daniel.vetter@ffwll.ch>
      d68e7c3c
    • V
      drm/i915: Fix port_clock and adjusted_mode.clock readout all over · 18442d08
      Ville Syrjälä 提交于
      Now that adjusted_mode.clock no longer contains the pixel_multiplier, we
      can kill the get_clock() callback and instead do the clock readout
      in get_pipe_config().
      
      Also i9xx_crtc_clock_get() can now extract the frequency of the PCH
      DPLL, so use it to populate port_clock accurately for PCH encoders.
      For DP in port A the encoder is still responsible for filling in
      port_clock. The FDI adjusted_mode.clock extraction is kept in place
      for some extra sanity checking, but we no longer need to pretend it's
      also the port_clock.
      
      In the encoder get_config() functions fill out adjusted_mode.clock
      based on port_clock and other details such as the DP M/N values,
      HDMI 12bpc and SDVO pixel_multiplier. For PCH encoders we will then
      do an extra sanity check to make sure the dotclock we derived from
      the FDI configuratiuon matches the one we derive from port_clock.
      
      DVO doesn't exist on PCH platforms, so it doesn't need to anything
      but assign adjusted_mode.clock=port_clock. And DDI is HSW only, so
      none of the changes apply there.
      
      v2: Use hdmi_reg color format to detect 12bpc HDMI case
      v3: Set adjusted_mode.clock for LVDS too
      v4: Rename ironlake_crtc_clock_get to ironlake_pch_clock_get,
          eliminate the useless link_freq variable.
      Signed-off-by: NVille Syrjälä <ville.syrjala@linux.intel.com>
      Reviewed-by: NJani Nikula <jani.nikula@intel.com>
      Signed-off-by: NDaniel Vetter <daniel.vetter@ffwll.ch>
      18442d08
  14. 05 9月, 2013 1 次提交
  15. 30 8月, 2013 1 次提交
  16. 22 8月, 2013 1 次提交
  17. 08 8月, 2013 5 次提交
  18. 06 8月, 2013 2 次提交
    • J
      drm/i915: rearrange vlv hdmi enable and pre_enable callbacks · b76cf76b
      Jani Nikula 提交于
      VLV wants encoder enabling before the pipe is up. This is currently
      achieved through calling the ->enable callback early, right after the
      ->pre_enable callback, in valleyview_crtc_enable(). This loses both the
      distinction between ->pre_enable and ->enable on VLV and the possibility
      to use a hook at the end of the modeset sequence.
      
      Rearrange the HDMI callbacks to make it possible to move ->enable call
      later. Basically do everything in ->pre_enable on VLV, and make ->enable
      a NOP.
      
      There should be no functional changes.
      
      v2: Rebase.
      
      v3: Explain why this is needed in the commit message (Chris).
      Signed-off-by: NJani Nikula <jani.nikula@intel.com>
      Reviewed-by: NChris Wilson <chris@chris-wilson.co.uk>
      Reviewed-by: NVille Syrjälä <ville.syrjala@linux.intel.com>
      Signed-off-by: NDaniel Vetter <daniel.vetter@ffwll.ch>
      b76cf76b
    • C
      drm/i915: Acquire dpio_lock for VLV sideband programming in DP/HDMI · 0980a60f
      Chris Wilson 提交于
      Otherwise we get flooded by the kernel warning us that we are doing
      long sequences of IO without serialisation. For example,
      
       WARNING: CPU: 0 PID: 11136 at drivers/gpu/drm/i915/intel_sideband.c:40 vlv_sideband_rw+0x48/0x1ef()
       Modules linked in:
       CPU: 0 PID: 11136 Comm: kworker/u2:0 Tainted: G        W    3.11.0-rc2+ #4
       Call Trace:
        [<c2028564>] ?  warn_slowpath_common+0x63/0x78
        [<c227ad43>] ?  vlv_sideband_rw+0x48/0x1ef
        [<c20285dd>] ?  warn_slowpath_null+0xf/0x13
        [<c227ad43>] ?  vlv_sideband_rw+0x48/0x1ef
        [<c227b060>] ?  vlv_dpio_write+0x1c/0x21
        [<c2262b3b>] ?  intel_dp_set_signal_levels+0x24a/0x385
        [<c2264909>] ?  intel_dp_complete_link_train+0x25/0x1d1
        [<c2264c55>] ?  intel_dp_check_link_status+0xf7/0x106
        [<c2238ced>] ?  i915_hotplug_work_func+0x17b/0x221
        [<c203a204>] ?  process_one_work+0x12e/0x210
        [<c203a5e4>] ?  worker_thread+0x116/0x1ad
        [<c203a4ce>] ?  rescuer_thread+0x1cb/0x1cb
        [<c203d8f5>] ?  kthread+0x67/0x6c
        [<c2457ebb>] ?  ret_from_kernel_thread+0x1b/0x30
        [<c203d88e>] ?  init_completion+0x18/0x18
      
      v2: Retire the locking in vlv_crtc_enable() and do it close to the meat.
      Signed-off-by: NChris Wilson <chris@chris-wilson.co.uk>
      Reviewed-by: NJani Nikula <jani.nikula@intel.com>
      [danvet: Squash in a s/mutex_lock/mutex_unlock/ fixup spotted by the 0
      day kernel build/coccinelle and reported by Dan Carpenter.]
      Signed-off-by: NDaniel Vetter <daniel.vetter@ffwll.ch>
      0980a60f
  19. 05 8月, 2013 1 次提交
  20. 24 7月, 2013 1 次提交
  21. 23 7月, 2013 1 次提交
    • D
      drm/i915: fix hdmi portclock limits · 7d148ef5
      Daniel Vetter 提交于
      In
      
      commit 325b9d04
      Author: Daniel Vetter <daniel.vetter@ffwll.ch>
      Date:   Fri Apr 19 11:24:33 2013 +0200
      
          drm/i915: fixup 12bpc hdmi dotclock handling
      
      I've errornously claimed that we don't yet support the hdmi 1.4
      dotclocks > 225 MHz on Haswell. But a bug report and a closer look at
      the wrpll table showed that we've supported port clocks up to 300MHz.
      
      With the new code to dynamically compute wrpll limits we should have
      no issues going up to the full 340 MHz range of hdmi 1.4, so let's
      just use that to fix this regression. That'll allow 4k over hdmi for
      free!
      
      v2: Drop the random hunk that somehow slipped in.
      
      v3: Cantiga has the original HDMI dotclock limit of 165MHz. And also
      patch up the mode filtering. To do so extract the dotclock limits into
      a little helper function.
      
      v4: Use 300MHz (from Bspec) instead of 340MHz (upper limit for hdmi
      1.3), apparently hw is not required to be able to drive the highest
      dotclocks. Suggested by Damien.
      
      Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=67048
      Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=67030
      Tested-by: Andreas Reis <andreas.reis@gmail.com> (v2)
      Cc: Damien Lespiau <damien.lespiau@intel.com>
      Reviewed-by: NDamien Lespiau <damien.lespiau@intel.com>
      Signed-off-by: NDaniel Vetter <daniel.vetter@ffwll.ch>
      7d148ef5
  22. 01 7月, 2013 1 次提交
  23. 04 6月, 2013 1 次提交
    • D
      drm/i915: store adjusted dotclock in adjusted_mode->clock · ff9a6750
      Daniel Vetter 提交于
      ... not the port clock. This allows us to kill the funny semantics
      around pixel_target_clock.
      
      Since the dpll code still needs the real port clock, add a new
      port_clock field to the pipe configuration. Handling the default case
      for that one is a bit tricky, since encoders might not consistently
      overwrite it when retrying the crtc/encoder bw arbitrage step in the
      compute config stage. Hence we need to always clear port_clock and
      update it again if the encoder hasn't put in something more specific.
      This can't be done in one step since the encoder might want to adjust
      the mode first.
      
      I was a bit on the fence whether I should subsume the pixel multiplier
      handling into the port_clock, too. But then I decided against this
      since it's on an abstract level still the dotclock of the adjusted
      mode, and only our hw makes it a bit special due to the separate pixel
      mulitplier setting (which requires that the dpll runs at the
      non-multiplied dotclock).
      
      So after this patch the adjusted_mode accurately describes the mode we
      feed into the port, after the panel fitter and pixel multiplier (or
      line doubling, if we ever bother with that) have done their job.
      Since the fdi link is between the pfit and the pixel multiplier steps
      we need to be careful with calculating the fdi link config.
      
      v2: Fix up ilk cpu pll handling.
      
      v3: Introduce an fdi_dotclock variable in ironlake_fdi_compute_config
      to make it clearer that we transmit the adjusted_mode without the
      pixel multiplier taken into account. The old code multiplied the the
      available link bw with the pixel multiplier, which results in the same
      fdi configuration, but is much more confusing.
      
      v4: Rebase on top of Imre's is_cpu_edp removal.
      
      v5: Rebase on top of Paulo's haswell watermark fixes, which introduce
      a new place which looked at the pixel_clock and so needed conversion.
      
      v6: Split out prep patches as requested by Paulo Zanoni. Also rebase
      on top of the fdi dotclock handling fix in the fdi lanes/bw
      computation code.
      
      Reviewed-by: Jesse Barnes <jbarnes@virtuousgeek.org> (v3)
      Reviewed-by: Paulo Zanoni <paulo.r.zanoni@intel.com> (v6)
      Signed-off-by: NDaniel Vetter <daniel.vetter@ffwll.ch>
      ff9a6750
  24. 24 5月, 2013 2 次提交
  25. 21 5月, 2013 1 次提交
    • J
      drm/i915: add encoder get_config function v5 · 045ac3b5
      Jesse Barnes 提交于
      We can use this for fetching encoder specific pipe_config state, like
      mode flags, adjusted clock, etc.
      
      Just used for mode flags atm, so we can check the pipe config state at
      mode set time.
      
      v2: get_config when checking hw state too
      v3: fix DVO and LVDS mode flags (Ville)
          get SDVO DTD for flag fetch (Ville)
      v4: use input timings (Ville)
          correct command used (Ville)
          remove gen4 check (Ville)
      v5: get DDI flag config too
      Signed-off-by: NJesse Barnes <jbarnes@virtuousgeek.org>
      Reviewed-by: Ville Syrjälä <ville.syrjala@linux.intel.com> (v4)
      Tested-by: Paulo Zanoni <przanoni@gmail.com> (the new hsw ddi stuff)
      Signed-off-by: NDaniel Vetter <daniel.vetter@ffwll.ch>
      045ac3b5