[igt-dev] [PATCH igt 2/3] lib: Add Icelake platform definition

Paulo Zanoni paulo.r.zanoni at intel.com
Fri Apr 27 20:01:22 UTC 2018


From: Arkadiusz Hiler <arkadiusz.hiler at intel.com>

v2 (made by Paulo): PCI IDs are now part of a previous patch, so we
can move the ICL_ICL_11_IDs macro to this patch and avoid the
compilation warining on unused intel_icelake_info.

Signed-off-by: Arkadiusz Hiler <arkadiusz.hiler at intel.com>
Signed-off-by: Paulo Zanoni <paulo.r.zanoni at intel.com>
---
 lib/intel_chipset.h     | 3 +++
 lib/intel_device_info.c | 8 ++++++++
 2 files changed, 11 insertions(+)

diff --git a/lib/intel_chipset.h b/lib/intel_chipset.h
index 9250f4f9..40170b7b 100644
--- a/lib/intel_chipset.h
+++ b/lib/intel_chipset.h
@@ -67,6 +67,7 @@ struct intel_device_info {
 	bool is_geminilake : 1;
 	bool is_coffeelake : 1;
 	bool is_cannonlake : 1;
+	bool is_icelake : 1;
 	const char *codename;
 };
 
@@ -163,6 +164,7 @@ void intel_check_pch(void);
 #define IS_GEMINILAKE(devid)	(intel_get_device_info(devid)->is_geminilake)
 #define IS_COFFEELAKE(devid)	(intel_get_device_info(devid)->is_coffeelake)
 #define IS_CANNONLAKE(devid)	(intel_get_device_info(devid)->is_cannonlake)
+#define IS_ICELAKE(devid)	(intel_get_device_info(devid)->is_icelake)
 
 #define IS_GEN(devid, x)	(intel_get_device_info(devid)->gen & (1u << ((x)-1)))
 #define AT_LEAST_GEN(devid, x)	(intel_get_device_info(devid)->gen & -(1u << ((x)-1)))
@@ -176,6 +178,7 @@ void intel_check_pch(void);
 #define IS_GEN8(devid)		IS_GEN(devid, 8)
 #define IS_GEN9(devid)		IS_GEN(devid, 9)
 #define IS_GEN10(devid)		IS_GEN(devid, 10)
+#define IS_GEN11(devid)		IS_GEN(devid, 11)
 
 #define IS_MOBILE(devid)	(intel_get_device_info(devid)->is_mobile)
 #define IS_965(devid)		AT_LEAST_GEN(devid, 4)
diff --git a/lib/intel_device_info.c b/lib/intel_device_info.c
index 1c710733..cc417ed5 100644
--- a/lib/intel_device_info.c
+++ b/lib/intel_device_info.c
@@ -283,6 +283,12 @@ static const struct intel_device_info intel_cannonlake_info = {
 	.codename = "cannonlake"
 };
 
+static const struct intel_device_info intel_icelake_info = {
+	.gen = BIT(10),
+	.is_icelake = true,
+	.codename = "icelake"
+};
+
 static const struct pci_id_match intel_device_match[] = {
 	INTEL_I810_IDS(&intel_i810_info),
 	INTEL_I815_IDS(&intel_i815_info),
@@ -351,6 +357,8 @@ static const struct pci_id_match intel_device_match[] = {
 
 	INTEL_CNL_IDS(&intel_cannonlake_info),
 
+	INTEL_ICL_11_IDS(&intel_icelake_info),
+
 	INTEL_VGA_DEVICE(PCI_MATCH_ANY, &intel_generic_info),
 };
 
-- 
2.14.3



More information about the igt-dev mailing list