Add config interface start (PciReadWriteConfigSpace, PciReadSlotConfig)
[reactos.git] / reactos / drivers / bus / pcix / intrface / agpintrf.c
1 /*
2 * PROJECT: ReactOS PCI Bus Driver
3 * LICENSE: BSD - See COPYING.ARM in the top level directory
4 * FILE: drivers/bus/pci/intrface/agpintrf.c
5 * PURPOSE: AGP Interface
6 * PROGRAMMERS: ReactOS Portable Systems Group
7 */
8
9 /* INCLUDES *******************************************************************/
10
11 #include <pci.h>
12 #define NDEBUG
13 #include <debug.h>
14
15 /* GLOBALS ********************************************************************/
16
17 PCI_INTERFACE AgpTargetInterface =
18 {
19 &GUID_AGP_TARGET_BUS_INTERFACE_STANDARD,
20 sizeof(AGP_BUS_INTERFACE_STANDARD),
21 AGP_BUS_INTERFACE_V1,
22 AGP_BUS_INTERFACE_V1,
23 PCI_INTERFACE_PDO,
24 0,
25 PciInterface_AgpTarget,
26 agpintrf_Constructor,
27 agpintrf_Initializer
28 };
29
30 /* FUNCTIONS ******************************************************************/
31
32 NTSTATUS
33 NTAPI
34 agpintrf_Initializer(IN PVOID Instance)
35 {
36 /* PnP Interfaces don't get Initialized */
37 ASSERTMSG(FALSE, "PCI agpintrf_Initializer, unexpected call.");
38 return STATUS_UNSUCCESSFUL;
39 }
40
41 NTSTATUS
42 NTAPI
43 agpintrf_Constructor(IN PVOID DeviceExtension,
44 IN PVOID Instance,
45 IN PVOID InterfaceData,
46 IN USHORT Version,
47 IN USHORT Size,
48 IN PINTERFACE Interface)
49 {
50 PPCI_PDO_EXTENSION PdoExtension = (PPCI_PDO_EXTENSION)DeviceExtension;
51
52 /* Only AGP bridges are supported (which are PCI-to-PCI Bridge Devices) */
53 if ((PdoExtension->BaseClass != PCI_CLASS_BRIDGE_DEV) ||
54 (PdoExtension->SubClass != PCI_SUBCLASS_BR_PCI_TO_PCI))
55 {
56 /* Fail any other PDO */
57 return STATUS_NOT_SUPPORTED;
58 }
59
60 /* Not yet implemented */
61 UNIMPLEMENTED;
62 while (TRUE);
63 }
64
65 /* EOF */