Git conversion: Make reactos the root directory, move rosapps, rostests, wallpapers into modules, and delete rossubsys.
- Add in MSVC support for HAL .init sections by using alloc_text. MSVC support for putting the HAL pci class and vendor tables into .init is still lacking. Put into a _MINIHAL_ guard or freeldr gets REALLY sad. - Rename INIT_FUNCTION to INIT_SECTION and put it at the top of functions for consistency with __declspec declarations (it is actually possible to do this via __declspec in newer MSVC versions). svn path=/trunk/; revision=69037
[HAL] - Implement HalStartProfileInterrupt, HalSetProfileInterval, and HalpProfileInterruptHandler Now kernrate works! CORE-10066 #resolve svn path=/trunk/; revision=68863
[HAL] Small cleanup and fix amd64 build (don't use the PIT) svn path=/trunk/; revision=53497
[HAL] We cannot make any assumptions about the latency whith which the timer interrupt fires after a rollover, since VBox (other VMs probably as well) doesn't always meet this. Add another check to KeQueryPerformanceCounter that gracefully handles missing interrupts. Also raise to DISPATCH_LEVEL, since the function is not reentrant. svn path=/trunk/; revision=53496
[HAL] - Rewrite KeQueryPerformanceCounter in C - Implement support for changing the clock rate svn path=/trunk/; revision=53495
[HAL] Convert while (TRUE); to ASSERT(FALSE); on unimplemented pathes. svn path=/trunk/; revision=50096
[HAL]: Add INIT_FUNCTION where needed. Will save 860KB later. svn path=/trunk/; revision=49463
[HAL] - Stub support for future timer latency watchdog. - Change older-style comments to standard ReactOS commenting style. svn path=/trunk/; revision=48731
[HAL] - Move all amd64 specific files to one amd64 folder - Compile x86 specific timer code only on x86 - Use KeRegisterInterruptHandler instead of manual idt manipulation - add missing stubs for amd64 svn path=/trunk/; revision=47565
[hal] Add a mini-HAL static library Mostly the same thing as the real one, except interrupts and DMA svn path=/trunk/; revision=45809
[REACTOS] Add asm.h containing macros to make assembly code both GAS and ML compatible at the same time. [NTOS/HAL] Move trap entry points from C into a GAS/ML compatile assembly file (might need fine tuning for ML). The entries are generated by a shared assembly macro TRAP_ENTRY. Removed KiTrapStub, KiIsV8086TrapSafe, KiIsUserTrapSafe, KiSetSaneSegments, removed segment handling from KiEnter*Trap. [NTOS] Make KiFastCallEntryHandler and KiSystemServiceHandler FASTCALL and pass the systemcall number in TrapFrame->Eax [HAL] Use _setjmp/longjmp instead of saving a trapframe in HalpBiosCall svn path=/trunk/; revision=45565
[HAL]: Implement the profile and clock interrupt trap/handlers in C instead of ASM. This allows the kernel to remove the ugly hacks based on internal knowledge of how the assembly/stack of the HAL is supposed to look like. Everything is now done through a clean C interface. [NTOS]: Remove said hacks and have a normal C implementation of KeUpdateSystemTime. It exits the interrupt through a soft interrupt exit. [NTOS]: Implement 4 lines of support code needed to handle interrupts during V8086 mode, which were lacking since we weren't hitting this case yet. Note that now the KeUpdateSystemTime interface is not "compatible" with Windows anymore. This does not matter, since the only possible caller of KeUpdateSystemTime is a very specific HAL routine that needs a very specific stack layout to actually work, so the chance of anyone calling this API is absolutely zero (no, not even some experimental driver. It's absolutely impossible). svn path=/trunk/; revision=45276
- Document and define Timer and System Control Ports (0x43, 0x61) as defined in ISA System Architecture 3rd Edition and The Undocumented PC. - Document PIT access modes, channels and operating modes. - Rewrite HalHandleNMI to use the System Control Port definitions instead of magic values that were never explained. - Rewrite HalMakeBeep not to program the PIT with magic hexadecimal values that were not explained anywhere and seem dubious. - Fix the PIT frequency to match its correct value of ~1.19318MHz which is what every x86 book states and what Linux and all other operating systems use. This is equivalent to one third of the NTSC color burst (subcarrier frequency) used on CGA computers for video output. Previously, the HAL used 1.193167MHz, which is only used by NT and isn't documented anywhere, and in fact appears to be a typo in the NT sources (a less accurate way of dividing the NTSC color burst gives 1.19318167MHz). Somehow, the ReactOS developer of this function must have made the same "typo", by complete coincidence, of course. - Rewrite part of HalpInitializeClock to use the new definitions. This function was at least somewhat documenting the magic values. svn path=/trunk/; revision=44991
- Replace broken implementation of HalpCalibrateStallExecution with a new implementation by a mysterious HAL ninja and myself. The old implementation calculated the stall count factor incorrectly and produced bogus results that were off by several thousand, and varied by as much for each boot, and can best be described as "rand() made complicated". The new implementation installs its own RTC interrupt handler to accurately calculate the stall scale factor, all done in assembler instead of broken C. Fixes the hang at boot when initializing Uniata as stalls no longer takes 10 times or more as long to execute then they should. svn path=/trunk/; revision=43789
[ntoskrnl] - Reimplement HalpCalibrateStallExecution which was removed in r24964. Real Windows uses a different algorithm, however existing one seems to work acceptably. This patch is critical for devices support on real hardware. The only downside is that uniata initialization takes a substantial amount of time now, this is going to be investigated. Patch by Daniel Zimmermann. See issue #4600 for more details. svn path=/trunk/; revision=43364
Merge HAL changes 34743, 34812, 34839, 34917, 35515, 35771, 35902, 35904, 35905, 35906, 35942, 35947, 35948, 35949, 35953, 36013, 36388, 36389, 36570, 37873, 37991, 39151 from amd64 branch svn path=/trunk/; revision=43173
- Use msvc intrinsics in HAL instead of Ke386* svn path=/trunk/; revision=43074
compatability fixes, so some hal code can be shared svn path=/branches/ros-amd64-bringup/; revision=35902
- Fix a bug in KeQueryPerformanceCounter which was reading the flags in ESI instead of ECX. - Fix a bug in KeQueryPerformanceCounter which wasn't handling the possibility of an invalid counter value. - Don't disable/enable interrupts in HalpInitializeClock and HalCalibratePerformanceCounter. Instead, save the flags, disable, and then restore flags, so that if interrupts were disabled initially, they'll remain that way. - Make KeUpdateRunTime and KeUpdateSystemTime support KPRCB->SkipTick. - Atomically check for DPC routine active by referencing fs. Also update Debug DPC time. - Add support for detecting break-in during KeUpdateSystemTime. - DPC Routine active is a BOOLEAN, not a ULONG. Fix the check in KeUpdateRunTime since this might've messed up a lot of things. - Temporarily disable DbgBreakPoint during DbgPrint. - Hang in KeQueryPerformanceCounter while WinDBG is connected is now fixed, as well as DbgPrint support. WinDBG can now remain connected and show all the DebugPrints! (But GUI doesn't boot -- yet). svn path=/trunk/; revision=25984