intel_chipset.h revision 08d7334d
122944501Smrg/* 222944501Smrg * 322944501Smrg * Copyright 2003 Tungsten Graphics, Inc., Cedar Park, Texas. 422944501Smrg * All Rights Reserved. 522944501Smrg * 622944501Smrg * Permission is hereby granted, free of charge, to any person obtaining a 722944501Smrg * copy of this software and associated documentation files (the 822944501Smrg * "Software"), to deal in the Software without restriction, including 922944501Smrg * without limitation the rights to use, copy, modify, merge, publish, 1022944501Smrg * distribute, sub license, and/or sell copies of the Software, and to 1122944501Smrg * permit persons to whom the Software is furnished to do so, subject to 1222944501Smrg * the following conditions: 1322944501Smrg * 1422944501Smrg * The above copyright notice and this permission notice (including the 1522944501Smrg * next paragraph) shall be included in all copies or substantial portions 1622944501Smrg * of the Software. 1722944501Smrg * 1822944501Smrg * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS 1922944501Smrg * OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF 2022944501Smrg * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT. 2122944501Smrg * IN NO EVENT SHALL TUNGSTEN GRAPHICS AND/OR ITS SUPPLIERS BE LIABLE FOR 2222944501Smrg * ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, 2322944501Smrg * TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE 2422944501Smrg * SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. 2522944501Smrg * 2622944501Smrg */ 2722944501Smrg 2822944501Smrg#ifndef _INTEL_CHIPSET_H 2922944501Smrg#define _INTEL_CHIPSET_H 3022944501Smrg 31e88f27b3Smrg#define PCI_CHIP_I810 0x7121 32e88f27b3Smrg#define PCI_CHIP_I810_DC100 0x7123 33e88f27b3Smrg#define PCI_CHIP_I810_E 0x7125 34e88f27b3Smrg#define PCI_CHIP_I815 0x1132 35e88f27b3Smrg 36e88f27b3Smrg#define PCI_CHIP_I830_M 0x3577 37e88f27b3Smrg#define PCI_CHIP_845_G 0x2562 38e88f27b3Smrg#define PCI_CHIP_I855_GM 0x3582 39e88f27b3Smrg#define PCI_CHIP_I865_G 0x2572 40e88f27b3Smrg 41e88f27b3Smrg#define PCI_CHIP_I915_G 0x2582 42e88f27b3Smrg#define PCI_CHIP_E7221_G 0x258A 43e88f27b3Smrg#define PCI_CHIP_I915_GM 0x2592 44e88f27b3Smrg#define PCI_CHIP_I945_G 0x2772 45e88f27b3Smrg#define PCI_CHIP_I945_GM 0x27A2 46e88f27b3Smrg#define PCI_CHIP_I945_GME 0x27AE 47e88f27b3Smrg 48e88f27b3Smrg#define PCI_CHIP_Q35_G 0x29B2 49e88f27b3Smrg#define PCI_CHIP_G33_G 0x29C2 50e88f27b3Smrg#define PCI_CHIP_Q33_G 0x29D2 51e88f27b3Smrg 52e88f27b3Smrg#define PCI_CHIP_IGD_GM 0xA011 53e88f27b3Smrg#define PCI_CHIP_IGD_G 0xA001 54e88f27b3Smrg 55e88f27b3Smrg#define IS_IGDGM(devid) ((devid) == PCI_CHIP_IGD_GM) 56e88f27b3Smrg#define IS_IGDG(devid) ((devid) == PCI_CHIP_IGD_G) 57e88f27b3Smrg#define IS_IGD(devid) (IS_IGDG(devid) || IS_IGDGM(devid)) 58e88f27b3Smrg 59e88f27b3Smrg#define PCI_CHIP_I965_G 0x29A2 60e88f27b3Smrg#define PCI_CHIP_I965_Q 0x2992 61e88f27b3Smrg#define PCI_CHIP_I965_G_1 0x2982 62e88f27b3Smrg#define PCI_CHIP_I946_GZ 0x2972 63e88f27b3Smrg#define PCI_CHIP_I965_GM 0x2A02 64e88f27b3Smrg#define PCI_CHIP_I965_GME 0x2A12 65e88f27b3Smrg 66e88f27b3Smrg#define PCI_CHIP_GM45_GM 0x2A42 67e88f27b3Smrg 68e88f27b3Smrg#define PCI_CHIP_IGD_E_G 0x2E02 69e88f27b3Smrg#define PCI_CHIP_Q45_G 0x2E12 70e88f27b3Smrg#define PCI_CHIP_G45_G 0x2E22 71e88f27b3Smrg#define PCI_CHIP_G41_G 0x2E32 72e88f27b3Smrg 73e88f27b3Smrg#define PCI_CHIP_ILD_G 0x0042 74e88f27b3Smrg#define PCI_CHIP_ILM_G 0x0046 75e88f27b3Smrg 76e88f27b3Smrg#define PCI_CHIP_SANDYBRIDGE_GT1 0x0102 /* desktop */ 77e88f27b3Smrg#define PCI_CHIP_SANDYBRIDGE_GT2 0x0112 78e88f27b3Smrg#define PCI_CHIP_SANDYBRIDGE_GT2_PLUS 0x0122 79e88f27b3Smrg#define PCI_CHIP_SANDYBRIDGE_M_GT1 0x0106 /* mobile */ 80e88f27b3Smrg#define PCI_CHIP_SANDYBRIDGE_M_GT2 0x0116 81e88f27b3Smrg#define PCI_CHIP_SANDYBRIDGE_M_GT2_PLUS 0x0126 82e88f27b3Smrg#define PCI_CHIP_SANDYBRIDGE_S 0x010A /* server */ 83e88f27b3Smrg 84e88f27b3Smrg#define PCI_CHIP_IVYBRIDGE_GT1 0x0152 /* desktop */ 85e88f27b3Smrg#define PCI_CHIP_IVYBRIDGE_GT2 0x0162 86e88f27b3Smrg#define PCI_CHIP_IVYBRIDGE_M_GT1 0x0156 /* mobile */ 87e88f27b3Smrg#define PCI_CHIP_IVYBRIDGE_M_GT2 0x0166 88e88f27b3Smrg#define PCI_CHIP_IVYBRIDGE_S 0x015a /* server */ 89e88f27b3Smrg#define PCI_CHIP_IVYBRIDGE_S_GT2 0x016a /* server */ 90e88f27b3Smrg 91e88f27b3Smrg#define PCI_CHIP_HASWELL_GT1 0x0402 /* Desktop */ 92e88f27b3Smrg#define PCI_CHIP_HASWELL_GT2 0x0412 93e88f27b3Smrg#define PCI_CHIP_HASWELL_GT3 0x0422 94e88f27b3Smrg#define PCI_CHIP_HASWELL_M_GT1 0x0406 /* Mobile */ 95e88f27b3Smrg#define PCI_CHIP_HASWELL_M_GT2 0x0416 96e88f27b3Smrg#define PCI_CHIP_HASWELL_M_GT3 0x0426 97e88f27b3Smrg#define PCI_CHIP_HASWELL_S_GT1 0x040A /* Server */ 98e88f27b3Smrg#define PCI_CHIP_HASWELL_S_GT2 0x041A 99e88f27b3Smrg#define PCI_CHIP_HASWELL_S_GT3 0x042A 100e88f27b3Smrg#define PCI_CHIP_HASWELL_B_GT1 0x040B /* Reserved */ 101e88f27b3Smrg#define PCI_CHIP_HASWELL_B_GT2 0x041B 102e88f27b3Smrg#define PCI_CHIP_HASWELL_B_GT3 0x042B 103e88f27b3Smrg#define PCI_CHIP_HASWELL_E_GT1 0x040E /* Reserved */ 104e88f27b3Smrg#define PCI_CHIP_HASWELL_E_GT2 0x041E 105e88f27b3Smrg#define PCI_CHIP_HASWELL_E_GT3 0x042E 106e88f27b3Smrg#define PCI_CHIP_HASWELL_SDV_GT1 0x0C02 /* Desktop */ 107e88f27b3Smrg#define PCI_CHIP_HASWELL_SDV_GT2 0x0C12 108e88f27b3Smrg#define PCI_CHIP_HASWELL_SDV_GT3 0x0C22 109e88f27b3Smrg#define PCI_CHIP_HASWELL_SDV_M_GT1 0x0C06 /* Mobile */ 110e88f27b3Smrg#define PCI_CHIP_HASWELL_SDV_M_GT2 0x0C16 111e88f27b3Smrg#define PCI_CHIP_HASWELL_SDV_M_GT3 0x0C26 112e88f27b3Smrg#define PCI_CHIP_HASWELL_SDV_S_GT1 0x0C0A /* Server */ 113e88f27b3Smrg#define PCI_CHIP_HASWELL_SDV_S_GT2 0x0C1A 114e88f27b3Smrg#define PCI_CHIP_HASWELL_SDV_S_GT3 0x0C2A 115e88f27b3Smrg#define PCI_CHIP_HASWELL_SDV_B_GT1 0x0C0B /* Reserved */ 116e88f27b3Smrg#define PCI_CHIP_HASWELL_SDV_B_GT2 0x0C1B 117e88f27b3Smrg#define PCI_CHIP_HASWELL_SDV_B_GT3 0x0C2B 118e88f27b3Smrg#define PCI_CHIP_HASWELL_SDV_E_GT1 0x0C0E /* Reserved */ 119e88f27b3Smrg#define PCI_CHIP_HASWELL_SDV_E_GT2 0x0C1E 120e88f27b3Smrg#define PCI_CHIP_HASWELL_SDV_E_GT3 0x0C2E 121e88f27b3Smrg#define PCI_CHIP_HASWELL_ULT_GT1 0x0A02 /* Desktop */ 122e88f27b3Smrg#define PCI_CHIP_HASWELL_ULT_GT2 0x0A12 123e88f27b3Smrg#define PCI_CHIP_HASWELL_ULT_GT3 0x0A22 124e88f27b3Smrg#define PCI_CHIP_HASWELL_ULT_M_GT1 0x0A06 /* Mobile */ 125e88f27b3Smrg#define PCI_CHIP_HASWELL_ULT_M_GT2 0x0A16 126e88f27b3Smrg#define PCI_CHIP_HASWELL_ULT_M_GT3 0x0A26 127e88f27b3Smrg#define PCI_CHIP_HASWELL_ULT_S_GT1 0x0A0A /* Server */ 128e88f27b3Smrg#define PCI_CHIP_HASWELL_ULT_S_GT2 0x0A1A 129e88f27b3Smrg#define PCI_CHIP_HASWELL_ULT_S_GT3 0x0A2A 130e88f27b3Smrg#define PCI_CHIP_HASWELL_ULT_B_GT1 0x0A0B /* Reserved */ 131e88f27b3Smrg#define PCI_CHIP_HASWELL_ULT_B_GT2 0x0A1B 132e88f27b3Smrg#define PCI_CHIP_HASWELL_ULT_B_GT3 0x0A2B 133e88f27b3Smrg#define PCI_CHIP_HASWELL_ULT_E_GT1 0x0A0E /* Reserved */ 134e88f27b3Smrg#define PCI_CHIP_HASWELL_ULT_E_GT2 0x0A1E 135e88f27b3Smrg#define PCI_CHIP_HASWELL_ULT_E_GT3 0x0A2E 136e88f27b3Smrg#define PCI_CHIP_HASWELL_CRW_GT1 0x0D02 /* Desktop */ 137e88f27b3Smrg#define PCI_CHIP_HASWELL_CRW_GT2 0x0D12 138e88f27b3Smrg#define PCI_CHIP_HASWELL_CRW_GT3 0x0D22 139e88f27b3Smrg#define PCI_CHIP_HASWELL_CRW_M_GT1 0x0D06 /* Mobile */ 140e88f27b3Smrg#define PCI_CHIP_HASWELL_CRW_M_GT2 0x0D16 141e88f27b3Smrg#define PCI_CHIP_HASWELL_CRW_M_GT3 0x0D26 142e88f27b3Smrg#define PCI_CHIP_HASWELL_CRW_S_GT1 0x0D0A /* Server */ 143e88f27b3Smrg#define PCI_CHIP_HASWELL_CRW_S_GT2 0x0D1A 144e88f27b3Smrg#define PCI_CHIP_HASWELL_CRW_S_GT3 0x0D2A 145e88f27b3Smrg#define PCI_CHIP_HASWELL_CRW_B_GT1 0x0D0B /* Reserved */ 146e88f27b3Smrg#define PCI_CHIP_HASWELL_CRW_B_GT2 0x0D1B 147e88f27b3Smrg#define PCI_CHIP_HASWELL_CRW_B_GT3 0x0D2B 148e88f27b3Smrg#define PCI_CHIP_HASWELL_CRW_E_GT1 0x0D0E /* Reserved */ 149e88f27b3Smrg#define PCI_CHIP_HASWELL_CRW_E_GT2 0x0D1E 150e88f27b3Smrg#define PCI_CHIP_HASWELL_CRW_E_GT3 0x0D2E 151e88f27b3Smrg#define BDW_SPARE 0x2 152e88f27b3Smrg#define BDW_ULT 0x6 153e88f27b3Smrg#define BDW_SERVER 0xa 154e88f27b3Smrg#define BDW_IRIS 0xb 155e88f27b3Smrg#define BDW_WORKSTATION 0xd 156e88f27b3Smrg#define BDW_ULX 0xe 157e88f27b3Smrg 158e88f27b3Smrg#define PCI_CHIP_VALLEYVIEW_PO 0x0f30 /* VLV PO board */ 159e88f27b3Smrg#define PCI_CHIP_VALLEYVIEW_1 0x0f31 160e88f27b3Smrg#define PCI_CHIP_VALLEYVIEW_2 0x0f32 161e88f27b3Smrg#define PCI_CHIP_VALLEYVIEW_3 0x0f33 162e88f27b3Smrg 163857b0bc6Smrg#define PCI_CHIP_CHERRYVIEW_0 0x22b0 164857b0bc6Smrg#define PCI_CHIP_CHERRYVIEW_1 0x22b1 165857b0bc6Smrg#define PCI_CHIP_CHERRYVIEW_2 0x22b2 166857b0bc6Smrg#define PCI_CHIP_CHERRYVIEW_3 0x22b3 167857b0bc6Smrg 16808d7334dSsnj#define PCI_CHIP_SKYLAKE_ULT_GT2 0x1916 16908d7334dSsnj#define PCI_CHIP_SKYLAKE_ULT_GT1 0x1906 17008d7334dSsnj#define PCI_CHIP_SKYLAKE_ULT_GT3 0x1926 17108d7334dSsnj#define PCI_CHIP_SKYLAKE_ULT_GT2F 0x1921 17208d7334dSsnj#define PCI_CHIP_SKYLAKE_ULX_GT1 0x190E 17308d7334dSsnj#define PCI_CHIP_SKYLAKE_ULX_GT2 0x191E 17408d7334dSsnj#define PCI_CHIP_SKYLAKE_DT_GT2 0x1912 17508d7334dSsnj#define PCI_CHIP_SKYLAKE_DT_GT1 0x1902 17608d7334dSsnj#define PCI_CHIP_SKYLAKE_HALO_GT2 0x191B 17708d7334dSsnj#define PCI_CHIP_SKYLAKE_HALO_GT3 0x192B 17808d7334dSsnj#define PCI_CHIP_SKYLAKE_HALO_GT1 0x190B 17908d7334dSsnj#define PCI_CHIP_SKYLAKE_SRV_GT2 0x191A 18008d7334dSsnj#define PCI_CHIP_SKYLAKE_SRV_GT3 0x192A 18108d7334dSsnj#define PCI_CHIP_SKYLAKE_SRV_GT1 0x190A 18208d7334dSsnj#define PCI_CHIP_SKYLAKE_WKS_GT2 0x191D 18308d7334dSsnj 184e88f27b3Smrg#define IS_MOBILE(devid) ((devid) == PCI_CHIP_I855_GM || \ 185e88f27b3Smrg (devid) == PCI_CHIP_I915_GM || \ 186e88f27b3Smrg (devid) == PCI_CHIP_I945_GM || \ 187e88f27b3Smrg (devid) == PCI_CHIP_I945_GME || \ 188e88f27b3Smrg (devid) == PCI_CHIP_I965_GM || \ 189e88f27b3Smrg (devid) == PCI_CHIP_I965_GME || \ 190e88f27b3Smrg (devid) == PCI_CHIP_GM45_GM || IS_IGD(devid) || \ 191e88f27b3Smrg (devid) == PCI_CHIP_IVYBRIDGE_M_GT1 || \ 192e88f27b3Smrg (devid) == PCI_CHIP_IVYBRIDGE_M_GT2) 193e88f27b3Smrg 194e88f27b3Smrg#define IS_G45(devid) ((devid) == PCI_CHIP_IGD_E_G || \ 195e88f27b3Smrg (devid) == PCI_CHIP_Q45_G || \ 196e88f27b3Smrg (devid) == PCI_CHIP_G45_G || \ 197e88f27b3Smrg (devid) == PCI_CHIP_G41_G) 198e88f27b3Smrg#define IS_GM45(devid) ((devid) == PCI_CHIP_GM45_GM) 199e88f27b3Smrg#define IS_G4X(devid) (IS_G45(devid) || IS_GM45(devid)) 200e88f27b3Smrg 201e88f27b3Smrg#define IS_ILD(devid) ((devid) == PCI_CHIP_ILD_G) 202e88f27b3Smrg#define IS_ILM(devid) ((devid) == PCI_CHIP_ILM_G) 203e88f27b3Smrg 204e88f27b3Smrg#define IS_915(devid) ((devid) == PCI_CHIP_I915_G || \ 205e88f27b3Smrg (devid) == PCI_CHIP_E7221_G || \ 206e88f27b3Smrg (devid) == PCI_CHIP_I915_GM) 207e88f27b3Smrg 208e88f27b3Smrg#define IS_945GM(devid) ((devid) == PCI_CHIP_I945_GM || \ 209e88f27b3Smrg (devid) == PCI_CHIP_I945_GME) 210e88f27b3Smrg 211e88f27b3Smrg#define IS_945(devid) ((devid) == PCI_CHIP_I945_G || \ 212e88f27b3Smrg (devid) == PCI_CHIP_I945_GM || \ 213e88f27b3Smrg (devid) == PCI_CHIP_I945_GME || \ 214e88f27b3Smrg IS_G33(devid)) 215e88f27b3Smrg 216e88f27b3Smrg#define IS_G33(devid) ((devid) == PCI_CHIP_G33_G || \ 217e88f27b3Smrg (devid) == PCI_CHIP_Q33_G || \ 218e88f27b3Smrg (devid) == PCI_CHIP_Q35_G || IS_IGD(devid)) 219e88f27b3Smrg 220e88f27b3Smrg#define IS_GEN2(devid) ((devid) == PCI_CHIP_I830_M || \ 221e88f27b3Smrg (devid) == PCI_CHIP_845_G || \ 222e88f27b3Smrg (devid) == PCI_CHIP_I855_GM || \ 223e88f27b3Smrg (devid) == PCI_CHIP_I865_G) 224e88f27b3Smrg 225e88f27b3Smrg#define IS_GEN3(devid) (IS_945(devid) || IS_915(devid)) 226e88f27b3Smrg 227e88f27b3Smrg#define IS_GEN4(devid) ((devid) == PCI_CHIP_I965_G || \ 228e88f27b3Smrg (devid) == PCI_CHIP_I965_Q || \ 229e88f27b3Smrg (devid) == PCI_CHIP_I965_G_1 || \ 230e88f27b3Smrg (devid) == PCI_CHIP_I965_GM || \ 231e88f27b3Smrg (devid) == PCI_CHIP_I965_GME || \ 232e88f27b3Smrg (devid) == PCI_CHIP_I946_GZ || \ 233e88f27b3Smrg IS_G4X(devid)) 234e88f27b3Smrg 235e88f27b3Smrg#define IS_GEN5(devid) (IS_ILD(devid) || IS_ILM(devid)) 236e88f27b3Smrg 237e88f27b3Smrg#define IS_GEN6(devid) ((devid) == PCI_CHIP_SANDYBRIDGE_GT1 || \ 238e88f27b3Smrg (devid) == PCI_CHIP_SANDYBRIDGE_GT2 || \ 239e88f27b3Smrg (devid) == PCI_CHIP_SANDYBRIDGE_GT2_PLUS || \ 240e88f27b3Smrg (devid) == PCI_CHIP_SANDYBRIDGE_M_GT1 || \ 241e88f27b3Smrg (devid) == PCI_CHIP_SANDYBRIDGE_M_GT2 || \ 242e88f27b3Smrg (devid) == PCI_CHIP_SANDYBRIDGE_M_GT2_PLUS || \ 243e88f27b3Smrg (devid) == PCI_CHIP_SANDYBRIDGE_S) 244e88f27b3Smrg 245e88f27b3Smrg#define IS_GEN7(devid) (IS_IVYBRIDGE(devid) || \ 246e88f27b3Smrg IS_HASWELL(devid) || \ 247e88f27b3Smrg IS_VALLEYVIEW(devid)) 248e88f27b3Smrg 249e88f27b3Smrg#define IS_IVYBRIDGE(devid) ((devid) == PCI_CHIP_IVYBRIDGE_GT1 || \ 250e88f27b3Smrg (devid) == PCI_CHIP_IVYBRIDGE_GT2 || \ 251e88f27b3Smrg (devid) == PCI_CHIP_IVYBRIDGE_M_GT1 || \ 252e88f27b3Smrg (devid) == PCI_CHIP_IVYBRIDGE_M_GT2 || \ 253e88f27b3Smrg (devid) == PCI_CHIP_IVYBRIDGE_S || \ 254e88f27b3Smrg (devid) == PCI_CHIP_IVYBRIDGE_S_GT2) 255e88f27b3Smrg 256e88f27b3Smrg#define IS_VALLEYVIEW(devid) ((devid) == PCI_CHIP_VALLEYVIEW_PO || \ 257e88f27b3Smrg (devid) == PCI_CHIP_VALLEYVIEW_1 || \ 258e88f27b3Smrg (devid) == PCI_CHIP_VALLEYVIEW_2 || \ 259e88f27b3Smrg (devid) == PCI_CHIP_VALLEYVIEW_3) 260e88f27b3Smrg 261e88f27b3Smrg#define IS_HSW_GT1(devid) ((devid) == PCI_CHIP_HASWELL_GT1 || \ 262e88f27b3Smrg (devid) == PCI_CHIP_HASWELL_M_GT1 || \ 263e88f27b3Smrg (devid) == PCI_CHIP_HASWELL_S_GT1 || \ 264e88f27b3Smrg (devid) == PCI_CHIP_HASWELL_B_GT1 || \ 265e88f27b3Smrg (devid) == PCI_CHIP_HASWELL_E_GT1 || \ 266e88f27b3Smrg (devid) == PCI_CHIP_HASWELL_SDV_GT1 || \ 267e88f27b3Smrg (devid) == PCI_CHIP_HASWELL_SDV_M_GT1 || \ 268e88f27b3Smrg (devid) == PCI_CHIP_HASWELL_SDV_S_GT1 || \ 269e88f27b3Smrg (devid) == PCI_CHIP_HASWELL_SDV_B_GT1 || \ 270e88f27b3Smrg (devid) == PCI_CHIP_HASWELL_SDV_E_GT1 || \ 271e88f27b3Smrg (devid) == PCI_CHIP_HASWELL_ULT_GT1 || \ 272e88f27b3Smrg (devid) == PCI_CHIP_HASWELL_ULT_M_GT1 || \ 273e88f27b3Smrg (devid) == PCI_CHIP_HASWELL_ULT_S_GT1 || \ 274e88f27b3Smrg (devid) == PCI_CHIP_HASWELL_ULT_B_GT1 || \ 275e88f27b3Smrg (devid) == PCI_CHIP_HASWELL_ULT_E_GT1 || \ 276e88f27b3Smrg (devid) == PCI_CHIP_HASWELL_CRW_GT1 || \ 277e88f27b3Smrg (devid) == PCI_CHIP_HASWELL_CRW_M_GT1 || \ 278e88f27b3Smrg (devid) == PCI_CHIP_HASWELL_CRW_S_GT1 || \ 279e88f27b3Smrg (devid) == PCI_CHIP_HASWELL_CRW_B_GT1 || \ 280e88f27b3Smrg (devid) == PCI_CHIP_HASWELL_CRW_E_GT1) 281e88f27b3Smrg#define IS_HSW_GT2(devid) ((devid) == PCI_CHIP_HASWELL_GT2 || \ 282e88f27b3Smrg (devid) == PCI_CHIP_HASWELL_M_GT2 || \ 283e88f27b3Smrg (devid) == PCI_CHIP_HASWELL_S_GT2 || \ 284e88f27b3Smrg (devid) == PCI_CHIP_HASWELL_B_GT2 || \ 285e88f27b3Smrg (devid) == PCI_CHIP_HASWELL_E_GT2 || \ 286e88f27b3Smrg (devid) == PCI_CHIP_HASWELL_SDV_GT2 || \ 287e88f27b3Smrg (devid) == PCI_CHIP_HASWELL_SDV_M_GT2 || \ 288e88f27b3Smrg (devid) == PCI_CHIP_HASWELL_SDV_S_GT2 || \ 289e88f27b3Smrg (devid) == PCI_CHIP_HASWELL_SDV_B_GT2 || \ 290e88f27b3Smrg (devid) == PCI_CHIP_HASWELL_SDV_E_GT2 || \ 291e88f27b3Smrg (devid) == PCI_CHIP_HASWELL_ULT_GT2 || \ 292e88f27b3Smrg (devid) == PCI_CHIP_HASWELL_ULT_M_GT2 || \ 293e88f27b3Smrg (devid) == PCI_CHIP_HASWELL_ULT_S_GT2 || \ 294e88f27b3Smrg (devid) == PCI_CHIP_HASWELL_ULT_B_GT2 || \ 295e88f27b3Smrg (devid) == PCI_CHIP_HASWELL_ULT_E_GT2 || \ 296e88f27b3Smrg (devid) == PCI_CHIP_HASWELL_CRW_GT2 || \ 297e88f27b3Smrg (devid) == PCI_CHIP_HASWELL_CRW_M_GT2 || \ 298e88f27b3Smrg (devid) == PCI_CHIP_HASWELL_CRW_S_GT2 || \ 299e88f27b3Smrg (devid) == PCI_CHIP_HASWELL_CRW_B_GT2 || \ 300e88f27b3Smrg (devid) == PCI_CHIP_HASWELL_CRW_E_GT2) 301e88f27b3Smrg#define IS_HSW_GT3(devid) ((devid) == PCI_CHIP_HASWELL_GT3 || \ 302e88f27b3Smrg (devid) == PCI_CHIP_HASWELL_M_GT3 || \ 303e88f27b3Smrg (devid) == PCI_CHIP_HASWELL_S_GT3 || \ 304e88f27b3Smrg (devid) == PCI_CHIP_HASWELL_B_GT3 || \ 305e88f27b3Smrg (devid) == PCI_CHIP_HASWELL_E_GT3 || \ 306e88f27b3Smrg (devid) == PCI_CHIP_HASWELL_SDV_GT3 || \ 307e88f27b3Smrg (devid) == PCI_CHIP_HASWELL_SDV_M_GT3 || \ 308e88f27b3Smrg (devid) == PCI_CHIP_HASWELL_SDV_S_GT3 || \ 309e88f27b3Smrg (devid) == PCI_CHIP_HASWELL_SDV_B_GT3 || \ 310e88f27b3Smrg (devid) == PCI_CHIP_HASWELL_SDV_E_GT3 || \ 311e88f27b3Smrg (devid) == PCI_CHIP_HASWELL_ULT_GT3 || \ 312e88f27b3Smrg (devid) == PCI_CHIP_HASWELL_ULT_M_GT3 || \ 313e88f27b3Smrg (devid) == PCI_CHIP_HASWELL_ULT_S_GT3 || \ 314e88f27b3Smrg (devid) == PCI_CHIP_HASWELL_ULT_B_GT3 || \ 315e88f27b3Smrg (devid) == PCI_CHIP_HASWELL_ULT_E_GT3 || \ 316e88f27b3Smrg (devid) == PCI_CHIP_HASWELL_CRW_GT3 || \ 317e88f27b3Smrg (devid) == PCI_CHIP_HASWELL_CRW_M_GT3 || \ 318e88f27b3Smrg (devid) == PCI_CHIP_HASWELL_CRW_S_GT3 || \ 319e88f27b3Smrg (devid) == PCI_CHIP_HASWELL_CRW_B_GT3 || \ 320e88f27b3Smrg (devid) == PCI_CHIP_HASWELL_CRW_E_GT3) 321e88f27b3Smrg 322e88f27b3Smrg#define IS_HASWELL(devid) (IS_HSW_GT1(devid) || \ 323e88f27b3Smrg IS_HSW_GT2(devid) || \ 324e88f27b3Smrg IS_HSW_GT3(devid)) 325e88f27b3Smrg 326e88f27b3Smrg#define IS_BROADWELL(devid) (((devid & 0xff00) != 0x1600) ? 0 : \ 327e88f27b3Smrg (((devid & 0x00f0) >> 4) > 3) ? 0 : \ 328e88f27b3Smrg ((devid & 0x000f) == BDW_SPARE) ? 1 : \ 329e88f27b3Smrg ((devid & 0x000f) == BDW_ULT) ? 1 : \ 330e88f27b3Smrg ((devid & 0x000f) == BDW_IRIS) ? 1 : \ 331e88f27b3Smrg ((devid & 0x000f) == BDW_SERVER) ? 1 : \ 332e88f27b3Smrg ((devid & 0x000f) == BDW_WORKSTATION) ? 1 : \ 333e88f27b3Smrg ((devid & 0x000f) == BDW_ULX) ? 1 : 0) 334e88f27b3Smrg 335857b0bc6Smrg#define IS_CHERRYVIEW(devid) ((devid) == PCI_CHIP_CHERRYVIEW_0 || \ 336857b0bc6Smrg (devid) == PCI_CHIP_CHERRYVIEW_1 || \ 337857b0bc6Smrg (devid) == PCI_CHIP_CHERRYVIEW_2 || \ 338857b0bc6Smrg (devid) == PCI_CHIP_CHERRYVIEW_3) 339e88f27b3Smrg 340857b0bc6Smrg#define IS_GEN8(devid) (IS_BROADWELL(devid) || \ 341857b0bc6Smrg IS_CHERRYVIEW(devid)) 342e88f27b3Smrg 34308d7334dSsnj#define IS_SKL_GT1(devid) ((devid) == PCI_CHIP_SKYLAKE_ULT_GT1 || \ 34408d7334dSsnj (devid) == PCI_CHIP_SKYLAKE_ULX_GT1 || \ 34508d7334dSsnj (devid) == PCI_CHIP_SKYLAKE_DT_GT1 || \ 34608d7334dSsnj (devid) == PCI_CHIP_SKYLAKE_HALO_GT1 || \ 34708d7334dSsnj (devid) == PCI_CHIP_SKYLAKE_SRV_GT1) 34808d7334dSsnj 34908d7334dSsnj#define IS_SKL_GT2(devid) ((devid) == PCI_CHIP_SKYLAKE_ULT_GT2 || \ 35008d7334dSsnj (devid) == PCI_CHIP_SKYLAKE_ULT_GT2F || \ 35108d7334dSsnj (devid) == PCI_CHIP_SKYLAKE_ULX_GT2 || \ 35208d7334dSsnj (devid) == PCI_CHIP_SKYLAKE_DT_GT2 || \ 35308d7334dSsnj (devid) == PCI_CHIP_SKYLAKE_HALO_GT2 || \ 35408d7334dSsnj (devid) == PCI_CHIP_SKYLAKE_SRV_GT2 || \ 35508d7334dSsnj (devid) == PCI_CHIP_SKYLAKE_WKS_GT2) 35608d7334dSsnj 35708d7334dSsnj#define IS_SKL_GT3(devid) ((devid) == PCI_CHIP_SKYLAKE_ULT_GT3 || \ 35808d7334dSsnj (devid) == PCI_CHIP_SKYLAKE_HALO_GT3 || \ 35908d7334dSsnj (devid) == PCI_CHIP_SKYLAKE_SRV_GT3) 36008d7334dSsnj 36108d7334dSsnj#define IS_SKYLAKE(devid) (IS_SKL_GT1(devid) || \ 36208d7334dSsnj IS_SKL_GT2(devid) || \ 36308d7334dSsnj IS_SKL_GT3(devid)) 36408d7334dSsnj 36508d7334dSsnj#define IS_GEN9(devid) IS_SKYLAKE(devid) 36608d7334dSsnj 367e88f27b3Smrg#define IS_9XX(dev) (IS_GEN3(dev) || \ 368e88f27b3Smrg IS_GEN4(dev) || \ 369e88f27b3Smrg IS_GEN5(dev) || \ 370e88f27b3Smrg IS_GEN6(dev) || \ 371e88f27b3Smrg IS_GEN7(dev) || \ 37208d7334dSsnj IS_GEN8(dev) || \ 37308d7334dSsnj IS_GEN9(dev)) 374e88f27b3Smrg 37522944501Smrg 37622944501Smrg#endif /* _INTEL_CHIPSET_H */ 377