Commit graph

24172 commits

Author SHA1 Message Date
Hervé Poussineau 030a4abe86 Convert text to multibyte before displaying it
svn path=/trunk/; revision=25992
2007-03-04 23:26:30 +00:00
Hervé Poussineau abfa7fb417 Some reformatting, no code change
svn path=/trunk/; revision=25991
2007-03-04 23:18:28 +00:00
Aleksey Bragin 55a11ded1b Fix compiling in proper npfs mode.
svn path=/trunk/; revision=25989
2007-03-04 21:14:58 +00:00
Alex Ionescu 1e35f772f8 - Enable _WINKD_ in config.rbuild. Currently set to 0 and don't set it to 1 yet because it won't build yet.
- Support _WINKD_ in ntoskrnl.rbuild to build KD64 instead of KDBG/KD if it's enabled.
- Remove some incorrect kernel exports.

svn path=/trunk/; revision=25988
2007-03-04 20:52:54 +00:00
Alex Ionescu be2645ad8a - Wrap some KDBG-specific initialization in _WINKD_ guard.
- Remove KdpDetectConflicts since our serial driver correctly uses KdComPortInUse for this (and kdcom fills it out).

svn path=/trunk/; revision=25987
2007-03-04 20:28:18 +00:00
Alex Ionescu bf3d075381 - Add kd64.h header from branch and format it nicely.
- Add support for _WINKD_ definition to use kd64.h instead of kd.h, as well as disable usage of rossym.h
- Add KdSystemDebugControl, NtSet/QueryDebugFilterState to kdapi.c for the KD64 code.

svn path=/trunk/; revision=25986
2007-03-04 19:54:39 +00:00
Alex Ionescu f7577eaeb7 - Enable stubs in kdcom to actually be exported (to simplfiy compatibility with KD Branch, which won't be needed soon thanks to a build flag).
- Enable call to KdDebuggerInitialize1 even in trunk, since it doesn't do anything.
- Make i8042prt stop using a reactos-only kernel export hack (KdpServiceDispatcher),and use KdSystemDebugControl instead, which is the NT version and fully-exported.
- Implement a stub KdSystemDebugControl and export it.

svn path=/trunk/; revision=25985
2007-03-04 19:20:03 +00:00
Alex Ionescu 12e7593f24 - 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
2007-03-04 19:06:34 +00:00
Eric Kohl 3e6fa8fd31 Translate german resources.
svn path=/trunk/; revision=25983
2007-03-04 18:47:12 +00:00
Eric Kohl 2f8a2c2ac1 - Show disables and selected menu items.
- User the caption font to display the window text.

svn path=/trunk/; revision=25982
2007-03-04 18:41:47 +00:00
Magnus Olsen 78674981d1 split up all testcase to own file. the size are growning
svn path=/trunk/; revision=25981
2007-03-04 11:57:44 +00:00
Magnus Olsen 5b73c362ba adding so dump can decoding pCallBackFlags[0] so we do not need calc out what hardware acclations DD_CALLBACKS support.
svn path=/trunk/; revision=25980
2007-03-04 11:45:29 +00:00
Eric Kohl 9039b97b9f Users can now set bold or italic fonts.
svn path=/trunk/; revision=25978
2007-03-03 21:03:22 +00:00
Magnus Olsen 2c81a2df18 partly implement NtGdiDdReenableDirectDrawObject
this give us bit more closer getting hardware accalertions working. 

svn path=/trunk/; revision=25977
2007-03-03 20:19:56 +00:00
Alex Ionescu c44e8d2c89 - Fix another typo in CommonDispatchException (with yet another critical flaw as a result). Sometimes, exceptions would incorrectly be detected as coming from user-mode even though CS was kernel mode. When creating the KTRAP_FRAME, the kernel would then add the Ring 3 RPL_MASK (3) (because it believed we're in usermode) to the kernel-mode CS, creating the invalid CS of 0xB, which would lead into a GPF during the iretd.
- Re-enable DebugPrint since this now works.

svn path=/trunk/; revision=25976
2007-03-03 19:49:36 +00:00
Alex Ionescu a195100319 - Fix critical bugs in DR_TRAP_FIXUP, TRAP_PROLOG and TRAP_EPILOG which would either cause infinite loops during exceptions or corruption of the correct code path when dealing with debug registers.
- Fix a bug in KiRecordDr7 setting the new DR7 mask.
- Make KiEspToTrapFrame thread-safe by raising to APC_LEVEL to make sure a thread/set context doesn't corrupt the state.
- Fix thread-safe IRQL Code in KeContexToTrapFrame/KeTrapFrameToContext.
- Fix KiDispatchException to properly handle KI_EXCEPTION_ACCESS_VIOLATION and convert it back to STATUS_ACCESS_VIOLATION which is what the system expects.
- Also fix the way we do bugchecks so the the trapframe gets properly put as a parameter.
- Make KiDebugService call into KiTrap3 to share code (merge from kd-branch).
- Changes to the KdpEnterDebuggerException hack we have to handle this change.
- Temporarily disable DebugPrint functionality (sorry, I'm onto a big bug here!)

svn path=/trunk/; revision=25975
2007-03-03 17:24:58 +00:00
Magnus Olsen 037363f05d NtGdiDdQueryDirectDrawObject
1. fixed some return code it get right. 

svn path=/trunk/; revision=25973
2007-03-03 16:31:28 +00:00
Eric Kohl 7368a5b0d4 - Let the user edit the font size directly.
- Remove the useless "NOT CBS_SIMPLE" window style from the font size combobox.

svn path=/trunk/; revision=25970
2007-03-03 12:44:09 +00:00
Sylvain Petreolle 827a4b1699 downloader fixes:
remove downloader.xml from bootcd
fix paths in .rbuild

svn path=/trunk/; revision=25969
2007-03-03 11:41:28 +00:00
Alex Ionescu 27065dc629 - Remove DbgPrint committed in FreeLDR by accident.
- Fix a hack in DbgLoadImageSymbols.

svn path=/trunk/; revision=25967
2007-03-03 05:44:58 +00:00
Alex Ionescu 523822a169 - Copy the entire drivers in memory, not just their mappable sections, since WinDBG (and probably other things) use "SizeOfImage" in the header to figure out when the image ends, but we map considerably less, creating overlaps.
svn path=/trunk/; revision=25966
2007-03-03 05:41:14 +00:00
Alex Ionescu af68f5e42d - Remove KD APIs from stub HAL, they've been in kdcom for a while (merge from kd-branch).
- DebugPrint/DebugPrompt should have an int3 after the int2d, and the int2d handler should ++ the trap frame's EIP to compensate (merge from kd-branch).
- Remove KDB symbol hooks (merge from kd-branch).
- Make PSEH compialble in MSVC again after Greatlord's break.
- Fix KiSaveProcessorControlState/KiRestoreProcessorControlState (merge from kd-branch).
- Disable GDB hook/hacks (merge from kd-branch).
- Add KD64 directory from kd-branch with SharedUserData access enabled (no other code changed). It's not currently compiled though, just putting it here.

svn path=/trunk/; revision=25965
2007-03-03 04:39:25 +00:00
Sylvain Petreolle 61ea6949b7 fix build
svn path=/trunk/; revision=25964
2007-03-02 22:04:21 +00:00
Aleksey Bragin 545cea09f9 Don't spam debug log with that message, it seems it's normal.
svn path=/trunk/; revision=25961
2007-03-02 21:11:16 +00:00
Christoph von Wittich 913d1938ee some configuration changes for debug builds
svn path=/trunk/; revision=25960
2007-03-02 21:04:41 +00:00
Christoph von Wittich e3a80a5990 fix the msvc backend on linux hosts
svn path=/trunk/; revision=25959
2007-03-02 20:53:41 +00:00
Alex Ionescu f5751896c4 -Fix build
svn path=/trunk/; revision=25958
2007-03-02 20:40:48 +00:00
Christoph von Wittich 46921a9a8f fix a crash in the msvc8 backend
svn path=/trunk/; revision=25957
2007-03-02 20:30:12 +00:00
Alex Ionescu ae80dd6422 - Fix various ntoskrnl/wdk compilation issues in rossym, cmlib, kdcom, rtl.
- Rename one more duplicated file in the kernel which wasn't caught previously.
- pseh, rossym, cmlib, kdcom, bootvid, rtl compile & link, and ntoskrnl is now down to only 23 linker errors.

svn path=/trunk/; revision=25956
2007-03-02 19:52:29 +00:00
Alex Ionescu 7815967299 - Do massive renames in the ntoskrnl tree to make sure we don't have multiple files with the same name (this makes msvc very, very, sad).
- Add _IN_KERNEL_ define for WDK compatibility when using resstr.h
- The entire kernel can now be compiled with MSVC (read this sentence carefully before throwing out the champagne).

svn path=/trunk/; revision=25954
2007-03-02 18:25:23 +00:00
Magnus Olsen e48040833f adding a small debugprint to detect if pseh going into a endless loop, if we see same msg from it repate it self whole time, we known then pseh have gone into endless loop.
svn path=/trunk/; revision=25953
2007-03-02 17:49:47 +00:00
Maarten Bosma 6a00d9d64a Lester Kortenhoeven (lester(at)kortenhoeven(dot)de): Implement scripting.
svn path=/trunk/; revision=25952
2007-03-02 17:27:39 +00:00
Alex Ionescu 794a97e498 - More MSVC fixes.
svn path=/trunk/; revision=25948
2007-03-02 16:28:34 +00:00
Alex Ionescu 9efff39376 - Fix multiple WDK compatibilities issues.
- Fix MSVC warnings and incompatibilities.

svn path=/trunk/; revision=25947
2007-03-02 16:26:45 +00:00
Christoph von Wittich 7270b49222 fix mkhive on x86_64 hosts
svn path=/trunk/; revision=25946
2007-03-02 15:57:34 +00:00
Alex Ionescu b15fa5308e - Rewrite a dirty, reverse-engineered function written by dwelch (David Welch) 7.1 years ago in revision 965. We must agressively continue to hunt down such reversed code by previously tainted ReactOS developers who have thankfully left/been kicked out since then.
svn path=/trunk/; revision=25945
2007-03-02 07:37:45 +00:00
Alex Ionescu 5ba38d0494 - Don't depend on LD variables anymore for Mm.
- Update KrnlFun.c
- Make pushlock.c compile with msvc/wdk.
- Fix definition of HIGH_LEVEL_ENTRIES which was way too small (and thus always 0) which caused frees/allocates in the 3rd-level table not to work properly. MSVC statically detected this, it's unlikely we were hitting this in ROS at the moment but it would've been a bad bug to catch later, yay msvc.

svn path=/trunk/; revision=25944
2007-03-02 07:23:19 +00:00
Alex Ionescu ba689f332a - Fix some rtl warnings on /W3.
svn path=/trunk/; revision=25943
2007-03-02 07:21:33 +00:00
Alex Ionescu a0a19e46ae - Merge from KD-branch:
- Remove double implementation of DebugPrint with a single correct implementation which calls DebugService, and moved DebugPrint to rtl since it can now be shared properly.

svn path=/trunk/; revision=25942
2007-03-02 06:11:27 +00:00
Alex Ionescu 2e20ca1f14 - Create PDE/PTE entries for KUSER_SHARED_DATA in FreeLDR, so that MmInit1 isn't needed to access it.
- This allows us to access SharedUserData much earlier in the kernel, as well as in kdcom, which means the Windows/TinyKRNL version should now work without modification.

svn path=/trunk/; revision=25941
2007-03-02 06:01:07 +00:00
Alex Ionescu d89145a431 - Fix a bug in HalEnableSystemInterrupt which was causing us to read invalid port data instead of the PCI edge/level registers.
- Fix an offset bug which was causing us to read/write to DR7 in a completely random location (somewhere in side the _CONTEXT record).
- Fix a bug in DR save/restore which was making us save dr0,1,2 isntead of dr3,6,7.
- All bugs reported by Aleksey Bragin.

svn path=/trunk/; revision=25938
2007-03-01 20:27:33 +00:00
Alex Ionescu 5928240766 - Fix KiDispatchException to unmask KI_EXCEPTION_INTERNAL when setting the exception code, so that usermode/SEH filters get proper exception codes again.
- Fixes and compatible merges from KD Branch:
 - Add stubs for KdSave, KdRestore, KdDebuggerInitialize0, KdSendPacket, KdReceivePacket to kdcom.dll
 - Implement and export KeTryToAcquireSpinLockAtDpcLevel.
 - Add EXCEPTION_RECORD64 and LIST_ENTRY64, KeTryToAcquireSpinLockAtDpcLevel, BREAKPOINT_COMMAND_STRING, Ke386SetCr2, Ke386SetDr3, Ke386SetDr6.
 - Remove non-kernel routines from kdfuncs.h and remove deprecated routines from ke.h.
 - Implement KiRestoreProcessorControlState, KeFreezeExecution, KeThawExecution, ExAcquireTimeRefreshLock, ExReleaseTimeRefreshLock.
 - Rename ModuleLoadList to PsLoadedModuleList. Add PsNtosImageBase and set value in it.
 - Add skeleton wdbgexts.h with what's needed until now, this is a PSDK header.
 - Add kddll.h for KDCOM/1394/USB2.DLL prototypes.
 - Add windbgkd.h with KD protocol definitions. Used to be an NT5 DDK header, but was removed, so this goes into include\reactos.
 - Fix KiDebugService to load EDX from KTRAP_FRAME_EDX, not KTRAP_FRAME_EAX!.
 - Fix CommonDispatchException to check for the argument count in ECX, not EAX. Previously we were ignoring parameter counts and never filling out exception records!
 - Add KdDebuggerInitialize1 and enable call to it.
 - Fix KD_SYMBOLS_INFO definition and DbgLoadImageSymbols prototype.
 - Implement DbgUnLoadImageSymbols.
 - Fix some small bugs in KeBugCheckWithTf and add various debugger calls/checks where needed.
 - Fix bugcheck recursion code which was incorrect.
 - Only save/restore CR4 if KeFeatureBits indicates CR4 support exists.
 - Export KdDebuggerNotPresent since KDCOM needs it.
 - Add KCONTINUE_STATUS.
 - Add DBGKD_ANY_CONTROL_SET and X86/IA64/AMD64 control sets.
 - Add DBGKD_MANIPULATE_STATE64 and all sub-structures (READ_MEMORY, WRITE_MEMORY, etc).
 - Create GCC_ULONG64 type to hack around a bug in GCC which is incapable of creating entries for externals at compile-time for 64-bit pointers.
 - Rename NameSpaceRoot to ObpRootDirectoryObject, IopLogListHead to IopErrorLogListHead, BugcheckCallbackListHead to KeBugcheckCallbackListHead, BugcheckReasonCallbackListHead to KeBugcheckReasonCallbackListHead, ObTypeObjectType to ObpTypeObjectType.
 - Create ntverp.h and common.ver files. These are the standard files used by the NT/DDK build systems and we should try to support them as well instead of re-defining everything our own way (especially if we want to build ddk-compatible drivers later on).
 - Made init.c use version data from ntverp.h instead of hard-coding.
 - Defined NT 5.2.3790.1830 as the version we report.
 - Fixed up .rc file to be correct and match DDK-sytnax/style.
 - For now only the kernel uses this new versionning scheme, but we should change the build system later to use this for every component.
 - Fix KiSaveProcessorControlState and KiRestoreProcessorControlSate. The latter doesn't freeze the CPU anymore so it's enabled, and the former doesn't cause WinDBG to panic anymore and display weird data.
 - KPROCESSOR_STATE is not 4-byte aligned.
 - Use DR_MASK and DR7_OVERRIDE_V in KiUpdateDr7, KiRecordDr7 instead of DR_ACTIVE_MASK.
 - Add ExceptionRecord32To64.
 - Fix generation of driver name for symbol load.

svn path=/trunk/; revision=25937
2007-03-01 19:51:20 +00:00
Magnus Olsen 94297234b4 NtGdiGetObject
1. fixed one BSD it does show bluescreen when the buffer are too small
2. fixed some bugs in calculation of different GdiObject sized

svn path=/trunk/; revision=25935
2007-03-01 19:13:29 +00:00
Ged Murphy eb28b183e5 - call undocumented functions directly when building with MSVC and the MS PSDK
- fixes building with MSVC

note, this can be removed when bulding ROS with MSVC isn't reliant on the MS PSDK

svn path=/trunk/; revision=25932
2007-02-28 23:43:12 +00:00
Eric Kohl c04b7173b2 Add code to support font size changes.
svn path=/trunk/; revision=25931
2007-02-28 22:49:34 +00:00
Eric Kohl c296041163 Use wsprintf() to convert an integer to a string instead of abusing a hidden edit control.
svn path=/trunk/; revision=25930
2007-02-28 20:44:47 +00:00
Alex Ionescu 045e38927e - Make usetup ""work"" on systems with ~28MB+ RAM. Due to an unknown bug (in usetup or Mm, file copies during setup don't get flushed until memory reaches about 42-47% remaining. At this point, if enough memory is available, no more memory will be allocated, even though more files are being copied. On systems with < 48MB, the system will not usually flush pages fast enough to keep the memory at ~42-47%. We ""fix"" this by adding a delay to each file copy as long as free memory is below 40%.
- Also added 3 progress bars during memory transfers to show the status of the memory.

svn path=/trunk/; revision=25929
2007-02-28 20:43:13 +00:00
Alex Ionescu a1ad43c2ee - More refactoring of FreeLDR/SetupLDR PE Loader Code to remove some hacks.
- Don't double-free some entries when failing to load a boot driver. This would cause a crash when pciide couldn't load (since we don't yet import drivers in FreeLDR, and pciide needs pciidex). Thanks to encoded for reporting it.
- We now free boot driver memory again since it's safe to do so again. This should reduce memory requirements even more.

svn path=/trunk/; revision=25928
2007-02-28 19:04:27 +00:00
Alex Ionescu 864da6c412 - Properly load drivers using new method describred previously (read from disk into temporary allocated buffer, then map into allocated memory, then free disk buffer).
- FreeLDR doesn't relocate nor map imports for drivers yet..still needs testing/fixes.

svn path=/trunk/; revision=25927
2007-02-28 17:48:44 +00:00
Sylvain Petreolle 257f23bf3b forget to add 2 files
svn path=/trunk/; revision=25926
2007-02-28 14:24:17 +00:00