mirror of
https://github.com/reactos/reactos.git
synced 2025-01-03 21:09:19 +00:00
[VGA_NEW]
* Explicitly mark the functions as stdcall. svn path=/trunk/; revision=56977
This commit is contained in:
parent
6a16d0d04b
commit
01b9338bc1
3 changed files with 44 additions and 20 deletions
|
@ -13,12 +13,9 @@ add_library(vga SHARED
|
|||
target_link_libraries(vga libcntpr)
|
||||
|
||||
# FIXME: http://www.cmake.org/Bug/view.php?id=12998
|
||||
if(MSVC)
|
||||
#add_target_compile_flags(vga "/Gz")
|
||||
set_source_files_properties(${SOURCE} PROPERTIES COMPILE_FLAGS "/Gz")
|
||||
else()
|
||||
#add_target_compile_flags(vga "-mrtd -fno-builtin")
|
||||
set_source_files_properties(${SOURCE} PROPERTIES COMPILE_FLAGS "-mrtd -fno-builtin")
|
||||
if(NOT MSVC)
|
||||
#allow_warnings(vga)
|
||||
set_source_files_properties(${SOURCE} PROPERTIES COMPILE_FLAGS "-Wno-error")
|
||||
endif()
|
||||
|
||||
set_module_type(vga kernelmodedriver)
|
||||
|
|
|
@ -10,12 +10,14 @@
|
|||
#include "vga.h"
|
||||
|
||||
VP_STATUS
|
||||
NTAPI
|
||||
VgaInterpretCmdStream(
|
||||
PHW_DEVICE_EXTENSION HwDeviceExtension,
|
||||
PUSHORT pusCmdStream
|
||||
);
|
||||
|
||||
VP_STATUS
|
||||
NTAPI
|
||||
VgaSetMode(
|
||||
PHW_DEVICE_EXTENSION HwDeviceExtension,
|
||||
PVIDEO_MODE Mode,
|
||||
|
@ -26,6 +28,7 @@ VgaSetMode(
|
|||
);
|
||||
|
||||
VP_STATUS
|
||||
NTAPI
|
||||
VgaQueryAvailableModes(
|
||||
PHW_DEVICE_EXTENSION HwDeviceExtension,
|
||||
PVIDEO_MODE_INFORMATION ModeInformation,
|
||||
|
@ -34,6 +37,7 @@ VgaQueryAvailableModes(
|
|||
);
|
||||
|
||||
VP_STATUS
|
||||
NTAPI
|
||||
VgaQueryNumberOfAvailableModes(
|
||||
PHW_DEVICE_EXTENSION HwDeviceExtension,
|
||||
PVIDEO_NUM_MODES NumModes,
|
||||
|
@ -42,6 +46,7 @@ VgaQueryNumberOfAvailableModes(
|
|||
);
|
||||
|
||||
VP_STATUS
|
||||
NTAPI
|
||||
VgaQueryCurrentMode(
|
||||
PHW_DEVICE_EXTENSION HwDeviceExtension,
|
||||
PVIDEO_MODE_INFORMATION ModeInformation,
|
||||
|
@ -50,6 +55,7 @@ VgaQueryCurrentMode(
|
|||
);
|
||||
|
||||
VOID
|
||||
NTAPI
|
||||
VgaZeroVideoMemory(
|
||||
PHW_DEVICE_EXTENSION HwDeviceExtension
|
||||
);
|
||||
|
@ -64,6 +70,7 @@ VgaZeroVideoMemory(
|
|||
|
||||
//---------------------------------------------------------------------------
|
||||
VP_STATUS
|
||||
NTAPI
|
||||
VgaInterpretCmdStream(
|
||||
PHW_DEVICE_EXTENSION HwDeviceExtension,
|
||||
PUSHORT pusCmdStream
|
||||
|
@ -349,8 +356,8 @@ Return Value:
|
|||
|
||||
} // end VgaInterpretCmdStream()
|
||||
|
||||
|
||||
VP_STATUS
|
||||
NTAPI
|
||||
VgaSetMode(
|
||||
PHW_DEVICE_EXTENSION HwDeviceExtension,
|
||||
PVIDEO_MODE Mode,
|
||||
|
@ -504,8 +511,9 @@ Cleanup:
|
|||
return NO_ERROR;
|
||||
|
||||
} //end VgaSetMode()
|
||||
|
||||
|
||||
VP_STATUS
|
||||
NTAPI
|
||||
VgaQueryAvailableModes(
|
||||
PHW_DEVICE_EXTENSION HwDeviceExtension,
|
||||
PVIDEO_MODE_INFORMATION ModeInformation,
|
||||
|
@ -641,8 +649,9 @@ Return Value:
|
|||
return NO_ERROR;
|
||||
|
||||
} // end VgaGetAvailableModes()
|
||||
|
||||
|
||||
VP_STATUS
|
||||
NTAPI
|
||||
VgaQueryNumberOfAvailableModes(
|
||||
PHW_DEVICE_EXTENSION HwDeviceExtension,
|
||||
PVIDEO_NUM_MODES NumModes,
|
||||
|
@ -704,8 +713,9 @@ Return Value:
|
|||
return NO_ERROR;
|
||||
|
||||
} // end VgaGetNumberOfAvailableModes()
|
||||
|
||||
|
||||
VP_STATUS
|
||||
NTAPI
|
||||
VgaQueryCurrentMode(
|
||||
PHW_DEVICE_EXTENSION HwDeviceExtension,
|
||||
PVIDEO_MODE_INFORMATION ModeInformation,
|
||||
|
@ -837,8 +847,8 @@ Return Value:
|
|||
|
||||
} // end VgaQueryCurrentMode()
|
||||
|
||||
|
||||
VOID
|
||||
NTAPI
|
||||
VgaZeroVideoMemory(
|
||||
PHW_DEVICE_EXTENSION HwDeviceExtension
|
||||
)
|
||||
|
@ -886,3 +896,4 @@ Return Value:
|
|||
VgaInterpretCmdStream(HwDeviceExtension, DisableA000Color);
|
||||
|
||||
}
|
||||
|
||||
|
|
|
@ -19,6 +19,7 @@
|
|||
//
|
||||
|
||||
VP_STATUS
|
||||
NTAPI
|
||||
VgaFindAdapter(
|
||||
PVOID HwDeviceExtension,
|
||||
PVOID HwContext,
|
||||
|
@ -28,11 +29,13 @@ VgaFindAdapter(
|
|||
);
|
||||
|
||||
BOOLEAN
|
||||
NTAPI
|
||||
VgaInitialize(
|
||||
PVOID HwDeviceExtension
|
||||
);
|
||||
|
||||
BOOLEAN
|
||||
NTAPI
|
||||
VgaStartIO(
|
||||
PVOID HwDeviceExtension,
|
||||
PVIDEO_REQUEST_PACKET RequestPacket
|
||||
|
@ -43,6 +46,7 @@ VgaStartIO(
|
|||
//
|
||||
|
||||
VP_STATUS
|
||||
NTAPI
|
||||
VgaQueryAvailableModes(
|
||||
PHW_DEVICE_EXTENSION HwDeviceExtension,
|
||||
PVIDEO_MODE_INFORMATION ModeInformation,
|
||||
|
@ -51,6 +55,7 @@ VgaQueryAvailableModes(
|
|||
);
|
||||
|
||||
VP_STATUS
|
||||
NTAPI
|
||||
VgaQueryNumberOfAvailableModes(
|
||||
PHW_DEVICE_EXTENSION HwDeviceExtension,
|
||||
PVIDEO_NUM_MODES NumModes,
|
||||
|
@ -59,6 +64,7 @@ VgaQueryNumberOfAvailableModes(
|
|||
);
|
||||
|
||||
VP_STATUS
|
||||
NTAPI
|
||||
VgaQueryCurrentMode(
|
||||
PHW_DEVICE_EXTENSION HwDeviceExtension,
|
||||
PVIDEO_MODE_INFORMATION ModeInformation,
|
||||
|
@ -67,6 +73,7 @@ VgaQueryCurrentMode(
|
|||
);
|
||||
|
||||
VP_STATUS
|
||||
NTAPI
|
||||
VgaSetMode(
|
||||
PHW_DEVICE_EXTENSION HwDeviceExtension,
|
||||
PVIDEO_MODE Mode,
|
||||
|
@ -77,17 +84,20 @@ VgaSetMode(
|
|||
);
|
||||
|
||||
BOOLEAN
|
||||
NTAPI
|
||||
VgaIsPresent(
|
||||
PHW_DEVICE_EXTENSION HwDeviceExtension
|
||||
);
|
||||
|
||||
VOID
|
||||
NTAPI
|
||||
VgaInterpretCmdStream(
|
||||
PVOID HwDeviceExtension,
|
||||
PUSHORT pusCmdStream
|
||||
);
|
||||
|
||||
VP_STATUS
|
||||
NTAPI
|
||||
VgaSetPaletteReg(
|
||||
PHW_DEVICE_EXTENSION HwDeviceExtension,
|
||||
PVIDEO_PALETTE_DATA PaletteBuffer,
|
||||
|
@ -95,6 +105,7 @@ VgaSetPaletteReg(
|
|||
);
|
||||
|
||||
VP_STATUS
|
||||
NTAPI
|
||||
VgaSetColorLookup(
|
||||
PHW_DEVICE_EXTENSION HwDeviceExtension,
|
||||
PVIDEO_CLUT ClutBuffer,
|
||||
|
@ -102,6 +113,7 @@ VgaSetColorLookup(
|
|||
);
|
||||
|
||||
VP_STATUS
|
||||
NTAPI
|
||||
GetDeviceDataCallback(
|
||||
PVOID HwDeviceExtension,
|
||||
PVOID Context,
|
||||
|
@ -116,6 +128,7 @@ GetDeviceDataCallback(
|
|||
|
||||
// eVb: 1.2 [RESOURCE] - Add new function for acquiring VGA resources (I/O, memory)
|
||||
VP_STATUS
|
||||
NTAPI
|
||||
VgaAcquireResources(
|
||||
PHW_DEVICE_EXTENSION DeviceExtension
|
||||
);
|
||||
|
@ -130,7 +143,6 @@ VgaAcquireResources(
|
|||
#pragma alloc_text(PAGE,VgaSetColorLookup)
|
||||
#endif
|
||||
|
||||
|
||||
//---------------------------------------------------------------------------
|
||||
ULONG
|
||||
// eVb: 1.3 [GCC] - Add NTAPI for GCC support
|
||||
|
@ -303,9 +315,10 @@ Return Value:
|
|||
return initializationStatus;
|
||||
|
||||
} // end DriverEntry()
|
||||
|
||||
|
||||
//---------------------------------------------------------------------------
|
||||
VP_STATUS
|
||||
NTAPI
|
||||
VgaFindAdapter(
|
||||
PVOID HwDeviceExtension,
|
||||
PVOID HwContext,
|
||||
|
@ -485,9 +498,10 @@ Return Value:
|
|||
|
||||
|
||||
} // VgaFindAdapter()
|
||||
|
||||
|
||||
//---------------------------------------------------------------------------
|
||||
BOOLEAN
|
||||
NTAPI
|
||||
VgaInitialize(
|
||||
PVOID HwDeviceExtension
|
||||
)
|
||||
|
@ -527,9 +541,10 @@ Return Value:
|
|||
return TRUE;
|
||||
|
||||
} // VgaInitialize()
|
||||
|
||||
|
||||
//---------------------------------------------------------------------------
|
||||
BOOLEAN
|
||||
NTAPI
|
||||
VgaStartIO(
|
||||
PVOID HwDeviceExtension,
|
||||
PVIDEO_REQUEST_PACKET RequestPacket
|
||||
|
@ -912,15 +927,14 @@ Return Value:
|
|||
|
||||
} // VgaStartIO()
|
||||
|
||||
|
||||
//---------------------------------------------------------------------------
|
||||
//
|
||||
// private routines
|
||||
//
|
||||
|
||||
|
||||
//---------------------------------------------------------------------------
|
||||
BOOLEAN
|
||||
NTAPI
|
||||
VgaIsPresent(
|
||||
PHW_DEVICE_EXTENSION HwDeviceExtension
|
||||
)
|
||||
|
@ -1243,10 +1257,10 @@ Return Value:
|
|||
return returnStatus;
|
||||
|
||||
} // VgaIsPresent()
|
||||
|
||||
|
||||
//---------------------------------------------------------------------------
|
||||
VP_STATUS
|
||||
NTAPI
|
||||
VgaSetPaletteReg(
|
||||
PHW_DEVICE_EXTENSION HwDeviceExtension,
|
||||
PVIDEO_PALETTE_DATA PaletteBuffer,
|
||||
|
@ -1334,9 +1348,9 @@ Return Value:
|
|||
|
||||
} // end VgaSetPaletteReg()
|
||||
|
||||
|
||||
//---------------------------------------------------------------------------
|
||||
VP_STATUS
|
||||
NTAPI
|
||||
VgaSetColorLookup(
|
||||
PHW_DEVICE_EXTENSION HwDeviceExtension,
|
||||
PVIDEO_CLUT ClutBuffer,
|
||||
|
@ -1440,8 +1454,9 @@ Return Value:
|
|||
return ERROR_INVALID_PARAMETER;
|
||||
|
||||
} // end VgaSetColorLookup()
|
||||
|
||||
|
||||
VP_STATUS
|
||||
NTAPI
|
||||
GetDeviceDataCallback(
|
||||
PVOID HwDeviceExtension,
|
||||
PVOID Context,
|
||||
|
@ -1501,6 +1516,7 @@ Return Value:
|
|||
|
||||
// eVb: 1.16 [RESOURCE] - Add new function for acquiring VGA resources (I/O, memory)
|
||||
VP_STATUS
|
||||
NTAPI
|
||||
VgaAcquireResources(
|
||||
PHW_DEVICE_EXTENSION DeviceExtension
|
||||
)
|
||||
|
|
Loading…
Reference in a new issue