From fd2a558bf8a8390fad3236d903b224dfa58a46df Mon Sep 17 00:00:00 2001 From: Jordan Justen Date: Thu, 9 Dec 2021 10:11:37 -0800 Subject: [PATCH] intel/l3: Make DG1 urb-size exception more generic Signed-off-by: Jordan Justen Reviewed-by: Caio Oliveira Part-of: --- src/intel/common/intel_l3_config.c | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) diff --git a/src/intel/common/intel_l3_config.c b/src/intel/common/intel_l3_config.c index c7c6b3086ca..9fcb326f93d 100644 --- a/src/intel/common/intel_l3_config.c +++ b/src/intel/common/intel_l3_config.c @@ -351,9 +351,14 @@ unsigned intel_get_l3_config_urb_size(const struct intel_device_info *devinfo, const struct intel_l3_config *cfg) { - /* We don't have to program the URB size in DG1, it's a fixed value. */ - if (devinfo->platform == INTEL_PLATFORM_DG1) + /* We don't have to program the URB size for some platforms. It's a fixed + * value. + */ + if (cfg == NULL) { + ASSERTED const struct intel_l3_list *const list = get_l3_list(devinfo); + assert(list->length == 0); return devinfo->urb.size; + } /* From the SKL "L3 Allocation and Programming" documentation: *