Author: pschweitzer Date: Thu Sep 10 21:41:20 2015 New Revision: 69176
URL: http://svn.reactos.org/svn/reactos?rev=69176&view=rev Log: [MOUNTMGR] Move DriverEntry() and MountmgrReadNoAutoMount() to INIT_SECTION
Modified: trunk/reactos/drivers/filters/mountmgr/mntmgr.h trunk/reactos/drivers/filters/mountmgr/mountmgr.c
Modified: trunk/reactos/drivers/filters/mountmgr/mntmgr.h URL: http://svn.reactos.org/svn/reactos/trunk/reactos/drivers/filters/mountmgr/mn... ============================================================================== --- trunk/reactos/drivers/filters/mountmgr/mntmgr.h [iso-8859-1] (original) +++ trunk/reactos/drivers/filters/mountmgr/mntmgr.h [iso-8859-1] Thu Sep 10 21:41:20 2015 @@ -7,6 +7,12 @@ #include <wdmguid.h> #include <ndk/psfuncs.h> #include <ntdddisk.h> + +#ifdef __GNUC__ +#define INIT_SECTION __attribute__((section ("INIT"))) +#else +#define INIT_SECTION /* Done via alloc_text for MSC */ +#endif
/* Enter FIXME */ #ifdef IsEqualGUID
Modified: trunk/reactos/drivers/filters/mountmgr/mountmgr.c URL: http://svn.reactos.org/svn/reactos/trunk/reactos/drivers/filters/mountmgr/mo... ============================================================================== --- trunk/reactos/drivers/filters/mountmgr/mountmgr.c [iso-8859-1] (original) +++ trunk/reactos/drivers/filters/mountmgr/mountmgr.c [iso-8859-1] Thu Sep 10 21:41:20 2015 @@ -28,6 +28,11 @@
#define NDEBUG #include <debug.h> + +#if defined(ALLOC_PRAGMA) +#pragma alloc_text(INIT, MountmgrReadNoAutoMount) +#pragma alloc_text(INIT, DriverEntry) +#endif
/* FIXME */ GUID MountedDevicesGuid = {0x53F5630D, 0xB6BF, 0x11D0, {0x94, 0xF2, 0x00, 0xA0, 0xC9, 0x1E, 0xFB, 0x8B}}; @@ -912,6 +917,7 @@ /* * @implemented */ +INIT_SECTION BOOLEAN MountmgrReadNoAutoMount(IN PUNICODE_STRING RegistryPath) { @@ -1805,6 +1811,7 @@
/* FUNCTIONS ****************************************************************/
+INIT_SECTION NTSTATUS NTAPI DriverEntry(IN PDRIVER_OBJECT DriverObject,