diff mbox series

[v1,5/6] drm/i915/xe2lpd: Load DMC

Message ID 20240222125634.275047-6-vinod.govindapillai@intel.com (mailing list archive)
State New, archived
Headers show
Series LNL display | expand

Commit Message

Govindapillai, Vinod Feb. 22, 2024, 12:56 p.m. UTC
From: Balasubramani Vivekanandan <balasubramani.vivekanandan@intel.com>

Load DMC for XE2LPD. The value 0x8000 is the maximum payload size for
any xe2lpd dmc firmware.

Signed-off-by: Balasubramani Vivekanandan <balasubramani.vivekanandan@intel.com>
Signed-off-by: Dnyaneshwar Bhadane <dnyaneshwar.bhadane@intel.com>
---
 drivers/gpu/drm/i915/display/intel_dmc.c | 9 ++++++++-
 1 file changed, 8 insertions(+), 1 deletion(-)

Comments

Lucas De Marchi Feb. 22, 2024, 2:26 p.m. UTC | #1
On Thu, Feb 22, 2024 at 02:56:33PM +0200, Vinod Govindapillai wrote:
>From: Balasubramani Vivekanandan <balasubramani.vivekanandan@intel.com>
>
>Load DMC for XE2LPD. The value 0x8000 is the maximum payload size for
>any xe2lpd dmc firmware.
>
>Signed-off-by: Balasubramani Vivekanandan <balasubramani.vivekanandan@intel.com>
>Signed-off-by: Dnyaneshwar Bhadane <dnyaneshwar.bhadane@intel.com>
>---
> drivers/gpu/drm/i915/display/intel_dmc.c | 9 ++++++++-
> 1 file changed, 8 insertions(+), 1 deletion(-)
>
>diff --git a/drivers/gpu/drm/i915/display/intel_dmc.c b/drivers/gpu/drm/i915/display/intel_dmc.c
>index 835781624482..54c5909de293 100644
>--- a/drivers/gpu/drm/i915/display/intel_dmc.c
>+++ b/drivers/gpu/drm/i915/display/intel_dmc.c
>@@ -89,10 +89,14 @@ static struct intel_dmc *i915_to_dmc(struct drm_i915_private *i915)
> 	__stringify(major) "_"			\
> 	__stringify(minor) ".bin"
>
>+#define XE2LPD_MAX_FW_SIZE		0x8000
> #define XELPDP_DMC_MAX_FW_SIZE		0x7000
> #define DISPLAY_VER13_DMC_MAX_FW_SIZE	0x20000
> #define DISPLAY_VER12_DMC_MAX_FW_SIZE	ICL_DMC_MAX_FW_SIZE
>
>+#define XE2LPD_DMC_PATH			DMC_PATH(xe2lpd)
>+MODULE_FIRMWARE(XE2LPD_DMC_PATH);

looking at the mailing list I don't see any pull request to either
linux-firmware or drm-firmware with the DMC firmware. So if we had LNL
in CI, it would just fail. We need it at least in drm-firmware to be
able to test. We need it in linux-firmware to be able to merge.

Lucas De Marchi
Gustavo Sousa Feb. 22, 2024, 8:39 p.m. UTC | #2
Quoting Lucas De Marchi (2024-02-22 11:26:57-03:00)
>On Thu, Feb 22, 2024 at 02:56:33PM +0200, Vinod Govindapillai wrote:
>>From: Balasubramani Vivekanandan <balasubramani.vivekanandan@intel.com>
>>
>>Load DMC for XE2LPD. The value 0x8000 is the maximum payload size for
>>any xe2lpd dmc firmware.
>>
>>Signed-off-by: Balasubramani Vivekanandan <balasubramani.vivekanandan@intel.com>
>>Signed-off-by: Dnyaneshwar Bhadane <dnyaneshwar.bhadane@intel.com>
>>---
>> drivers/gpu/drm/i915/display/intel_dmc.c | 9 ++++++++-
>> 1 file changed, 8 insertions(+), 1 deletion(-)
>>
>>diff --git a/drivers/gpu/drm/i915/display/intel_dmc.c b/drivers/gpu/drm/i915/display/intel_dmc.c
>>index 835781624482..54c5909de293 100644
>>--- a/drivers/gpu/drm/i915/display/intel_dmc.c
>>+++ b/drivers/gpu/drm/i915/display/intel_dmc.c
>>@@ -89,10 +89,14 @@ static struct intel_dmc *i915_to_dmc(struct drm_i915_private *i915)
>>         __stringify(major) "_"                        \
>>         __stringify(minor) ".bin"
>>
>>+#define XE2LPD_MAX_FW_SIZE                0x8000
>> #define XELPDP_DMC_MAX_FW_SIZE                0x7000
>> #define DISPLAY_VER13_DMC_MAX_FW_SIZE        0x20000
>> #define DISPLAY_VER12_DMC_MAX_FW_SIZE        ICL_DMC_MAX_FW_SIZE
>>
>>+#define XE2LPD_DMC_PATH                        DMC_PATH(xe2lpd)
>>+MODULE_FIRMWARE(XE2LPD_DMC_PATH);
>
>looking at the mailing list I don't see any pull request to either
>linux-firmware or drm-firmware with the DMC firmware. So if we had LNL
>in CI, it would just fail. We need it at least in drm-firmware to be
>able to test. We need it in linux-firmware to be able to merge.

FIY: Xe2LPD DMC has been merged into linux-firmware:

    https://gitlab.com/kernel-firmware/linux-firmware/-/merge_requests/160

--
Gustavo Sousa
Rodrigo Vivi Feb. 22, 2024, 9:11 p.m. UTC | #3
On Thu, Feb 22, 2024 at 02:56:33PM +0200, Vinod Govindapillai wrote:
> From: Balasubramani Vivekanandan <balasubramani.vivekanandan@intel.com>
> 
> Load DMC for XE2LPD. The value 0x8000 is the maximum payload size for
> any xe2lpd dmc firmware.
> 
> Signed-off-by: Balasubramani Vivekanandan <balasubramani.vivekanandan@intel.com>
> Signed-off-by: Dnyaneshwar Bhadane <dnyaneshwar.bhadane@intel.com>

Please always sign-off whenever sending someone's else patch. Even when there
was no modification on the original patch. The sign-off is needed when handling
the patches.

> ---
>  drivers/gpu/drm/i915/display/intel_dmc.c | 9 ++++++++-
>  1 file changed, 8 insertions(+), 1 deletion(-)
> 
> diff --git a/drivers/gpu/drm/i915/display/intel_dmc.c b/drivers/gpu/drm/i915/display/intel_dmc.c
> index 835781624482..54c5909de293 100644
> --- a/drivers/gpu/drm/i915/display/intel_dmc.c
> +++ b/drivers/gpu/drm/i915/display/intel_dmc.c
> @@ -89,10 +89,14 @@ static struct intel_dmc *i915_to_dmc(struct drm_i915_private *i915)
>  	__stringify(major) "_"			\
>  	__stringify(minor) ".bin"
>  
> +#define XE2LPD_MAX_FW_SIZE		0x8000
>  #define XELPDP_DMC_MAX_FW_SIZE		0x7000
>  #define DISPLAY_VER13_DMC_MAX_FW_SIZE	0x20000
>  #define DISPLAY_VER12_DMC_MAX_FW_SIZE	ICL_DMC_MAX_FW_SIZE
>  
> +#define XE2LPD_DMC_PATH			DMC_PATH(xe2lpd)
> +MODULE_FIRMWARE(XE2LPD_DMC_PATH);
> +
>  #define MTL_DMC_PATH			DMC_PATH(mtl)
>  MODULE_FIRMWARE(MTL_DMC_PATH);
>  
> @@ -987,7 +991,10 @@ void intel_dmc_init(struct drm_i915_private *i915)
>  
>  	INIT_WORK(&dmc->work, dmc_load_work_fn);
>  
> -	if (DISPLAY_VER_FULL(i915) == IP_VER(14, 0)) {
> +	if (DISPLAY_VER_FULL(i915) == IP_VER(20, 0)) {
> +		dmc->fw_path = XE2LPD_DMC_PATH;
> +		dmc->max_fw_size = XE2LPD_MAX_FW_SIZE;
> +	} else if (DISPLAY_VER_FULL(i915) == IP_VER(14, 0)) {
>  		dmc->fw_path = MTL_DMC_PATH;
>  		dmc->max_fw_size = XELPDP_DMC_MAX_FW_SIZE;
>  	} else if (IS_DG2(i915)) {
> -- 
> 2.34.1
>
diff mbox series

Patch

diff --git a/drivers/gpu/drm/i915/display/intel_dmc.c b/drivers/gpu/drm/i915/display/intel_dmc.c
index 835781624482..54c5909de293 100644
--- a/drivers/gpu/drm/i915/display/intel_dmc.c
+++ b/drivers/gpu/drm/i915/display/intel_dmc.c
@@ -89,10 +89,14 @@  static struct intel_dmc *i915_to_dmc(struct drm_i915_private *i915)
 	__stringify(major) "_"			\
 	__stringify(minor) ".bin"
 
+#define XE2LPD_MAX_FW_SIZE		0x8000
 #define XELPDP_DMC_MAX_FW_SIZE		0x7000
 #define DISPLAY_VER13_DMC_MAX_FW_SIZE	0x20000
 #define DISPLAY_VER12_DMC_MAX_FW_SIZE	ICL_DMC_MAX_FW_SIZE
 
+#define XE2LPD_DMC_PATH			DMC_PATH(xe2lpd)
+MODULE_FIRMWARE(XE2LPD_DMC_PATH);
+
 #define MTL_DMC_PATH			DMC_PATH(mtl)
 MODULE_FIRMWARE(MTL_DMC_PATH);
 
@@ -987,7 +991,10 @@  void intel_dmc_init(struct drm_i915_private *i915)
 
 	INIT_WORK(&dmc->work, dmc_load_work_fn);
 
-	if (DISPLAY_VER_FULL(i915) == IP_VER(14, 0)) {
+	if (DISPLAY_VER_FULL(i915) == IP_VER(20, 0)) {
+		dmc->fw_path = XE2LPD_DMC_PATH;
+		dmc->max_fw_size = XE2LPD_MAX_FW_SIZE;
+	} else if (DISPLAY_VER_FULL(i915) == IP_VER(14, 0)) {
 		dmc->fw_path = MTL_DMC_PATH;
 		dmc->max_fw_size = XELPDP_DMC_MAX_FW_SIZE;
 	} else if (IS_DG2(i915)) {