drm/xe/pf: Use an explicit check to see if the device has LMTT
authorPiotr Piórkowski <piotr.piorkowski@intel.com>
Fri, 7 Feb 2025 11:31:11 +0000 (12:31 +0100)
committerMichal Wajdeczko <michal.wajdeczko@intel.com>
Mon, 10 Feb 2025 10:10:14 +0000 (11:10 +0100)
commitcbc0a0ee34b5f108b184a6d59afd0f305564350a
tree9c436760030dd97ddb7f2c185dfa7ad39598eb11
parent6bb05b3631bd81227298b291b651dc7ec6ee0145
drm/xe/pf: Use an explicit check to see if the device has LMTT

So far, the main condition for using LMTT has been to check that
the device is a discrete gfx.
Let's add a dedicated function to check if the device supports LMTT
as not all future discrete GPU platforms will require LMTT.

v2:
 - use xe_has_device_lmtt only when necessary - leave IS_DGFX for other
   things related to LMEM provisioning
v3:
 - remove IS_SRIOV_PF condition from xe_device_has_lmtt (Michal
   Wajdeczko)
 - keep IS_SRIOV_PF asserts in LMTT-related code (Michal Wajdeczko)
v4:
 - update commit description

Signed-off-by: Piotr Piórkowski <piotr.piorkowski@intel.com>
Cc: Michal Wajdeczko <michal.wajdeczko@intel.com>
Cc: Michał Winiarski <michal.winiarski@intel.com>
Cc: Satyanarayana K V P <satyanarayana.k.v.p@intel.com>
Reviewed-by: Tejas Upadhyay <tejas.upadhyay@intel.com>
Reviewed-by: Satyanarayana K V P <satyanarayana.k.v.p@intel.com>
Signed-off-by: Michal Wajdeczko <michal.wajdeczko@intel.com>
Link: https://patchwork.freedesktop.org/patch/msgid/20250207113111.853821-2-piotr.piorkowski@intel.com
drivers/gpu/drm/xe/xe_device.h
drivers/gpu/drm/xe/xe_gt_sriov_pf_config.c
drivers/gpu/drm/xe/xe_lmtt.c