1. 01 10月, 2013 5 次提交
    • C
      drm/i915: Do not unlock upon error in i915_gem_idle() · f7403347
      Chris Wilson 提交于
      We never took the lock ourselves and all callers expect the struct_mutex
      to be locked upon return (be it success or error), thereore dropping the
      lock along the error paths looks to be a vestigial error from
      
      commit db1b76ca
      Author: Daniel Vetter <daniel.vetter@ffwll.ch>
      Date:   Tue Jul 9 16:51:37 2013 +0200
      
          drm/i915: don't frob mm.suspended when not using ums
      Signed-off-by: NChris Wilson <chris@chris-wilson.co.uk>
      Cc: Daniel Vetter <daniel.vetter@ffwll.ch>
      Signed-off-by: NDaniel Vetter <daniel.vetter@ffwll.ch>
      f7403347
    • D
      drm/i915: Use unsigned for overflow checks in execbuf · b205ca57
      Daniel Vetter 提交于
      There's actually no real risk since we already check for stricter
      constraints earlier (using UINT_MAX / sizeof (struct
      drm_i915_gem_exec_object2) as the limit). But in eb_create we use
      signed integers, which steals a factor of 2. Luckily struct
      drm_i915_gem_exec_object2 for this to not matter.
      
      Still, be consistent and use unsigned integers.
      
      Similar use unsinged integers when checking for overflows in the
      relocation entry processing.
      
      I've also added a new subtests to igt/gem_reloc_overflow to also
      test for overflowing args->buffer_count values.
      
      v2: Give the variables again tighter scope to make it clear that the
      computation is purely local and doesn't leak out to the 2nd block.
      Requested by Chris Wilson.
      
      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>
      b205ca57
    • D
      drm/i915: Ditch INTELFB_CONN_LIMIT · 955382f3
      Daniel Vetter 提交于
      And the gratious overallocation of crtcs. Seems to go back to the ums
      days of yonder ...
      
      We also still need it to make the fbdev emulation happy, but I don't
      think there's really a need. Especially since the current fbdev
      emulation doesn't actually support cloning.
      
      v2: Use sizeof(*pointer) pattern (Jani).
      
      Cc: Jani Nikula <jani.nikula@linux.intel.com>
      Reviewed-by: NJani Nikula <jani.nikula@intel.com>
      Signed-off-by: NDaniel Vetter <daniel.vetter@ffwll.ch>
      955382f3
    • D
      drm/i915: Use kcalloc more · a1e22653
      Daniel Vetter 提交于
      No buffer overflows here, but better safe than sorry.
      
      v2:
      - Fixup the sizeof conversion, I've missed the pointer deref (Jani).
      - Drop the redundant GFP_ZERO, kcalloc alreads memsets (Jani).
      - Use kmalloc_array for the execbuf fastpath to avoid the memset
        (Chris). I've opted to leave all other conversions as-is since they
        aren't in a fastpath and dealing with cleared memory instead of
        random garbage is just generally nicer.
      
      Cc: Jani Nikula <jani.nikula@linux.intel.com>
      Cc: Chris Wilson <chris@chris-wilson.co.uk>
      Reviewed-by: NJani Nikula <jani.nikula@intel.com>
      [danvet: Drop the contentious kmalloc_array hunk in execbuf.]
      Signed-off-by: NDaniel Vetter <daniel.vetter@ffwll.ch>
      a1e22653
    • D
      drm/i915: use pointer = k[cmz...]alloc(sizeof(*pointer), ...) pattern · b14c5679
      Daniel Vetter 提交于
      Done while reviewing all our allocations for fubar. Also a few errant
      cases of lacking () for the sizeof operator - just a bit of OCD.
      
      I've left out all the conversions that also should use kcalloc from
      this patch  (it's only 2).
      Reviewed-by: NJani Nikula <jani.nikula@intel.com>
      Signed-off-by: NDaniel Vetter <daniel.vetter@ffwll.ch>
      b14c5679
  2. 28 9月, 2013 4 次提交
  3. 26 9月, 2013 2 次提交
  4. 25 9月, 2013 4 次提交
  5. 24 9月, 2013 3 次提交
  6. 23 9月, 2013 9 次提交
  7. 21 9月, 2013 12 次提交
  8. 20 9月, 2013 1 次提交