1. 21 3月, 2014 1 次提交
  2. 19 3月, 2014 4 次提交
  3. 18 3月, 2014 4 次提交
  4. 11 3月, 2014 1 次提交
    • V
      drm/i915: Make encoder cloning more flexible · bc079e8b
      Ville Syrjälä 提交于
      Currently we allow encoders to indicate whether they can be part of a
      cloned set with just one flag. That's not flexible enough to describe
      the actual hardware capabilities. Instead make it a bitmask of encoder
      types with which the current encoder can be cloned.
      
      For now we set the bitmask to allow DVO+DVO and DVO+VGA, which should
      match what the old boolean flag allowed. We will add some more cloning
      options in the future.
      
      Note that this patch also removes the encoder.possible_clones setting
      from encoder setup code - we compute this dynamically.
      Signed-off-by: NVille Syrjälä <ville.syrjala@linux.intel.com>
      Reviewed-by: NRodrigo Vivi <rodrigo.vivi@gmail.com>
      [danvet: Add Ville's explanation why removing the encoder
      possible_clones is save.]
      Signed-off-by: NDaniel Vetter <daniel.vetter@ffwll.ch>
      bc079e8b
  5. 08 3月, 2014 5 次提交
    • J
      drm/i915: remove early fb allocation dependency on CONFIG_FB v2 · 484b41dd
      Jesse Barnes 提交于
      By stuffing the fb allocation into the crtc, we get mode set lifetime
      refcounting for free, but have to handle the initial pin & fence
      slightly differently.  It also means we can move the shared fb handling
      into the core rather than leaving it out in the fbdev code.
      
      v2: null out crtc->fb on error (Daniel)
          take fbdev fb ref and remove unused error path (Daniel)
      Requested-by: NDaniel Vetter <daniel@ffwll.ch>
      Signed-off-by: NJesse Barnes <jbarnes@virtuousgeek.org>
      Signed-off-by: NDaniel Vetter <daniel.vetter@ffwll.ch>
      484b41dd
    • J
      drm/i915: Wrap the preallocated BIOS framebuffer and preserve for KMS fbcon v12 · d978ef14
      Jesse Barnes 提交于
      Retrieve current framebuffer config info from the regs and create an fb
      object for the buffer the BIOS or boot loader left us.  This should
      allow for smooth transitions to userspace apps once we finish the
      initial configuration construction.
      
      v2: check for non-native modes and adjust (Jesse)
          fixup aperture and cmap frees (Imre)
          use unlocked unref if init_bios fails (Jesse)
          fix curly brace around DSPADDR check (Imre)
          comment failure path for pin_and_fence (Imre)
      v3: fixup fixup of aperture frees (Chris)
      v4: update to current bits (locking & pin_and_fence hack) (Jesse)
      v5: move fb config fetch to display code (Jesse)
          re-order hw state readout on initial load to suit fb inherit (Jesse)
          re-add pin_and_fence in fbdev code to make sure we refcount properly (Je
      v6: rename to plane_config (Daniel)
          check for valid object when initializing BIOS fb (Jesse)
          split from plane_config readout and other display changes (Jesse)
          drop use_bios_fb option (Chris)
          update comments (Jesse)
          rework fbdev_init_bios for clarity (Jesse)
          drop fb obj ref under lock (Chris)
      v7: use fb object from plane_config instead (Ville)
          take ref on fb object (Jesse)
      v8: put under i915_fastboot option (Jesse)
          fix fb ptr checking (Jesse)
          inform drm_fb_helper if we fail to enable a connector (Jesse)
          drop unnecessary enabled[] modifications in failure cases (Chris)
          split from BIOS connector config readout (Daniel)
          don't memset the fb buffer if preallocated (Chris)
          alloc ifbdev up front and pass to init_bios (Chris)
          check for bad ifbdev in restore_mode too (Chris)
      v9: fix up !fastboot bpp setting (Jesse)
          fix up !fastboot helper alloc (Jesse)
          make sure BIOS fb is sufficient for biggest active pipe (Jesse)
      v10:fix up size calculation for proposed fbs (Chris)
          go back to two pass pipe fb assignment (Chris)
          add warning for active pipes w/o fbs (Chris)
          clean up num_pipes checks in fbdev_init and fbdev_restore_mode (Chris)
          move i915.fastboot into fbdev_init (Chris)
      v11:make BIOS connector config usage unconditional (Daniel)
      v12:fix up fb vs pipe size checking (Chris)
      Signed-off-by: NJesse Barnes <jbarnes@virtuousgeek.org>
      Signed-off-by: NDaniel Vetter <daniel.vetter@ffwll.ch>
      d978ef14
    • J
      drm/i915: add plane_config fetching infrastructure v2 · 46f297fb
      Jesse Barnes 提交于
      Early at init time, we can try to read out the plane config structure
      and try to preserve it if possible.
      
      v2: alloc fb obj at init time after fetching plane config
      Signed-off-by: NJesse Barnes <jbarnes@virtuousgeek.org>
      Signed-off-by: NDaniel Vetter <daniel.vetter@ffwll.ch>
      46f297fb
    • I
      drm/i915: power domains: add vlv power wells · 77961eb9
      Imre Deak 提交于
      Based on an early draft from Jesse.
      
      Add support for powering on/off the dynamic power wells on VLV by
      registering its display and dpio dynamic power wells with the power
      domain framework.
      
      For now power on all PHY TX lanes regardless of the actual lane
      configuration. Later this can be optimized when the PHY side setup
      enables only the required lanes. Atm, it enables all lanes in all
      cases.
      
      v2:
      - undef function local COND macro after its last use (Ville)
      - Take dev_priv->irq_lock around the whole sequence of
        intel_set_cpu_fifo_underrun_reporting_nolock() and
        valleyview_disable_display_irqs(). They are short and releasing
        the lock in between only makes proving correctness more difficult.
      - sanitize local var names in vlv_power_well_enabled()
      v3:
      - rebase on latest -nightly
      Signed-off-by: NImre Deak <imre.deak@intel.com>
      Reviewed-by: NJesse Barnes <jbarnes@virtuousgeek.org>
      [danvet: Resolve conflict due to my changes in the previous patch.
      Also throw in an assert_spin_locked for safety. And finally appease
      checkpatch.]
      Signed-off-by: NDaniel Vetter <daniel.vetter@ffwll.ch>
      77961eb9
    • I
      drm/i915: add port power domains · 319be8ae
      Imre Deak 提交于
      Parts that poke port specific HW blocks like the encoder HW state
      readout or connector hotplug detect code need a way to check whether
      required power domains are on or enable/disable these. For this purpose
      add a set of power domains that refer to the port HW blocks. Get the
      proper port power domains during modeset.
      
      For now when requesting the power domain for a DDI port get it for a 4
      lane configuration. This can be optimized later to request only the 2
      lane power domain, when proper support is added on the VLV PHY side for
      this. Atm, the PHY setup code assumes a 4 lane config in all cases.
      Signed-off-by: NImre Deak <imre.deak@intel.com>
      Reviewed-by: NJesse Barnes <jbarnes@virtuousgeek.org>
      Signed-off-by: NDaniel Vetter <daniel.vetter@ffwll.ch>
      319be8ae
  6. 06 3月, 2014 1 次提交
  7. 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
  8. 13 2月, 2014 5 次提交
  9. 27 1月, 2014 1 次提交
    • R
      drm/i915: debugfs: Add support for probing DP sink CRC. · d2e216d0
      Rodrigo Vivi 提交于
      This debugfs interface will allow intel-gpu-tools test case
      to verify if screen has been updated properly on cases like PSR.
      
      v2: Accepted all Daniel's suggestions:
          * grab modeset lock
          * loop over connector and check DPMS on
          * return errors
          * use _eDP1 suffix for easy future extension
          * don't cache crc_supported neither latest crc
          * return crc as a full array and read it at once with aux.
          * use 0 to turn TEST_SINK off.
          * split the drm_helpers definitions in another patch.
      
      v3: Accepted 2 Damien's suggestion: remove h from printf hexa
          and return ENODEV when eDP not present instead of EAGAIN.
      
      v4: Accepted 2 Jani' s suggestion: 1 path for unlock and remove
          _retry from aux read.
      
      v5: removing last missing useless _retry (by Damien)
      
      Cc: Daniel Vetter <daniel.vetter@ffwll.ch>
      Cc: Damien Lespiau <damien.lespiau@intel.com>
      Cc: Jani Nikula <jani.nikula@intel.com>
      Signed-off-by: NRodrigo Vivi <rodrigo.vivi@gmail.com>
      Reviewed-by: NDamien Lespiau <damien.lespiau@intel.com>
      Signed-off-by: NDaniel Vetter <daniel.vetter@ffwll.ch>
      d2e216d0
  10. 25 1月, 2014 7 次提交
  11. 22 1月, 2014 1 次提交
    • C
      drm/i915: Wait for completion of pending flips when starved of fences · 5dce5b93
      Chris Wilson 提交于
      On older generations (gen2, gen3) the GPU requires fences for many
      operations, such as blits. The display hardware also requires fences for
      scanouts and this leads to a situation where an arbitrary number of
      fences may be pinned by old scanouts following a pageflip but before we
      have executed the unpin workqueue. This is unpredictable by userspace
      and leads to random EDEADLK when submitting an otherwise benign
      execbuffer. However, we can detect when we have an outstanding flip and
      so cause userspace to wait upon their completion before finally
      declaring that the system is starved of fences. This is really no worse
      than forcing the GPU to stall waiting for older execbuffer to retire and
      release their fences before we can reallocate them for the next
      execbuffer.
      
      v2: move the test for a pending fb unpin to a common routine for
      later reuse during eviction
      
      Reported-and-tested-by: dimon@gmx.net
      Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=73696Signed-off-by: NChris Wilson <chris@chris-wilson.co.uk>
      Reviewed-by: NJon Bloomfield <jon.bloomfield@intel.com>
      Signed-off-by: NDaniel Vetter <daniel.vetter@ffwll.ch>
      5dce5b93
  12. 11 1月, 2014 2 次提交
  13. 12 12月, 2013 2 次提交
  14. 11 12月, 2013 1 次提交
    • P
      drm/i915: add initial Runtime PM functions · 8a187455
      Paulo Zanoni 提交于
      This patch adds the initial infrastructure to allow a Runtime PM
      implementation that sets the device to its D3 state. The patch just
      adds the necessary callbacks and the initial infrastructure.
      
      We still don't have any platform that actually uses this
      infrastructure, we still don't call get/put in all the places we need
      to, and we don't have any function to save/restore the state of the
      registers. This is not a problem since no platform uses the code added
      by this patch. We have a few people simultaneously working on runtime
      PM, so this initial code could help everybody make their plans.
      
      V2: - Move some functions to intel_pm.c
          - Remove useless pm_runtime_allow() call at init
          - Remove useless pm_runtime_mark_last_busy() call at get
          - Use pm_runtime_get_sync() instead of 2 calls
          - Add a WARN to check if we're really awake
      
      V3: - Rebase.
      
      V4: - Don't need to call pci_{save,restore}_state and
            pci_set_power_sate, since they're already called by the PCI
            layer
          - Remove wrong pm_runtime_enable() call at init_runtime_pm
      Signed-off-by: NPaulo Zanoni <paulo.r.zanoni@intel.com>
      Reviewed-by: NRodrigo Vivi <rodrigo.vivi@gmail.com>
      Signed-off-by: NDaniel Vetter <daniel.vetter@ffwll.ch>
      8a187455
  15. 10 12月, 2013 2 次提交
  16. 06 12月, 2013 1 次提交
  17. 28 11月, 2013 1 次提交
    • I
      drm/i915: add intel_display_power_enabled_sw() for use in atomic ctx · ddf9c536
      Imre Deak 提交于
      Atm we call intel_display_power_enabled() from
      i915_capture_error_state() in IRQ context and then take a mutex. To fix
      this add a new intel_display_power_enabled_sw() which returns the domain
      state based on software tracking as opposed to reading the actual HW
      state.
      
      Since we use domain_use_count for this without locking on the reader
      side make sure we increase the counter only after enabling all required
      power wells and decrease it before disabling any of these power wells.
      
      Regression introduced in
      commit 1b02383464b4a915627ef3b8fd0ad7f07168c54c
      Author: Imre Deak <imre.deak@intel.com>
      Date:   Tue Sep 24 16:17:09 2013 +0300
      
          drm/i915: support for multiple power wells
      
      Note that atm we depend on the value returned by
      intel_display_power_enabled_sw() in i915_capture_error_state() to avoid
      unclaimed register access reports. This was never guaranteed though,
      since another thread can disable the power concurrently. If this is a
      problem we need another explicit way to disable the reporting during
      error captures.
      
      v2:
      - remove barriers as the caller can't depend on the value
        returned from i915_capture_error_state_sw() anyway (Ville)
      - dump the state of pipe/transcoder power domain state (Daniel)
      Reported-by: NChris Wilson <chris@chris-wilson.co.uk>
      Signed-off-by: NImre Deak <imre.deak@intel.com>
      Reviewed-by: NPaulo Zanoni <paulo.r.zanoni@intel.com>
      Signed-off-by: NDaniel Vetter <daniel.vetter@ffwll.ch>
      ddf9c536