Skip to content

Commit a4a027a

Browse files
rodrigovividanvet
authored andcommitted
drm/i915/kbl: Introduce the first official DMC for Kabylake.
Version 1.01. This firmware is made for Kabylake platform so it doesn't need the stepping workaround that we had before. v2: Rebased on top of latest nightly with min version required change. v3: With right CSR_VERSION (Patrik). Cc: Christophe Prigent <[email protected]> Cc: Patrik Jakobsson <[email protected]> Reviewed-by: Ben Widawsky <[email protected]> (v1) Signed-off-by: Rodrigo Vivi <[email protected]> Reviewed-by: Patrik Jakobsson <[email protected]> Link: http://patchwork.freedesktop.org/patch/msgid/[email protected] (cherry picked from commit 4922d49) Signed-off-by: Daniel Vetter <[email protected]>
1 parent bc7135b commit a4a027a

File tree

1 file changed

+19
-11
lines changed

1 file changed

+19
-11
lines changed

drivers/gpu/drm/i915/intel_csr.c

Lines changed: 19 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -41,16 +41,22 @@
4141
* be moved to FW_FAILED.
4242
*/
4343

44+
#define I915_CSR_KBL "i915/kbl_dmc_ver1.bin"
45+
MODULE_FIRMWARE(I915_CSR_KBL);
46+
#define KBL_CSR_VERSION_REQUIRED CSR_VERSION(1, 1)
47+
4448
#define I915_CSR_SKL "i915/skl_dmc_ver1.bin"
49+
MODULE_FIRMWARE(I915_CSR_SKL);
50+
#define SKL_CSR_VERSION_REQUIRED CSR_VERSION(1, 23)
51+
4552
#define I915_CSR_BXT "i915/bxt_dmc_ver1.bin"
53+
MODULE_FIRMWARE(I915_CSR_BXT);
54+
#define BXT_CSR_VERSION_REQUIRED CSR_VERSION(1, 7)
4655

4756
#define FIRMWARE_URL "https://01.org/linuxgraphics/intel-linux-graphics-firmwares"
4857

49-
MODULE_FIRMWARE(I915_CSR_SKL);
50-
MODULE_FIRMWARE(I915_CSR_BXT);
5158

52-
#define SKL_CSR_VERSION_REQUIRED CSR_VERSION(1, 23)
53-
#define BXT_CSR_VERSION_REQUIRED CSR_VERSION(1, 7)
59+
5460

5561
#define CSR_MAX_FW_SIZE 0x2FFF
5662
#define CSR_DEFAULT_FW_OFFSET 0xFFFFFFFF
@@ -169,12 +175,10 @@ struct stepping_info {
169175
char substepping;
170176
};
171177

172-
/*
173-
* Kabylake derivated from Skylake H0, so SKL H0
174-
* is the right firmware for KBL A0 (revid 0).
175-
*/
176178
static const struct stepping_info kbl_stepping_info[] = {
177-
{'H', '0'}, {'I', '0'}
179+
{'A', '0'}, {'B', '0'}, {'C', '0'},
180+
{'D', '0'}, {'E', '0'}, {'F', '0'},
181+
{'G', '0'}, {'H', '0'}, {'I', '0'},
178182
};
179183

180184
static const struct stepping_info skl_stepping_info[] = {
@@ -298,7 +302,9 @@ static uint32_t *parse_csr_fw(struct drm_i915_private *dev_priv,
298302

299303
csr->version = css_header->version;
300304

301-
if (IS_SKYLAKE(dev_priv) || IS_KABYLAKE(dev_priv)) {
305+
if (IS_KABYLAKE(dev_priv)) {
306+
required_min_version = KBL_CSR_VERSION_REQUIRED;
307+
} else if (IS_SKYLAKE(dev_priv)) {
302308
required_min_version = SKL_CSR_VERSION_REQUIRED;
303309
} else if (IS_BROXTON(dev_priv)) {
304310
required_min_version = BXT_CSR_VERSION_REQUIRED;
@@ -446,7 +452,9 @@ void intel_csr_ucode_init(struct drm_i915_private *dev_priv)
446452
if (!HAS_CSR(dev_priv))
447453
return;
448454

449-
if (IS_SKYLAKE(dev_priv) || IS_KABYLAKE(dev_priv))
455+
if (IS_KABYLAKE(dev_priv))
456+
csr->fw_path = I915_CSR_KBL;
457+
else if (IS_SKYLAKE(dev_priv))
450458
csr->fw_path = I915_CSR_SKL;
451459
else if (IS_BROXTON(dev_priv))
452460
csr->fw_path = I915_CSR_BXT;

0 commit comments

Comments
 (0)