• Jon Bloomfield's avatar
    drm/i915: Allow parsing of unsized batches · 435e8fc0
    Jon Bloomfield authored
    In "drm/i915: Add support for mandatory cmdparsing" we introduced the
    concept of mandatory parsing. This allows the cmdparser to be invoked
    even when user passes batch_len=0 to the execbuf ioctl's.
    
    However, the cmdparser needs to know the extents of the buffer being
    scanned. Refactor the code to ensure the cmdparser uses the actual
    object size, instead of the incoming length, if user passes 0.
    Signed-off-by: default avatarJon Bloomfield <jon.bloomfield@intel.com>
    Cc: Tony Luck <tony.luck@intel.com>
    Cc: Dave Airlie <airlied@redhat.com>
    Cc: Takashi Iwai <tiwai@suse.de>
    Cc: Tyler Hicks <tyhicks@canonical.com>
    Reviewed-by: default avatarChris Wilson <chris.p.wilson@intel.com>
    435e8fc0
i915_gem_execbuffer.c 76.1 KB