• 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
i915_gpu_error.c 27.3 KB