1. 11 8月, 2014 1 次提交
  2. 22 7月, 2014 1 次提交
    • D
      drm/i915: add DP 1.2 MST support (v0.7) · 0e32b39c
      Dave Airlie 提交于
      This adds DP 1.2 MST support on Haswell systems.
      
      Notes:
      a) this reworks irq handling for DP MST ports, so that we can
      avoid the mode config locking in the current hpd handlers, as
      we need to process up/down msgs at a better time.
      
      Changes since v0.1:
      use PORT_PCH_HOTPLUG to detect short vs long pulses
      add a workqueue to deal with digital events as they can get blocked on the
      main workqueue beyong mode_config mutex
      fix a bunch of modeset checker warnings
      acks irqs in the driver
      cleanup the MST encoders
      
      Changes since v0.2:
      check irq status again in work handler
      move around bring up and tear down to fix DPMS on/off
      use path properties.
      
      Changes since v0.3:
      updates for mst apis
      more state checker fixes
      irq handling improvements
      fbcon handling support
      improved reference counting of link - fixes redocking.
      
      Changes since v0.4:
      handle gpu reset hpd reinit without oopsing
      check link status on HPD irqs
      fix suspend/resume
      
      Changes since v0.5:
      use proper functions to get max link/lane counts
      fix another checker backtrace - due to connectors disappearing.
      set output type in more places fro, unknown->displayport
      don't talk to devices if no HPD asserted
      check mst on short irqs only
      check link status properly
      rebase onto prepping irq changes.
      drop unsued force_act
      
      Changes since v0.6:
      cleanup unused struct entry.
      
      [airlied: fix some sparse warnings].
      Reviewed-by: NTodd Previte <tprevite@gmail.com>
      Signed-off-by: NDave Airlie <airlied@redhat.com>
      0e32b39c
  3. 05 6月, 2014 1 次提交
    • S
      drm/i915: Add support for Generic MIPI panel driver · 2ab8b458
      Shobhit Kumar 提交于
      This driver makes use of the generic panel information from the VBT.
      Panel information is classified into two - panel configuration and panel
      power sequence which is unique to each panel. The generic driver uses the
      panel configuration and sequence parsed from VBT block #52 and #53
      
      v2: Address review comments by Jani
          - Move all of the things in driver c file from header
          - Make all functions static
          - Make use of video/mipi_display.c instead of redefining
          - Null checks during sequence execution
      
      v3: Address review comments by Damien
          - Rename the panel driver file as intel_dsi_panel_vbt.c
          - Fix style changes as suggested
          - Correct comments for lp->hs and hs->lp count calculations
          - General updating comments to have more clarity
          - using max() instead of ternary operator
          - Fix names (ui_num, ui_den) while using UI in calculations
          - compute max of lp_to_hs switch and hs_to_lp switch while computing
            hs_lp_switch_count
      Signed-off-by: NShobhit Kumar <shobhit.kumar@intel.com>
      Reviewed-by: NDamien Lespiau <damien.lespiau@intel.com>
      Signed-off-by: NDaniel Vetter <daniel.vetter@ffwll.ch>
      2ab8b458
  4. 17 5月, 2014 1 次提交
    • C
      drm/i915: Introduce mapping of user pages into video memory (userptr) ioctl · 5cc9ed4b
      Chris Wilson 提交于
      By exporting the ability to map user address and inserting PTEs
      representing their backing pages into the GTT, we can exploit UMA in order
      to utilize normal application data as a texture source or even as a
      render target (depending upon the capabilities of the chipset). This has
      a number of uses, with zero-copy downloads to the GPU and efficient
      readback making the intermixed streaming of CPU and GPU operations
      fairly efficient. This ability has many widespread implications from
      faster rendering of client-side software rasterisers (chromium),
      mitigation of stalls due to read back (firefox) and to faster pipelining
      of texture data (such as pixel buffer objects in GL or data blobs in CL).
      
      v2: Compile with CONFIG_MMU_NOTIFIER
      v3: We can sleep while performing invalidate-range, which we can utilise
      to drop our page references prior to the kernel manipulating the vma
      (for either discard or cloning) and so protect normal users.
      v4: Only run the invalidate notifier if the range intercepts the bo.
      v5: Prevent userspace from attempting to GTT mmap non-page aligned buffers
      v6: Recheck after reacquire mutex for lost mmu.
      v7: Fix implicit padding of ioctl struct by rounding to next 64bit boundary.
      v8: Fix rebasing error after forwarding porting the back port.
      v9: Limit the userptr to page aligned entries. We now expect userspace
          to handle all the offset-in-page adjustments itself.
      v10: Prevent vma from being copied across fork to avoid issues with cow.
      v11: Drop vma behaviour changes -- locking is nigh on impossible.
           Use a worker to load user pages to avoid lock inversions.
      v12: Use get_task_mm()/mmput() for correct refcounting of mm.
      v13: Use a worker to release the mmu_notifier to avoid lock inversion
      v14: Decouple mmu_notifier from struct_mutex using a custom mmu_notifer
           with its own locking and tree of objects for each mm/mmu_notifier.
      v15: Prevent overlapping userptr objects, and invalidate all objects
           within the mmu_notifier range
      v16: Fix a typo for iterating over multiple objects in the range and
           rearrange error path to destroy the mmu_notifier locklessly.
           Also close a race between invalidate_range and the get_pages_worker.
      v17: Close a race between get_pages_worker/invalidate_range and fresh
           allocations of the same userptr range - and notice that
           struct_mutex was presumed to be held when during creation it wasn't.
      v18: Sigh. Fix the refactor of st_set_pages() to allocate enough memory
           for the struct sg_table and to clear it before reporting an error.
      v19: Always error out on read-only userptr requests as we don't have the
           hardware infrastructure to support them at the moment.
      v20: Refuse to implement read-only support until we have the required
           infrastructure - but reserve the bit in flags for future use.
      v21: use_mm() is not required for get_user_pages(). It is only meant to
           be used to fix up the kernel thread's current->mm for use with
           copy_user().
      v22: Use sg_alloc_table_from_pages for that chunky feeling
      v23: Export a function for sanity checking dma-buf rather than encode
           userptr details elsewhere, and clean up comments based on
           suggestions by Bradley.
      Signed-off-by: NChris Wilson <chris@chris-wilson.co.uk>
      Cc: Tvrtko Ursulin <tvrtko.ursulin@linux.intel.com>
      Cc: "Gong, Zhipeng" <zhipeng.gong@intel.com>
      Cc: Akash Goel <akash.goel@intel.com>
      Cc: "Volkin, Bradley D" <bradley.d.volkin@intel.com>
      Reviewed-by: NTvrtko Ursulin <tvrtko.ursulin@linux.intel.com>
      Reviewed-by: NBrad Volkin <bradley.d.volkin@intel.com>
      [danvet: Frob ioctl allocation to pick the next one - will cause a bit
      of fuss with create2 apparently, but such are the rules.]
      [danvet2: oops, forgot to git add after manual patch application]
      [danvet3: Appease sparse.]
      Signed-off-by: NDaniel Vetter <daniel.vetter@ffwll.ch>
      5cc9ed4b
  5. 15 5月, 2014 1 次提交
  6. 08 3月, 2014 2 次提交
    • D
      drm/i915: Go OCD on the Makefile · 2fae6a86
      Daniel Vetter 提交于
      Chris suggested to split things up a bit into the different parts of
      the driver and also sort it all correctly, with the hope that we're
      trying to organize things a bit better eventually. It should also
      help newcomers to orient themselves a bit better.
      
      v2:
      - Move intel_pm.c to the core - to make things perfect we should split
        out the modeset related pm features (psr/fbc) into a separate file.
        Maybe something Rodrigo can do once the PSR patches have settled.
      
      - Split the modesetting sections into core and encoders/outputs.
        intel_ddi.c is a bit funky since it has core hsw+ support and ddi
        output support. Whatever.
      
      v3: Failed to git add ...
      
      v4: Really go ocd, i.e. spelling fix in a comment from Jani.
      
      Cc: Chris Wilson <chris@chris-wilson.co.uk>
      Reviewed-by: NChris Wilson <chris@chris-wilson.co.uk>
      Signed-off-by: NDaniel Vetter <daniel.vetter@ffwll.ch>
      2fae6a86
    • B
      drm/i915: Implement command buffer parsing logic · 351e3db2
      Brad Volkin 提交于
      The command parser scans batch buffers submitted via execbuffer ioctls before
      the driver submits them to hardware. At a high level, it looks for several
      things:
      
      1) Commands which are explicitly defined as privileged or which should only be
         used by the kernel driver. The parser generally rejects such commands, with
         the provision that it may allow some from the drm master process.
      2) Commands which access registers. To support correct/enhanced userspace
         functionality, particularly certain OpenGL extensions, the parser provides a
         whitelist of registers which userspace may safely access (for both normal and
         drm master processes).
      3) Commands which access privileged memory (i.e. GGTT, HWS page, etc). The
         parser always rejects such commands.
      
      See the overview comment in the source for more details.
      
      This patch only implements the logic. Subsequent patches will build the tables
      that drive the parser.
      
      v2: Don't set the secure bit if the parser succeeds
      Fail harder during init
      Makefile cleanup
      Kerneldoc cleanup
      Clarify module param description
      Convert ints to bools in a few places
      Move client/subclient defs to i915_reg.h
      Remove the bits_count field
      
      OTC-Tracker: AXIA-4631
      Change-Id: I50b98c71c6655893291c78a2d1b8954577b37a30
      Signed-off-by: NBrad Volkin <bradley.d.volkin@intel.com>
      Reviewed-by: NJani Nikula <jani.nikula@intel.com>
      [danvet: Appease checkpatch.]
      Signed-off-by: NDaniel Vetter <daniel.vetter@ffwll.ch>
      351e3db2
  7. 28 1月, 2014 1 次提交
    • J
      drm/i915: move module parameters into a struct, in a new file · d330a953
      Jani Nikula 提交于
      With 20+ module parameters, I think referring to them via a struct
      improves clarity over just having a bunch of globals. While at it, move
      the parameter initialization and definitions into a new file
      i915_params.c to reduce clutter in i915_drv.c.
      
      Apart from the ill-named i915_enable_rc6, i915_enable_fbc and
      i915_enable_ppgtt parameters, for which we lose the "i915_" prefix
      internally, the module parameters now look the same both on the kernel
      command line and in code. For example, "i915.modeset".
      
      The downsides of the change are losing static on a couple of variables
      and not having the initialization and module_param_named() right next to
      each other. On the other hand, all module parameters are now defined in
      one place at i915_params.c. Plus you can do this to find all module
      parameter references:
      
      $ git grep "i915\." -- drivers/gpu/drm/i915
      
      v2:
      - move the definitions into a new file
      - s/i915_params/i915/
      - make i915_try_reset i915.reset, for consistency
      Signed-off-by: NJani Nikula <jani.nikula@intel.com>
      Signed-off-by: NDaniel Vetter <daniel.vetter@ffwll.ch>
      d330a953
  8. 16 12月, 2013 1 次提交
  9. 07 12月, 2013 1 次提交
  10. 12 10月, 2013 2 次提交
    • D
      drm/i915: rename intel_fb.c to intel_fbdev.c · 0632fef6
      Daniel Vetter 提交于
      This file is all about the legacy fbdev support. If we want to extract
      framebuffer functions, we better put those into a separate file.
      
      Also rename functions accordingly, only two have used the intel_fb_
      prefix anyway.
      Reviewed-by: NChon Ming Lee <chon.ming.lee@intel.com>
      Signed-off-by: NDaniel Vetter <daniel.vetter@ffwll.ch>
      0632fef6
    • D
      drm/i915: Kconfig option to disable the legacy fbdev support · 4520f53a
      Daniel Vetter 提交于
      Boots Just Fine (tm)!
      
      The only glitch seems to be that at least on Fedora the boot splash
      gets confused and doesn't display much at all.
      
      And since there's no ugly console flickering anymore in between, the
      flicker while switching between X servers (VT support is still enabled)
      is even more jarring.
      
      Also, I'm unsure whether we don't need to somehow kick out vgacon, now
      that nothing else gets in the way. But stuff seems to work, so I
      don't care. Also everything still works as well with VGA_CONSOLE=n
      
      Also the #ifdef mess needs a bit of a cleanup, follow-up patches will
      do just that.
      
      To keep the Kconfig tidy, extract all the i915 options into its own
      file.
      
      v2:
      - Rebase on top of the preliminary hw support option and the
        intel_drv.h cleanup.
      - Shut up warnings in i915_debugfs.c
      
      v3: Use the right CONFIG variable, spotted by Chon Ming.
      
      Cc: Lee, Chon Ming <chon.ming.lee@intel.com>
      Cc: David Herrmann <dh.herrmann@gmail.com>
      Reviewed-by: NChon Ming Lee <chon.ming.lee@intel.com>
      Signed-off-by: NDaniel Vetter <daniel.vetter@ffwll.ch>
      4520f53a
  11. 04 9月, 2013 3 次提交
  12. 25 7月, 2013 1 次提交
    • C
      drm/i915: Colocate all GT access routines in the same file · 907b28c5
      Chris Wilson 提交于
      Currently, the register access code is split between i915_drv.c and
      intel_pm.c. It only bares a superficial resemblance to the reset of the
      powermanagement code, so move it all into its own file. This is to ease
      further patches to enforce serialised register access.
      
      v2: Scan for random abuse of I915_WRITE_NOTRACE
      v3: Take the opportunity to rename the GT functions as uncore. Uncore is
      the term used by the hardware design (and bspec) for all functions
      outside of the GPU (and CPU) cores in what is also known as the System
      Agent.
      v4: Rebase onto SNB rc6 fixes
      Signed-off-by: NChris Wilson <chris@chris-wilson.co.uk>
      Reviewed-by: NBen Widawsky <ben@bwidawsk.net>
      [danvet: Wrestle patch into applying and inline
      intel_uncore_early_sanitize (plus move the old comment to the new
      function). Also keep the _santize postfix for intel_uncore_sanitize.]
      [danvet: Squash in fixup spotted by Chris on irc: We need to call
      intel_pm_init before intel_uncore_sanitize since the later will call
      cancel_work on the delayed rps setup work the former initializes.]
      Signed-off-by: NDaniel Vetter <daniel.vetter@ffwll.ch>
      907b28c5
  13. 13 7月, 2013 1 次提交
  14. 24 5月, 2013 1 次提交
  15. 31 1月, 2013 1 次提交
    • D
      drm/i915: extract ums suspend/resume into i915_ums.c · d8157a36
      Daniel Vetter 提交于
      Similarly to how i915_dma.c is shaping up to be the dungeon hole for
      all things supporting dri1, create a new one to hide all the crazy
      things which are only really useful for ums support. Biggest part is
      the register suspend/resume support.
      
      Unfortunately a lot of it is still intermingled with bits and pieces
      we might still need, so needs more analysis and needs to stay in
      i915_suspend.c for now.
      Reviewed-by: NImre Deak <imre.deak@intel.com>
      
      v2: s/modeset_reg/display_reg/ as suggested by Imre, to avoid
      confusion between the kernel modeset code and display save/restore to
      support ums.
      
      v3: Fixup alphabetical order in the Makefile, spotted by Chris Wilson.
      Signed-off-by: NDaniel Vetter <daniel.vetter@ffwll.ch>
      d8157a36
  16. 26 7月, 2012 1 次提交
    • T
      drm/i915: Support for ns2501-DVO · 7434a255
      Thomas Richter 提交于
      This patch adds support for the ns2501 DVO, found in some older Fujitsu/Siemens Labtops.
      It is in the state of "works for me".
      Includes now proper DPMS support. Includes switching between resolutions -
      from 640x480 to 1024x768.
      Currently assumes that the native display resolution is 1024x768.
      
      The ns2501 seems to be rather critical - if the output PLL is not
      running, the chip doesn't seem to be clocked and then doesn't react
      on i2c messages. Thus, a quick'n-dirty trick ensures that the DVO
      is active before submitting any i2c messages to it. This is
      probably to be reviewed.
      
      Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=17902Signed-off-by: NThomas Richter <thor@math.tu-berlin.de>
      [danvet: fixup whitespace fail.]
      Signed-off-by: NDaniel Vetter <daniel.vetter@ffwll.ch>
      7434a255
  17. 14 6月, 2012 1 次提交
    • B
      drm/i915: preliminary context support · 254f965c
      Ben Widawsky 提交于
      Very basic code for context setup/destruction in the driver.
      
      Adds the file i915_gem_context.c This file implements HW context
      support. On gen5+ a HW context consists of an opaque GPU object which is
      referenced at times of context saves and restores.  With RC6 enabled,
      the context is also referenced as the GPU enters and exists from RC6
      (GPU has it's own internal power context, except on gen5).  Though
      something like a context does exist for the media ring, the code only
      supports contexts for the render ring.
      
      In software, there is a distinction between contexts created by the
      user, and the default HW context. The default HW context is used by GPU
      clients that do not request setup of their own hardware context. The
      default context's state is never restored to help prevent programming
      errors. This would happen if a client ran and piggy-backed off another
      clients GPU state.  The default context only exists to give the GPU some
      offset to load as the current to invoke a save of the context we
      actually care about. In fact, the code could likely be constructed,
      albeit in a more complicated fashion, to never use the default context,
      though that limits the driver's ability to swap out, and/or destroy
      other contexts.
      
      All other contexts are created as a request by the GPU client. These
      contexts store GPU state, and thus allow GPU clients to not re-emit
      state (and potentially query certain state) at any time. The kernel
      driver makes certain that the appropriate commands are inserted.
      
      There are 4 entry points into the contexts, init, fini, open, close.
      The names are self-explanatory except that init can be called during
      reset, and also during pm thaw/resume. As we expect our context to be
      preserved across these events, we do not reinitialize in this case.
      
      As Adam Jackson pointed out, The cutoff of 1MB where a HW context is
      considered too big is arbitrary. The reason for this is even though
      context sizes are increasing with every generation, they have yet to
      eclipse even 32k. If we somehow read back way more than that, it
      probably means BIOS has done something strange, or we're running on a
      platform that wasn't designed for this.
      
      v2: rename load/unload to init/fini (daniel)
      remove ILK support for get_size() (indirectly daniel)
      add HAS_HW_CONTEXTS macro to clarify supported platforms (daniel)
      added comments (Ben)
      Signed-off-by: NBen Widawsky <ben@bwidawsk.net>
      254f965c
  18. 23 5月, 2012 1 次提交
    • D
      i915: add dmabuf/prime buffer sharing support. · 1286ff73
      Daniel Vetter 提交于
      This adds handle->fd and fd->handle support to i915, this is to allow
      for offloading of rendering in one direction and outputs in the other.
      
      v2 from Daniel Vetter:
      - fixup conflicts with the prepare/finish gtt prep work.
      - implement ppgtt binding support.
      
      Note that we have squat i-g-t testcoverage for any of the lifetime and
      access rules dma_buf/prime support brings along. And there are quite a
      few intricate situations here.
      
      Also note that the integration with the existing code is a bit
      hackish, especially around get_gtt_pages and put_gtt_pages. It imo
      would be easier with the prep code from Chris Wilson's unbound series,
      but that is for 3.6.
      
      Also note that I didn't bother to put the new prepare/finish gtt hooks
      to good use by moving the dma_buf_map/unmap_attachment calls in there
      (like we've originally planned for).
      
      Last but not least this patch is only compile-tested, but I've changed
      very little compared to Dave Airlie's version. So there's a decent
      chance v2 on drm-next works as well as v1 on 3.4-rc.
      
      v3: Right when I've hit sent I've noticed that I've screwed up one
      obj->sg_list (for dmar support) and obj->sg_table (for prime support)
      disdinction. We should be able to merge these 2 paths, but that's
      material for another patch.
      
      v4: fix the error reporting bugs pointed out by ickle.
      
      v5: fix another error, and stop non-gtt mmaps on shared objects
      stop pread/pwrite on imported objects, add fake kmap
      Signed-off-by: NDave Airlie <airlied@redhat.com>
      Signed-Off-by: NDaniel Vetter <daniel.vetter@ffwll.ch>
      1286ff73
  19. 20 5月, 2012 1 次提交
  20. 03 5月, 2012 1 次提交
  21. 18 4月, 2012 1 次提交
  22. 13 4月, 2012 1 次提交
    • B
      drm/i915: rc6 in sysfs · 0136db58
      Ben Widawsky 提交于
      Merge rc6 information into the power group for our device. Until now the
      i915 driver has not had any sysfs entries (aside from the connector
      stuff enabled by drm core). Since it seems like we're likely to have
      more in the future I created a new file for sysfs stubs, as well as the
      rc6 sysfs functions which don't really belong elsewhere (perhaps
      i915_suspend, but most of the stuff is in intel_display,c).
      
      displays rc6 modes enabled (as a hex mask):
      cat /sys/class/drm/card0/power/rc6_enable
      
      displays #ms GPU has been in rc6 since boot:
      cat /sys/class/drm/card0/power/rc6_residency_ms
      
      displays #ms GPU has been in deep rc6 since boot:
      cat /sys/class/drm/card0/power/rc6p_residency_ms
      
      displays #ms GPU has been in deepest rc6 since boot:
      cat /sys/class/drm/card0/power/rc6pp_residency_ms
      
      Important note: I've seen on SNB that even when RC6 is *not* enabled the
      rc6 register seems to have a random value in it. I can only guess at the
      reason reason for this. Those writing tools that utilize this value need
      to be careful and probably want to scrutinize the value very carefully.
      
      v2: use common rc6 residency units to milliseconds for the other RC6 types
      
      v3: don't create sysfs files for GEN <= 5
      add a rc6_enable to show a mask of enabled rc6 types
      use unmerge instead of remove for sysfs group
      squash intel_enable_rc6() extraction into this patch
      
      v4: rename sysfs files (Chris)
      
      CC: Chris Wilson <chris@chris-wilson.co.uk>
      CC: Daniel Vetter <daniel.vetter@ffwll.ch>f
      CC: Arjan van de Ven <arjan@linux.intel.com>
      Signed-off-by: NBen Widawsky <benjamin.widawsky@intel.com>
      Reviewed-by: NChris Wilson <chris@chris-wilson.co.uk>
      [danvet: squash in the 64bit division fix by Chris Wilson.]
      Signed-off-by: NDaniel Vetter <daniel.vetter@ffwll.ch>
      0136db58
  23. 18 1月, 2012 1 次提交
  24. 04 1月, 2012 1 次提交
    • J
      drm/i915: add SNB and IVB video sprite support v6 · b840d907
      Jesse Barnes 提交于
      The video sprites support various video surface formats natively and can
      handle scaling as well.  So add support for them using the new DRM core
      sprite support functions.
      
      v2: use drm specific fourcc header and defines
      v3: address Daniel's comments:
        - don't take struct mutex around register access (only needed for
          regs in the GT power well)
        - don't hold struct mutex across vblank waits
        - fix up update_plane API (pass obj instead of GTT offset)
        - add interlaced defines for sprite regs
        - drop unnecessary 'reg' variables
        - comment double buffered reg flushing
        Also fix w/h confusion when writing the scaling reg.
      v4: more fixes, address more comments from Daniel, and include Hai's fix
        - prevent divide by zero in scaling calculation (Hai Lan)
        - update to Ville's new DRM_FORMAT_* types
        - fix sprite watermark handling (calc based on CRTC size, separate
          from normal display wm)
        - remove private refcounts now that the fb cleanups handles things
      v5: add linear surface support
      v6: remove color key clearing & setting from update_plane
      
      For this version, I tested DPMS since it came up in the last review;
      DPMS off/on works ok when a video player is working under X, but for
      power saving we'll probably want to do something smarter.  I'll leave
      that for a separate patch on top.  Likewise with the refcounting/fb
      layer handling, which are really separate cleanups.
      Reviewed-by: NDaniel Vetter <daniel.vetter@ffwll.ch>
      Signed-off-by: NJesse Barnes <jbarnes@virtuousgeek.org>
      Signed-off-by: NKeith Packard <keithp@keithp.com>
      b840d907
  25. 26 11月, 2010 1 次提交
  26. 24 11月, 2010 1 次提交
  27. 08 10月, 2010 1 次提交
  28. 08 9月, 2010 2 次提交
  29. 10 8月, 2010 2 次提交
  30. 27 5月, 2010 1 次提交
    • E
      drm/i915: Move ringbuffer-related code to intel_ringbuffer.c. · 62fdfeaf
      Eric Anholt 提交于
      This is preparation for supporting multiple ringbuffers on Ironlake.
      The non-copy-and-paste changes are:
      - de-staticing functions
      - I915_GEM_GPU_DOMAINS moving to i915_drv.h to be used by both files.
      - i915_gem_add_request had only half its implementation
        copy-and-pasted out of the middle of it.
      62fdfeaf
  31. 11 5月, 2010 1 次提交
  32. 08 12月, 2009 1 次提交
  33. 06 11月, 2009 1 次提交
    • D
      drm/i915: implement drmmode overlay support v4 · 02e792fb
      Daniel Vetter 提交于
      This implements intel overlay support for kms via a device-specific
      ioctl. Thomas Hellstrom brought up the idea of a general ioctl (on
      dri-devel). We've reached the conclusion that such an infrastructure
      only makes sense when multiple kms overlay implementations exists,
      which atm don't (and it doesn't look like this is gonna change).
      
      Open issues:
      - Runs in sync with the gpu, i.e. unnecessary waiting. I've decided
        to wait on this because the hw tends to hang when changing something
        in this area. I left some dummy functions as infrastructure.
      - polyphase filtering uses a static table.
      - uses uninterruptible sleeps. Unfortunately the alternatives may
        unnecessarily wedged the hw if/when we timeout too early (and
        userspace only overloaded the batch buffers with stuff worth a few
        secs of gpu time).
      
      Changes since v1:
      - fix off-by-one misconception on my side. This fixes fullscreen
        playback.
      Changes since v2:
      - add underrun detection as spec'ed for i965.
      - flush caches properly, fixing visual corruptions.
      Changes since v4:
      - fix up cache flushing of overlay memory regs.
      - killed require_pipe_a logic - it hangs the chip.
      
      Tested-By: diego.abelenda@gmail.com (on a 865G)
      Signed-off-by: NDaniel Vetter <daniel.vetter@ffwll.ch>
      [anholt: Resolved against the MADVISE ioctl going in before this one]
      Signed-off-by: NEric Anholt <eric@anholt.net>
      02e792fb
  34. 23 9月, 2009 1 次提交
    • C
      drm/i915: Add tracepoints · 1c5d22f7
      Chris Wilson 提交于
      By adding tracepoint equivalents for WATCH_BUF/EXEC we are able to monitor
      the lifetimes of objects, requests and significant events. These events can
      then be probed using the tracing frameworks, such as systemtap and, in
      particular, perf.
      
      For example to record the stack trace for every GPU stall during a run, use
      
        $ perf record -e i915:i915_gem_request_wait_begin -c 1 -g
      
      And
      
        $ perf report
      
      to view the results.
      
      [Updated to fix compilation issues caused.]
      Cc: Arjan van de Ven <arjan@linux.intel.com>
      Cc: Ben Gamari <bgamari@gmail.com>
      Signed-off-by: NChris Wilson <chris@chris-wilson.co.uk>
      1c5d22f7