OSDN Git Service

Merge branch 'pageflip' of git://people.freedesktop.org/~jbarnes/drm
[android-x86/external-libdrm.git] / intel / intel_chipset.h
1 /*
2  *
3  * Copyright 2003 Tungsten Graphics, Inc., Cedar Park, Texas.
4  * All Rights Reserved.
5  *
6  * Permission is hereby granted, free of charge, to any person obtaining a
7  * copy of this software and associated documentation files (the
8  * "Software"), to deal in the Software without restriction, including
9  * without limitation the rights to use, copy, modify, merge, publish,
10  * distribute, sub license, and/or sell copies of the Software, and to
11  * permit persons to whom the Software is furnished to do so, subject to
12  * the following conditions:
13  *
14  * The above copyright notice and this permission notice (including the
15  * next paragraph) shall be included in all copies or substantial portions
16  * of the Software.
17  *
18  * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS
19  * OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
20  * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT.
21  * IN NO EVENT SHALL TUNGSTEN GRAPHICS AND/OR ITS SUPPLIERS BE LIABLE FOR
22  * ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT,
23  * TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
24  * SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
25  *
26  */
27
28 #ifndef _INTEL_CHIPSET_H
29 #define _INTEL_CHIPSET_H
30
31 #define IS_I830(dev) ((dev)->pci_device == 0x3577)
32 #define IS_845G(dev) ((dev)->pci_device == 0x2562)
33 #define IS_I85X(dev) ((dev)->pci_device == 0x3582)
34 #define IS_I855(dev) ((dev)->pci_device == 0x3582)
35 #define IS_I865G(dev) ((dev)->pci_device == 0x2572)
36
37 #define IS_I915G(dev) ((dev)->pci_device == 0x2582 || (dev)->pci_device == 0x258a)
38 #define IS_I915GM(dev) ((dev)->pci_device == 0x2592)
39 #define IS_I945G(dev) ((dev)->pci_device == 0x2772)
40 #define IS_I945GM(dev) ((dev)->pci_device == 0x27A2 ||\
41                         (dev)->pci_device == 0x27AE)
42 #define IS_I965G(dev) ((dev)->pci_device == 0x2972 || \
43                        (dev)->pci_device == 0x2982 || \
44                        (dev)->pci_device == 0x2992 || \
45                        (dev)->pci_device == 0x29A2 || \
46                        (dev)->pci_device == 0x2A02 || \
47                        (dev)->pci_device == 0x2A12 || \
48                        (dev)->pci_device == 0x2A42 || \
49                        (dev)->pci_device == 0x2E02 || \
50                        (dev)->pci_device == 0x2E12 || \
51                        (dev)->pci_device == 0x2E22 || \
52                        (dev)->pci_device == 0x2E32 || \
53                        (dev)->pci_device == 0x2E42 || \
54                        (dev)->pci_device == 0x0042 || \
55                        (dev)->pci_device == 0x0046)
56
57 #define IS_I965GM(dev) ((dev)->pci_device == 0x2A02)
58
59 #define IS_GM45(dev) ((dev)->pci_device == 0x2A42)
60
61 #define IS_G4X(dev) ((dev)->pci_device == 0x2E02 || \
62                      (dev)->pci_device == 0x2E12 || \
63                      (dev)->pci_device == 0x2E22 || \
64                      (dev)->pci_device == 0x2E32 || \
65                      (dev)->pci_device == 0x2E42)
66
67 #define IS_G33(dev)    ((dev)->pci_device == 0x29C2 ||  \
68                         (dev)->pci_device == 0x29B2 ||  \
69                         (dev)->pci_device == 0x29D2)
70
71 #define IS_I9XX(dev) (IS_I915G(dev) || IS_I915GM(dev) || IS_I945G(dev) || \
72                       IS_I945GM(dev) || IS_I965G(dev) || IS_G33(dev))
73
74 #define IS_MOBILE(dev) (IS_I830(dev) || IS_I85X(dev) || IS_I915GM(dev) || \
75                         IS_I945GM(dev) || IS_I965GM(dev) || IS_GM45(dev))
76
77 #endif /* _INTEL_CHIPSET_H */