Searched hist:f4044ca1967098b44bd2d569ddb99352b599551e (Results 1 – 1 of 1) sorted by relevance
/linux/drivers/gpu/drm/i915/gt/uc/ |
H A D | intel_guc_ads.c | diff f4044ca1967098b44bd2d569ddb99352b599551e Tue Feb 08 08:01:40 CET 2022 Lucas De Marchi <lucas.demarchi@intel.com> drm/i915/guc: Prepare for error propagation
Currently guc_mmio_reg_add() relies on having enough memory available in the array to add a new slot. It uses `GEM_BUG_ON(count >= regset->size);` to protect going above the threshold.
In order to allow guc_mmio_reg_add() to handle the memory allocation by itself, it must return an error in case of failures. Adjust return code so this error can be propagated to the callers of guc_mmio_reg_add() and guc_mmio_regset_init().
No intended change in behavior.
Cc: Matt Roper <matthew.d.roper@intel.com> Cc: John Harrison <John.C.Harrison@Intel.com> Cc: Matthew Brost <matthew.brost@intel.com> Cc: Daniele Ceraolo Spurio <daniele.ceraolospurio@intel.com> Signed-off-by: Lucas De Marchi <lucas.demarchi@intel.com> Reviewed-by: Daniele Ceraolo Spurio <daniele.ceraolospurio@intel.com> Link: https://patchwork.freedesktop.org/patch/msgid/20220208070141.2095177-2-lucas.demarchi@intel.com
|