1. 23 5月, 2013 1 次提交
  2. 21 5月, 2013 1 次提交
    • P
      drm/i915: remove intel_update_linetime_watermarks · 1011d8c4
      Paulo Zanoni 提交于
      The spec says the linetime watermarks must be programmed before
      enabling any display low power watermarks, but we're currently
      updating the linetime watermarks after we call intel_update_watermarks
      (and only at crtc_mode_set, not at crtc_{enable,disable}). So IMHO the
      best way guarantee the linetime watermarks will be updated before the
      low power watermarks is inside the update_wm function, because it's
      the function that enables low power watermarks. And since Haswell is
      the only platform that has linetime watermarks, let's completely kill
      the "intel_update_linetime_watermarks" abstraction and just use the
      intel_update_watermarks abstraction by creating haswell_update_wm.
      
      For now haswell_update_wm is still calling sandybridge_update_wm, but
      in the future I plan to implement a function specific to Haswell.
      
      v2: - Rename patch
          - Disable LP watermarks before changing linetime WMs (Chris)
          - Add a comment explaining that this is just temporary code.
      Signed-off-by: NPaulo Zanoni <paulo.r.zanoni@intel.com>
      Reviewed-by: NVille Syrjälä <ville.syrjala@linux.intel.com>
      Signed-off-by: NDaniel Vetter <daniel.vetter@ffwll.ch>
      1011d8c4
  3. 11 5月, 2013 5 次提交
  4. 06 5月, 2013 1 次提交
  5. 01 5月, 2013 1 次提交
    • M
      drm/i915: reference count for i915_hw_contexts · dce3271b
      Mika Kuoppala 提交于
      Enabling PPGTT and also the need to track which context was guilty of
      gpu hang (arb robustness enabling) have put pressure for struct i915_hw_context
      to be more than just a placeholder for hw context state.
      
      In order to track object lifetime properly in a multi peer usage, add reference
      counting for i915_hw_context.
      
      v2: track i915_hw_context pointers instead of using ctx_ids
      (from Chris Wilson)
      
      v3 (Ben): Get rid of do_release() and handle refcounting more compactly.
      (recommended by Chis)
      
      v4: kref_* put inside static inlines (Daniel Vetter)
      remove code duplication on freeing context (Chris Wilson)
      
      v5: idr_remove and ctx->file_priv = NULL in destroy ioctl (Chris)
      This actually will cause a problem if one destroys a context and later
      refers to the idea of the context (multiple contexts may have the same
      id, but only 1 will exist in the idr).
      
      v6: Strip out the request related stuff. Reworded commit message.
      Got rid of do_destroy and introduced i915_gem_context_release_handle,
      suggested by Chris Wilson.
      
      v7: idr_remove can't be called inside idr_for_each (Chris Wilson)
      
      Signed-off-by: Ben Widawsky <ben@bwidawsk.net> (v5)
      Signed-off-by: Mika Kuoppala <mika.kuoppala@intel.com> (v7)
      Reviewed-by: NBen Widawsky <ben@bwidawsk.net>
      Reviewed-by: NChris Wilson <chris@chris-wilson.co.uk>
      [danvet: Squash sob lines, the patch ping-ponged between Ben and Mika
      a bit ...]
      Signed-off-by: NDaniel Vetter <daniel.vetter@ffwll.ch>
      dce3271b
  6. 30 4月, 2013 2 次提交
  7. 26 4月, 2013 1 次提交
  8. 25 4月, 2013 2 次提交
  9. 24 4月, 2013 1 次提交
    • J
      drm/i915: make sure GPU freq drops to minimum after entering RC6 v4 · 52ceb908
      Jesse Barnes 提交于
      On VLV, the Punit doesn't automatically drop the GPU to it's minimum
      voltage level when entering RC6, so we arm a timer to do it for us from
      the RPS interrupt handler.  It'll generally only fire when we go idle
      (or if for some reason there's a long delay between RPS interrupts), but
      won't be re-armed again until the next RPS event, so shouldn't affect
      power consumption after we go idle and it triggers.
      
      v2: use delayed work instead of timer + work queue combo (Ville)
      v3: fix up delayed work cancel (must be outside lock) (Daniel)
          fix up delayed work handling func for delayed work (Jesse)
      v4: cancel delayed work before RPS shutdown (Jani)
          pass delay not absolute time to mod_delayed_work (Jani)
      Signed-off-by: NJesse Barnes <jbarnes@virtuousgeek.org>
      Reviewed-by: NJani Nikula <jani.nikula@intel.com>
      Signed-off-by: NDaniel Vetter <daniel.vetter@ffwll.ch>
      52ceb908
  10. 23 4月, 2013 6 次提交
  11. 22 4月, 2013 1 次提交
  12. 18 4月, 2013 10 次提交
    • J
      drm/i915: turbo & RC6 support for VLV v7 · 0a073b84
      Jesse Barnes 提交于
      Uses slightly different interfaces than other platforms.
      
      v2: track actual set freq, not requested (Rohit)
          fix debug prints in init code (Jesse)
      v3: don't write sleep reg (Jesse)
          re-add RC6 wake limit write (Ben)
          fixup thresholds to match other platforms (Ben)
          clean up mem freq calculation (Ben)
          clean up debug prints (Ben)
      v4: move defines from punit patch (Ville)
      v5: remove writes to nonexistent regs (Jesse)
          put RP and RC regs together (Jesse)
          fix RC6 enable (Jesse)
      v6: use correct fuse reads from NC (Jesse)
          split out min/max funcs for use in sysfs (Jesse)
          add debugfs & sysfs freq controls (Jesse)
      v7: update with Ben's hw_max changes (Jesse)
      Signed-off-by: NJesse Barnes <jbarnes@virtuousgeek.org>
      Reviewed-by: Ben Widawsky <ben@bwidawsk.net> (v6)
      [danvet: Follow checkpatch sugggestion to use min_t to avoid casting
      fun.]
      Signed-off-by: NDaniel Vetter <daniel.vetter@ffwll.ch>
      0a073b84
    • J
      drm/i915: VLV GPU frequency to opcode functions · 855ba3be
      Jesse Barnes 提交于
      When requesting frequency changes or querying status from the Punit, we
      need to use an opcode that corresponds to the frequency, taking into
      account the memory frequency.
      Signed-off-by: NJesse Barnes <jbarnes@virtuousgeek.org>
      Acked-by: NBen Widawsky <ben@bwidawsk.net>
      Signed-off-by: NDaniel Vetter <daniel.vetter@ffwll.ch>
      855ba3be
    • V
      drm/i915: Use alphabetical names for sprites · 06da8da2
      Ville Syrjälä 提交于
      Add sprite_name() macro which should be used with the kind of sprites
      that are fixed to pipes (gen4.5+).
      
      Also use dev_priv->num_plane to calculate the sprite index insted
      assuming two sprites per pipe. This should make it print the right
      name.
      Signed-off-by: NVille Syrjälä <ville.syrjala@linux.intel.com>
      Signed-off-by: NDaniel Vetter <daniel.vetter@ffwll.ch>
      06da8da2
    • P
      drm/i915: set CPT FDI RX polarity bits based on VBT · 3f704fa2
      Paulo Zanoni 提交于
      Check the VBT to see if the machine has inverted FDI RX polarity on
      CPT. Based on this bit, set the appropriate bit on the TRANS_CHICKEN2
      registers.
      
      This should fix some machines that were showing black screens on all
      outputs.
      
      Cc: stable@vger.kernel.org
      Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=60029Signed-off-by: NPaulo Zanoni <paulo.r.zanoni@intel.com>
      Reviewed-by: NImre Deak <imre.deak@intel.com>
      Signed-off-by: NDaniel Vetter <daniel.vetter@ffwll.ch>
      3f704fa2
    • E
      drm/i915: Add Reenable Timer to turn Hotplug Detection back on (v4) · ac4c16c5
      Egbert Eich 提交于
      We disable hoptplug detection when we encounter a hotplug event
      storm. Still hotplug detection is required on some outputs (like
      Display Port). The interrupt storm may be only temporary (on certain
      Dell Laptops for instance it happens at certain charging states of
      the system). Thus we enable it after a certain grace period (2 minutes).
      Should the interrupt storm persist it will be detected immediately
      and it will be disabled again.
      
      v2: Reordered drm_i915_private: moved hotplug_reenable_timer to hpd state tracker.
      v3: Clarified loop start value,
          Removed superfluous test for Ivybridge and Haswell,
          Restructured loop to avoid deep nesting (all suggested by Ville Syrjälä)
      v4: Fixed two bugs pointed out by Jani Nikula.
      Signed-off-by: NEgbert Eich <eich@suse.de>
      Reviewed-by: NJani Nikula <jani.nikula@intel.com>
      Signed-off-by: NDaniel Vetter <daniel.vetter@ffwll.ch>
      ac4c16c5
    • E
      drm/i915: Add HPD IRQ storm detection (v5) · b543fb04
      Egbert Eich 提交于
      Add a hotplug IRQ storm detection (triggered when a hotplug interrupt
      fires more than 5 times / sec).
      Rationale:
      Despite of the many attempts to fix the problem with noisy hotplug
      interrupt lines we are still seeing systems which have issues:
      Once cause of noise seems to be bad routing of the hotplug line
      on the board: cross talk from other signals seems to cause erronous
      hotplug interrupts. This has been documented as an erratum for the
      the i945GM chipset and thus hotplug support was disabled for this
      chipset model but others seem to have this problem, too.
      
      We have seen this issue on a G35 motherboard for example:
      Even different motherboards of the same model seem to behave
      differently: while some only see only around 10-100 interrupts/s
      others seem to see 5k or more.
      We've also observed a dependency on the selected video mode.
      
      Also on certain laptops interrupt noise seems to occur duing
      battery charging when the battery is at a certain charge levels.
      
      Thus we add a simple algorithm here that detects an 'interrupt storm'
      condition.
      
      v2: Fixed comment.
      v3: Reordered drm_i915_private: moved hpd state tracking to hotplug work stuff.
      v4: Followed by Jesse Barnes to use a time_..() macro.
      v5: Fixed coding style as suggested by Jani Nikula.
      Signed-off-by: NEgbert Eich <eich@suse.de>
      Acked-by: NChris Wilson <chris@chris-wilson.co.uk>
      Reviewed-by: NJesse Barnes <jbarnes@virtuousgeek.org>
      Signed-off-by: NDaniel Vetter <daniel.vetter@ffwll.ch>
      b543fb04
    • V
      drm/i915: IVB/HSW have 32 fence register · 42b5aeab
      Ville Syrjälä 提交于
      Increase the number of fence registers to 32 on IVB/HSW. VLV however
      only has 16 fence registers according to the docs.
      
      Increasing the number of fences was attempted before [1], but there was
      some uncertainty about the maximum CPU fence number for FBC. Since then
      BSpec has been updated to state that there are in fact 32 fence registers,
      and the CPU fence number field in the SNB_DPFC_CTL_SA register is 5 bits,
      and the CPU fence number field in the ILK_DPFC_CONTROL register must be
      zero. So now it all makes sense.
      
      [1] http://lists.freedesktop.org/archives/intel-gfx/2011-October/012865.html
      
      v2: Include some background information based on the previous attempt
      Signed-off-by: NVille Syrjälä <ville.syrjala@linux.intel.com>
      Signed-off-by: NDaniel Vetter <daniel.vetter@ffwll.ch>
      42b5aeab
    • B
      drm/i915: Better overclock support · 31c77388
      Ben Widawsky 提交于
      Most importantly this will allow users to set overclock frequencies in
      sysfs. Previously the max was limited by the RP0 max as opposed to the
      overclock max. This is useful if one wants to either limit the max
      overclock frequency, or set the minimum frequency to be in the overclock
      range. It also fixes an issue where if one sets the max frequency to be
      below the overclock max, they wouldn't be able to set back the proper
      overclock max.
      
      In addition I've added a couple of other bits:
      Show the overclock freq. as max in sysfs
      Print the overclock max in debugfs.
      Print a warning if the user sets the min frequency to be in the
      overclock range.
      
      In this patch I've decided to store the hw_max when we read it from the
      pcode at init. The reason I do this is the pcode reads can fail, and are
      slow.
      
      v2: Report when user requested overclocked max (Daniel)
      Remove when user sets min to overclock range (Daniel)
      
      Reported-by: freezer from #intel-gfx on irc
      Signed-off-by: NBen Widawsky <ben@bwidawsk.net>
      Reviewed-by: NMika Kuoppala <mika.kuoppala@intel.com>
      [danvet: Fixup the s/100MHz/50MHz/ confusion in an unrelated comment
      that Mika spotted.]
      Signed-off-by: NDaniel Vetter <daniel.vetter@ffwll.ch>
      31c77388
    • B
      drm/i915: Allow PPGTT enable to fail · b7c36d25
      Ben Widawsky 提交于
      I'm really not happy that we have to support this, but this will be the
      simplest way to handle cases where PPGTT init can fail, which I promise
      will be coming in the future.
      
      v2: Resolve conflicts due to patch series reordering.
      
      Signed-off-by: Ben Widawsky <ben@bwidawsk.net> (v1)
      Signed-off-by: NDaniel Vetter <daniel.vetter@ffwll.ch>
      b7c36d25
    • B
      drm/i915: Abstract PPGTT enabling · 6197349b
      Ben Widawsky 提交于
      Since we've already set up a nice vtable to abstract other PPGTT
      functions, also abstract the actual register programming to enable
      things.
      
      This function will probably need to change a bit as we implement real
      processes.
      
      v2: Resolve conflicts due to patch series reordering.
      
      Signed-off-by: Ben Widawsky <ben@bwidawsk.net> (v1)
      Signed-off-by: NDaniel Vetter <daniel.vetter@ffwll.ch>
      6197349b
  13. 07 4月, 2013 1 次提交
    • B
      drm/i915: PCH_NOP · 40c7ead9
      Ben Widawsky 提交于
      Given certain fusing options discussed in the previous patch, it's
      possible to end up with platforms that normally have PCH but that PCH
      doesn't actually exist. In many cases, this is easily remedied with
      setting 0 pipes. This covers the other corners.
      
      Requiring this is a symptom of improper code splitting (using
      HAS_PCH_SPLIT instead of proper GEN checking, basically). I do not want
      to fix this.
      
      v2: Remove PCH reflck after change in previous patch (Daniel)
      Signed-off-by: NBen Widawsky <ben@bwidawsk.net>
      Signed-off-by: NDaniel Vetter <daniel.vetter@ffwll.ch>
      40c7ead9
  14. 03 4月, 2013 3 次提交
  15. 02 4月, 2013 1 次提交
  16. 28 3月, 2013 3 次提交