[PARPORT] Introduce a skeleton that will serve as base for implementing the parallel...
authorAmine Khaldi <amine.khaldi@reactos.org>
Sat, 2 May 2015 10:15:37 +0000 (10:15 +0000)
committerAmine Khaldi <amine.khaldi@reactos.org>
Sat, 2 May 2015 10:15:37 +0000 (10:15 +0000)
svn path=/trunk/; revision=67508

reactos/drivers/parallel/CMakeLists.txt
reactos/drivers/parallel/parport/CMakeLists.txt [new file with mode: 0644]
reactos/drivers/parallel/parport/parport.c [new file with mode: 0644]
reactos/drivers/parallel/parport/parport.h [new file with mode: 0644]
reactos/drivers/parallel/parport/parport.rc [new file with mode: 0644]
reactos/media/inf/ports.inf

diff --git a/reactos/drivers/parallel/parport/CMakeLists.txt b/reactos/drivers/parallel/parport/CMakeLists.txt
new file mode 100644 (file)
index 0000000..e675c31
--- /dev/null
@@ -0,0 +1,5 @@
+
+add_library(parport SHARED parport.c parport.rc)
+set_module_type(parport kernelmodedriver)
+add_importlibs(parport ntoskrnl hal)
+add_cd_file(TARGET parport DESTINATION reactos/system32/drivers FOR all)
diff --git a/reactos/drivers/parallel/parport/parport.c b/reactos/drivers/parallel/parport/parport.c
new file mode 100644 (file)
index 0000000..6223ae0
--- /dev/null
@@ -0,0 +1,30 @@
+/*
+ * COPYRIGHT:       See COPYING in the top level directory
+ * PROJECT:         Parallel Port Function Driver
+ * PURPOSE:         Parport driver loading/unloading
+ */
+
+#include "parport.h"
+
+static DRIVER_UNLOAD DriverUnload;
+DRIVER_INITIALIZE DriverEntry;
+
+static
+VOID
+NTAPI
+DriverUnload(IN PDRIVER_OBJECT DriverObject)
+{
+    DPRINT("Parport DriverUnload\n");
+}
+
+NTSTATUS
+NTAPI
+DriverEntry(IN PDRIVER_OBJECT DriverObject,
+            IN PUNICODE_STRING RegPath)
+{
+    DPRINT("Parport DriverEntry\n");
+
+    DriverObject->DriverUnload = DriverUnload;
+
+    return STATUS_SUCCESS;
+}
diff --git a/reactos/drivers/parallel/parport/parport.h b/reactos/drivers/parallel/parport/parport.h
new file mode 100644 (file)
index 0000000..54581ca
--- /dev/null
@@ -0,0 +1,16 @@
+/*
+ * COPYRIGHT:       See COPYING in the top level directory
+ * PROJECT:         Parallel Port Function Driver
+ * PURPOSE:         Parport driver header
+ */
+
+#ifndef _PARPORT_PCH_
+#define _PARPORT_PCH_
+
+#include <ntddk.h>
+#include <ntddser.h>
+
+//#define NDEBUG
+#include <debug.h>
+
+#endif /* _PARPORT_PCH_ */
diff --git a/reactos/drivers/parallel/parport/parport.rc b/reactos/drivers/parallel/parport/parport.rc
new file mode 100644 (file)
index 0000000..862bfae
--- /dev/null
@@ -0,0 +1,5 @@
+#define REACTOS_VERSION_DLL
+#define REACTOS_STR_FILE_DESCRIPTION  "Parallel Port Function Driver"
+#define REACTOS_STR_INTERNAL_NAME     "parport"
+#define REACTOS_STR_ORIGINAL_FILENAME "parport.sys"
+#include <reactos/version.rc>
index 7021f6c..4e68520 100644 (file)
@@ -34,18 +34,18 @@ HKR, , Installer32,    0, "msports.dll,PortsClassInstaller"
 ;---------------------------- LPT PORT DRIVER ---------------------------\r
 \r
 [LptPort_Inst.NT]\r
 ;---------------------------- LPT PORT DRIVER ---------------------------\r
 \r
 [LptPort_Inst.NT]\r
-;CopyFiles = LptPort_CopyFiles.NT\r
+CopyFiles = LptPort_CopyFiles.NT\r
 AddReg = LptPort_AddReg.NT\r
 \r
 [LptPort_CopyFiles.NT]\r
 parport.sys\r
 \r
 [LptPort_AddReg.NT]\r
 AddReg = LptPort_AddReg.NT\r
 \r
 [LptPort_CopyFiles.NT]\r
 parport.sys\r
 \r
 [LptPort_AddReg.NT]\r
-;HKR, , "EnumPropPages32", 0, "msports.dll,ParallelPortPropPageProvider"\r
+HKR, , "EnumPropPages32", 0, "msports.dll,ParallelPortPropPageProvider"\r
 HKR, , "PortSubClass", 1, 00\r
 \r
 [LptPort_Inst.NT.Services]\r
 HKR, , "PortSubClass", 1, 00\r
 \r
 [LptPort_Inst.NT.Services]\r
-;AddService = parport, 0x00000002, parport_Service_Inst\r
+AddService = parport, 0x00000002, parport_Service_Inst\r
 \r
 [parport_Service_Inst]\r
 ServiceType   = 1\r
 \r
 [parport_Service_Inst]\r
 ServiceType   = 1\r