Commit graph

29560 commits

Author SHA1 Message Date
ReactOS Portable Systems Group 0ef4d8dcdd Don't loop the page array list THREE times to set it up, ONCE is plenty enough!
Remove the incomprehensible PFN allocation being done for the pages holding the page list array. We now: 1) Find the highest usable RAM page 2) Allocate the PTEs to hold the array from that point on and lower.
Don't do expensive divisions for every single page on the system being looped! Precompute the values ONCE.
Don't set the reference count for the KPCR and KUSER_SHARED_DATA to 0, these are LIVE pages!
Removed the hack which pre-initializes the balancer -- this isn't needed anymore since the initial PTEs are allocated always from RAM now.
Add some comments about the assumptions being made in this code regarding all PCs having the same kind of memory maps.

svn path=/trunk/; revision=32357
2008-02-14 16:40:32 +00:00
ReactOS Portable Systems Group 81d636ae70 The Memory Manager design dictated that every page must be on a linked list, so that it can be removed from that list when dereferenced, and inserted on the free list. This wasn't optimal, because the UsedPageListHead was actually not used for anything else than working set and user-page LRU. Nevertheless, every single page on the system would be on a list (such as the non-pool memory list), even if those lists were ignored. Those lists are all gone now, replaced by the UsedPageListHead. Likewise, the BIOS page list has also been removed.
svn path=/trunk/; revision=32356
2008-02-14 15:36:12 +00:00
Daniel Reimer 14154e1c58 Bug 3053: some slovak translations by Mario Kacmar - kario@szm.sk
Bug 3066: Recent usetup polish translation update by Olaf Siejka - olaf_siejka@o2.pl

svn path=/trunk/; revision=32355
2008-02-14 11:30:14 +00:00
ReactOS Portable Systems Group 7ea9f649ca Remove more dead code from MmInit1. This nugget was trying to free memory allocations between 0x80F50000 and 0x80600000?
[FORMATTING] Make MmInitializePageList readable by human beings.
Remove code in MmInitializePageList which was just repeating what MmInit1 had already done (why?). Remove alignment code which was duplicated (why??).

svn path=/trunk/; revision=32354
2008-02-14 04:44:51 +00:00
ReactOS Portable Systems Group ad3e1b7948 [FORMATTING] Reformat MmInit1.
Also, it seems someone added code to get the First/LastKernPhysAddrs without having them setup (they are setup by the FreeLDR hack-code in freeldr.c, not by "real" bootloaders)... so why set them up in the first place? The code now uses the nice memory-list based routines to get this information instead.
Re-factored some detection and debugging code, cleaned up comments.


svn path=/trunk/; revision=32353
2008-02-14 04:28:41 +00:00
ReactOS Portable Systems Group 44baeebd8a [FORMATTING] Remove dead code (#if 0) and re-organize the file to match kernel standard layout/style.
Get rid of old debugging hacks introduced by ion (rmapready, pageopready, pagingready).

svn path=/trunk/; revision=32352
2008-02-14 03:08:20 +00:00
ReactOS Portable Systems Group 7c1fea060f Don't overwrite the stacks anymore -- set the right pointer in the ARM loader block (remember that stacks are top-down!).
Make a specialized UNIMPLEMENTED for Mm code so we don't go too far into the boot with 100 failures hanging behind our backs, which makes it hard to debug progress.

svn path=/trunk/; revision=32351
2008-02-14 02:33:42 +00:00
ReactOS Portable Systems Group 70fbfefbe5 Say hello to 4KB pages! Removed bring-up 1MB page hacks all over FreeLDR, and setup the kernel pages the same way the x86 build does it -- 6MB from 0x80800000 to 0x80DFFFFF for kernel and drivers.
We still identity map the bottom 0MB of memory with a 1MB page, since this makes the most sense.
We now map the low 8MB of memory to 0x80000000-0x807FFFFF, also with 4KB pages. This area will be discardable after early-init, and contains the early boot structures allocated by FreeLDR.
The Loader Parameter Block and its Extension are now dynamically allocated, instead of being static inside FreeLDR.
Fixed some bugs in the ARM_PTE structure.

svn path=/trunk/; revision=32350
2008-02-14 02:25:25 +00:00
Marc Piulachs 3f38f62b4c -'win32csr' and 'access' localizations by Javier Ramacha
See issue #3028 for more details.

svn path=/trunk/; revision=32349
2008-02-13 21:00:33 +00:00
Johannes Anderwald 773c3b017d - use tchar
- rename dialog to win xp sp2+ name

svn path=/trunk/; revision=32348
2008-02-13 17:51:41 +00:00
Dmitry Chapyshev 356bb09e5b - Fix build
svn path=/trunk/; revision=32347
2008-02-13 17:09:51 +00:00
Dmitry Chapyshev 7bbd9b91ed - Add winhttp.dll from Wine
- Add winhttp.h from Wine
- Add rbuild file for winfax.dll
- Add winhttp and winfax to bootcd

svn path=/trunk/; revision=32346
2008-02-13 16:46:28 +00:00
Dmitry Chapyshev 206e93a129 - Update Russian translation
svn path=/trunk/; revision=32345
2008-02-13 15:38:05 +00:00
Dmitry Chapyshev 1dcbc1bb71 - Synced wine head
svn path=/trunk/; revision=32344
2008-02-13 15:37:13 +00:00
Dmitry Chapyshev 4f86f92b0a - Update Russian translation
- Fix typos

svn path=/trunk/; revision=32343
2008-02-13 15:34:50 +00:00
ReactOS Portable Systems Group ea56f811ec Convert all Mm ASM stubs to C stubs in mm/arm/stubs.c. Now we can see what functions are called.
svn path=/trunk/; revision=32342
2008-02-13 06:43:36 +00:00
ReactOS Portable Systems Group e31c6ada8e Add /arm tree for Memory Manager and stub MmUpdatePageDir in C.
Add exp.c for ARM. Stub out KeContextToTrapFrame in C.
Add thrdini.c for ARM and implement KeArmInitThreadWithContext -- may require changes if the exception frame structure isn't preserving all we need. Stub out KiThreadStartup in C.

svn path=/trunk/; revision=32341
2008-02-13 05:16:14 +00:00
ReactOS Portable Systems Group a177849941 HalInitializeProcessor has no work to do on ARM
svn path=/trunk/; revision=32340
2008-02-13 05:11:35 +00:00
ReactOS Portable Systems Group 0c117eca26 Kill PSEH on ARM
svn path=/trunk/; revision=32339
2008-02-13 05:11:12 +00:00
ReactOS Portable Systems Group 172094a162 First attempt at ARM Exception Frame structure definition
svn path=/trunk/; revision=32338
2008-02-13 05:10:45 +00:00
ReactOS Portable Systems Group 2877ab7568 Just return FALSE in KDCOM on ARM, instead of freezing.
svn path=/trunk/; revision=32337
2008-02-13 04:58:43 +00:00
Timo Kreuzer a8c044b6cb Big ntuser fix:
- rename ObmXxx functions to UserXxx functions
- remove some macros
- move prototypes to object.h
- implement UserreferenceObjectByHandle creating a reference to the object, used for cursoricon stuff so far
- rewrite object manager functions to reasonably handle references
- dereference cursoricons correctly, so they will really get deleted -> fixes a cursoricon leak
- destroy submenus in NtUserDestroyMenu -> fixes a big menu leak
- free the buffer of the menu text -> fixes a mem leak
- delete old bitmaps in NtUserSetCursorContent -> fixes a bitmap leak
- delete monitor object on failure
Now taskmgr doesn't leak memory anymore. we still leak some user handles here and there even after terminating a process, but it's much better now.

svn path=/trunk/; revision=32336
2008-02-13 00:46:23 +00:00
Timo Kreuzer 8e61015f65 BITMAPOBJ_CopyBitmap:
- release lock on failure
- delete created bitmap on failure
- copy flags, fixes a memory leak

svn path=/trunk/; revision=32335
2008-02-12 23:14:07 +00:00
ReactOS Portable Systems Group ed323f3711 We now have a good initialization routine for ARM. We call HalInitializeProcessor (TBD) to setup the board, then we configure the PRCB and PCR. We also setup some global CPU variables and setup minimal interrupt support. The rest of the code follows the x86 design (Create initial thread/process).
There's now a cpu.c for ARM as well, and the cache routines are now there.
KDCOM APIs were marked as kernel stubs, so the kernel was never linking with kdcom. This has been fixed, and boot now stops in kdcom!KdPortInitializeEx since there's no ARM-compatible code.

svn path=/trunk/; revision=32334
2008-02-12 22:50:54 +00:00
ReactOS Portable Systems Group 93970a965e Added cache sweeping code into the HAL, for ARM926EJ-S and ARM1026EJ-S CPUs.
Finished implementation of KiSystemStartup.
Copied KiInitializeKernel from x86 to ARM, removing irrelevant parts. This is our current checkpoint.

svn path=/trunk/; revision=32333
2008-02-12 20:32:23 +00:00
ReactOS Portable Systems Group 0237c83496 QEMU doesn't support TLB Lockdown, so we now use a hack for QEMU and broken CPUs [albeit a portable one ;-)]. PCR access in usermode/kernelmode works.
We now have HalSweepI/Dcache APIs exported and stubbed in the ARM HAL (great, since UNIMPLEMENTED macro now works).
We now setup more of the PCR, including all the cache values required, then we call the HAL sweep functions (TBD).

svn path=/trunk/; revision=32330
2008-02-12 19:01:48 +00:00
Christoph von Wittich 4232dfc7a2 fix some memory and resource leaks
fixes by janderwald and myself

svn path=/trunk/; revision=32329
2008-02-12 18:49:20 +00:00
ReactOS Portable Systems Group e28048569a Fixed some bugs in KeFillFixedEntryTb -- we actually needed to map the PTE into memory (then we can umap it).
We were doing the initial PCR/PDR page allocation completely wrong since we're using 1MB section pages, not 4KB pages (this needs to be fixed later).
Piggyhack arm_kprintf on top of DebugService which we now define. DPRINT1 and ASSERT now work!
Send ARC paths and normalized command-line in the loader parameter block.
Current state:
FreeLoader v3.0 for ARM
Bootargs: rdbase=0x2000000 rdsize=0x1400000
Detecting Hardware...
Loading...
Reading NTOSKRNL.EXE
Reading BOOTVID.DLL
Reading HAL.DLL
Reading HAL.DLL                                                                 
Reading c_1252.nls
Reading c_437.nls
Reading l_intl.nls
Reading scsiport.sys
Reading atapi.sys
Reading buslogic.sys
Reading pci.sys
Reading class2.sys
Reading disk.sys
Reading vfatfs.sys
Reading ndis.sys
Mapped serial port to 0xc00f1000
(ntoskrnl/ke/arm/kiinit.c:135) -----------------------------------------------------
(ntoskrnl/ke/arm/kiinit.c:136) ReactOS 0.4-SVN (Build 20080207-r32151)
(ntoskrnl/ke/arm/kiinit.c:137) Command Line: DEBUG  DEBUGPORT=COM1  BAUDRATE=115200  SOS
(ntoskrnl/ke/arm/kiinit.c:138) ARC Paths: ramdisk(0) \ ramdisk(0) \ReactOS\


svn path=/trunk/; revision=32328
2008-02-12 18:34:33 +00:00
ReactOS Portable Systems Group b8a06afb8c Added arm_kprintf() for early kernel debugging (ARM bringup).
Freeldr maps the "Versatile"'s serial port into virtual
memory now, and C code can just use arm_kprintf().
This is not code that is supposed to remain in the kernel,
it's only needed for bringup, until enough is working so
that standard serial DbgPrint() works through the original
code path.

svn path=/trunk/; revision=32327
2008-02-12 17:45:58 +00:00
Gregor Brunmar 0531986011 Implemented IDirect3D9::GetAdapterDisplayMode()
svn path=/trunk/; revision=32326
2008-02-12 17:30:32 +00:00
Daniel Reimer 1b3b0a7310 Hopefully the last String. Translators. Your turn.
svn path=/trunk/; revision=32325
2008-02-12 17:00:09 +00:00
ReactOS Portable Systems Group f6587f9c6b Fix comments in ksarm.h -- they must be C89.
svn path=/trunk/; revision=32324
2008-02-12 16:32:13 +00:00
ReactOS Portable Systems Group e4d660e795 Write initialization code in assembly -- we load the kernel stack from FreeLDR and jump to C code.
We now have a file for C-code initialization (no reason to use assembly).
We now have some basic TLB routines and intrinsics (not tested).
We also detect if we are running on V4 or V6, and set the TLB and ASID counts respectively.

svn path=/trunk/; revision=32323
2008-02-12 16:22:01 +00:00
Daniel Reimer 22cecfcc97 Beginnings to allow to translate all other Strings. Translators, PLEEASE wait until I am ready before you file Bugs, you can already start to translate, but do not post Bugreports until I am ready adding the last hidden ones.
Thanks to Johannes Anderwald for explaining me why it made more Problems than fix stuff to translate some strings and how to fix it.

svn path=/trunk/; revision=32322
2008-02-12 14:52:36 +00:00
Aleksey Bragin 1565a8ee43 - Kernel's entrypoint is called NtProcessStartup right now, for ReactOS. If this is to be changed, it should be changed for all archs, not only for ARM.
svn path=/trunk/; revision=32321
2008-02-12 13:34:33 +00:00
Johannes Anderwald dd25d44880 - pass the correct path to _strip_gcc_deffile
- automatically create directories for converted def files
- fixes auto-def file generation

svn path=/trunk/; revision=32320
2008-02-12 12:18:23 +00:00
Hervé Poussineau 17e045e905 Fix assertion is pci/fdo.c
svn path=/trunk/; revision=32319
2008-02-12 11:16:05 +00:00
ReactOS Portable Systems Group e5ed1afb69 We now define the cache and id registers in CP15 (C0 Opcode 0 and 1).
We now setup ARM cache information in the loader block.
We now allocate the kernel, interrupt and abort stacks, as well as the idle thread and process, and boot PRCB.
We now allocate the PCR and PDR pages.
We now send the command line to the kernel in the LoaderBlock's load options.

svn path=/trunk/; revision=32318
2008-02-12 09:41:21 +00:00
Daniel Reimer 121e0c645a Bug 3053: some slovak translations by Mario Kacmar, kario@szm.sk
Bug 3051: Italian resources update by Paolo Devoti, devotip@tiscali.it

svn path=/trunk/; revision=32317
2008-02-12 08:44:41 +00:00
ReactOS Portable Systems Group 3e0f927c2c Real fix, this time, hopefully.
svn path=/trunk/; revision=32316
2008-02-12 06:51:39 +00:00
ReactOS Portable Systems Group 1ad36042e5 Fix for x86 build.
svn path=/trunk/; revision=32315
2008-02-12 06:38:41 +00:00
ReactOS Portable Systems Group f537761b8d The kernel entrypoint is called KiSystemStartup, not NtProcessStartup.
On ARM, don't prepend underscore to the kernel entrypoint.
We now correctly jump into the kernel entrypoint, instead of random code!

svn path=/trunk/; revision=32314
2008-02-12 06:15:35 +00:00
ReactOS Portable Systems Group 358d95b0c1 Move the entrypoint and startup code in boot.s.
Write ksarm.h and kxarm.h headers, defining the ARM Assembly ABI.
Rewrite the ARM assembler files we currently have to match the ABI.

svn path=/trunk/; revision=32313
2008-02-12 05:55:12 +00:00
ReactOS Portable Systems Group 76a0229615 fixed math
svn path=/trunk/; revision=32312
2008-02-12 05:07:08 +00:00
ReactOS Portable Systems Group 52fa6c202f Better organize FreeLDR ARM files -- there are no more stubs now. We have the ReactOS kernel loader in loader.c, just like on x86, and the ARM FreeLDR HAL/Mach routines in macharm.c
svn path=/trunk/; revision=32311
2008-02-12 04:22:39 +00:00
ReactOS Portable Systems Group 41af47163d We now have the ARM defines/structures in stubs.c in FreeLDR in more appropriate kernel headers. This is just cleanup work.
svn path=/trunk/; revision=32310
2008-02-12 04:15:53 +00:00
ReactOS Portable Systems Group 40ecc5259a Fix the build.
Your friendly ARM ninjas apologize.

svn path=/trunk/; revision=32309
2008-02-12 03:06:06 +00:00
ReactOS Portable Systems Group 074f4a2517 Fix a couple of MMU bugs (incrementing the base address before writing the PTE and using the wrong start base address).
Virtual memory now works!
FreeLDR now boots into the kernel, at 0x80801000, in KiSystemStartup!

svn path=/trunk/; revision=32308
2008-02-11 23:47:43 +00:00
ReactOS Portable Systems Group 5fff0bd749 We define a region in FreeLDR where we store the initial TTB. We have to align it at a 16KB boundary, and ld loves to crash with such big alignment, so wee manually define it to load at 0x50000. Pray FreeLDR never gets that big (you'd think LD would warn if that section is overwriting others).
Wrote a guideline for what ArmPrepareForReactOS should do and defined the initial ARM loader block and extension.
Wrote the initial MMU code. It's totally busted but after 3 hours of debugging, it doesn't abort anymore!
Cleanups TBD.


svn path=/trunk/; revision=32307
2008-02-11 22:17:15 +00:00
ReactOS Portable Systems Group 5c6d974c05 FORCEINLINE is a lot more...forcefull... now ;-). Previous version didn't always inline as requested.
svn path=/trunk/; revision=32306
2008-02-11 22:13:35 +00:00