Commit graph

40965 commits

Author SHA1 Message Date
Daniel Reimer 35ebed7670 Update Rapps Links and add the two RosBE Addons.
svn path=/trunk/; revision=45559
2010-02-10 19:33:10 +00:00
Sir Richard 88d67c0d34 [NTOS]: Allocate and initialize color tables based on MmSecondaryColors (MiInitializeColorTables).
[NTOS]: These come after the PFN database, so modify the MmPfnAllocation to account for them.

svn path=/trunk/; revision=45558
2010-02-10 18:44:30 +00:00
Sir Richard 1711020a43 [NTOS]: Factor out SecondaryColor computations into MiComputeColorInformation.
[NTOS]: Fix SecondaryColor computations. If the KPCR has no deta, use the default colors of 8, not just 1. Also handle cases where there is more L2 cache than we'd like -- set the secondary colors to a maximum of 1024 in that case. Finally, if the colors are not a power of two, or there are not enough (due to a registry setting), use the default of 8.

svn path=/trunk/; revision=45557
2010-02-10 18:10:04 +00:00
Sir Richard 4e061e178b [NTOS]: MxGetNextPage is not platform-specific, so share it.
[NTOS]: Factor out computations of NP sizes and limits into MiComputeNonPagedPoolVa.
[NTOS]: Fix NP size/limit calculations to use the amount of FREE RAM, not the amount of INSTALLED RAM.
[NTOS]: Use Windows 2003's algorithm for NP size on machines with more than 512MB of FREE RAM.
[NTOS]: Partly handle the case of machines with NP over 128MB.

svn path=/trunk/; revision=45556
2010-02-10 17:42:07 +00:00
Dmitry Gorbachev b7b948cff5 Do not crash, use valid kernel PTE.
svn path=/trunk/; revision=45555
2010-02-10 13:56:54 +00:00
Michael Martin 3c1ec16123 [usb/usbehci]
- Remove WorkItem code as its not needed. UsbHub driver polls the hubs for device connects.
- Register USB Host Controller Device Interface during AddDevice.- Implement more URB's USB_DEVICE_DESCRIPTOR_TYPE, USB_CONFIGURATION_DESCRIPTOR_TYPE, URB_FUNCTION_SELECT_CONFIGURATION, URB_FUNCTION_CLASS_DEVICE/USB_DEVICE_CLASS_HUB.
- Implement returning generic UsbdDeviceHandle in URB struct.

svn path=/trunk/; revision=45554
2010-02-10 12:38:18 +00:00
Christoph von Wittich a884062bc9 [usb/usbehci]
fix typo

svn path=/trunk/; revision=45553
2010-02-10 12:25:35 +00:00
Michael Martin b028cb1e4e [usb/usbehci]
- Define Device and Configuration Descriptors for RootHub20.
- Queue all USB_SUBMIT_URBs and create a separate thread to handle them.
- For PNP START_DEVICE, Create the internal RootHub usb device and register usb hub device interface.
- Fill in direct call interface for USB_BUS_INTERFACE_USBDI_V2 and USB_BUS_INTERFACE_HUB_V5.
- Implement Direct Call Interface function GetExtendedHubInformation.
- Remove duplicate structures that are already defined in USB Headers. Some reorganization.

svn path=/trunk/; revision=45552
2010-02-10 12:21:23 +00:00
Dmitry Gorbachev 909e0c1b43 Update log2lines to ver. 2.1. Jan Roeloffzen, bug #4342.
svn path=/trunk/; revision=45551
2010-02-10 12:10:23 +00:00
Ged Murphy 9709c3dfb9 Found a leak fix patch from years ago
svn path=/trunk/; revision=45550
2010-02-10 08:24:34 +00:00
Sir Richard 8e0c1b2fb4 [NTOS]: Actually use calculated kernel stack size value.
[NTOS]: Define the template PTE/PDE statically, instead of doing it in code. It's faster, and saves us the trouble of not being able to use the template from point 0. Move the template setup into ARM3 instead of page.c.

svn path=/trunk/; revision=45549
2010-02-10 04:12:23 +00:00
Sir Richard 9f67c34652 [NTOS]: Allow registry configuration of large kernel stack size, with proper checks.
svn path=/trunk/; revision=45548
2010-02-10 03:59:17 +00:00
Sir Richard 3caee550bc [NTOS]: Combine ARM3 phase 0 and 1 even it means calling back into TurdMM for one function call.
[NTOS]: Separate out platform-specific parts of ARM3 initialization instead of having everything in an arch-specific file.
No functional code changes.

svn path=/trunk/; revision=45547
2010-02-10 02:00:56 +00:00
Cameron Gutman f11ee9cfaf - Merge r45531 and r45545 from aicom-network-branch
svn path=/trunk/; revision=45546
2010-02-10 00:55:58 +00:00
Sir Richard 3a6220a5f0 [NDK]: Add MMPDE structure for ARM.
svn path=/trunk/; revision=45543
2010-02-09 22:57:14 +00:00
Sir Richard bf310b5d1a [NTOS]: Implement new and correct MiAddressToPte, ToPde, ToPdeOffset, and MiPdeToAddres and MiAddressToPte on ARM. Remove deprecated ARM page definitions.
[NTOS]: Move HYPER_SPACE to 0xC0500000 since it must be on its own PDE. We need to revisit some FreeLDR Mm decisions later.
[NTOS]: Move certain arch-specific definitions from mm.h to the arch-specific mm.h
[NTOS]: Fix certain parts of ARM3 which made the assumption that a PDE shares the same structure as a PTE. This is true on all architectures except ARM. We now define a new MMPDE type specifically for PDEs. On x86 it is defined to MMPTE with no changes.

svn path=/trunk/; revision=45542
2010-02-09 22:56:21 +00:00
Eric Kohl 5095fd3746 Implement device location information override support and add the location override value for PS/2 mice. PS/2 keyboards be added next.
Please translate the location override string.

svn path=/trunk/; revision=45541
2010-02-09 22:54:02 +00:00
Sir Richard 29200c4aa6 [NTOS]: Setup the template PTE and PDE used on ARM.
svn path=/trunk/; revision=45540
2010-02-09 22:53:41 +00:00
Dmitry Gorbachev e815fe376b Fix REL build, part 2.
svn path=/trunk/; revision=45539
2010-02-09 20:21:54 +00:00
Dmitry Gorbachev cca78c7b11 Fix REL build.
svn path=/trunk/; revision=45538
2010-02-09 20:08:06 +00:00
Dmitry Gorbachev d4cca547fc Demote "may be used uninitialized" errors into warnings again.
svn path=/trunk/; revision=45536
2010-02-09 19:02:56 +00:00
Colin Finck 75538f4c0a The big RosBE 1.5 compatibility patch. You will need RosBE 1.5 from this point!
- Set the minimum GCC version to 4.4.0 and minimum Binutils version to 20091016.
- Remove the -fno-unit-at-a-time hacks.
- Remove dgorbachev's temporary hacks for user-mode C++ applications.
- Merge ntoskrnl's "precomp.h" and "ntoskrnl.h" again, the PCH issues have been fixed.
- Use our "ofmt_stub.a" to be compatible with newer MinGW Runtime versions.
- Use LD's new -exclude-all-symbols option to not auto-export all symbols in case no DEF file or __declspec(dllexport) was specified.
  We used to patch our LD version to work around this problem.
- Use LD's --start-group and --end-group parameters to allow a more flexible linking order.
- Use GCC's -fno-set-stack-executable for amd64 and i386 targets to disable adding the __enable_execute_stack code.
- Change the makefile's name to "makefile-$(ARCH).auto" for all architectures.
- Remove some -Wno-error flags.

See issue #4810 for more details.

svn path=/trunk/; revision=45535
2010-02-09 18:14:58 +00:00
evb 1bfa0a72c8 - Make KeFlushProcessTb work. Since no MPCore support, CPU TLB is flushed instead. Maybe should use ASIDs later.
svn path=/trunk/; revision=45534
2010-02-09 18:06:26 +00:00
Benedikt Freisen c7fe125d08 [paint] fix rectangular selection tool
svn path=/trunk/; revision=45533
2010-02-09 18:06:18 +00:00
evb 8aff466da3 - Fix wrong initialization of different modes and stacks.
svn path=/trunk/; revision=45532
2010-02-09 18:05:01 +00:00
Johannes Anderwald 05051294e4 [DSOUND_NEW]
- Add more parameter checks
- Implement a few more functions for the primary sound buffer

svn path=/trunk/; revision=45530
2010-02-09 14:24:50 +00:00
Johannes Anderwald d1a6561178 [DSOUND_NEW]
- Implement getting volume, volume pan, and frequency for secondary sound buffer
- Semi-stub setting volume, volume pan and frequency for secondary...

svn path=/trunk/; revision=45529
2010-02-09 13:14:19 +00:00
Johannes Anderwald a12bfcf5d5 [DSOUND_NEW]
- Implement starting / stopping primary sound buffer
- Implement retrieving capabilities for secondary sound buffer
- Import sound mixing routines from wine, not yet used

svn path=/trunk/; revision=45527
2010-02-09 12:03:59 +00:00
Sir Richard 8c8041b1d6 [FREELDR]: Use WinLDR-style booting exclusively for ARM. Remove thousands of lines of old code where we basically did the same thing.
[FREELDR]: Build WinLDR for ARM too, and implement the required portability functions to get it working. Don't build "ros-style" loading on ARM.
[FREELDR]: Redo from scratch the entire paging setup for ARM. Instead of using 20MB of physical RAM, we now only use 1MB that's passed on to the kernel.
[FREELDR]: Fix loads of bugs in the ARM loader code (ha-ha!).
[FREELDR]: Cleanup compiler and linker flags in the rbuild files.
[ARMLLB]: Remove all deprecated video machine routines that are not used anymore.
If all went well, the ARM port should now boot on Versatile platforms up until the ARM3 initialization code.

svn path=/trunk/; revision=45526
2010-02-09 03:10:07 +00:00
Sir Richard 7cd39aa34b [MISC]: Build fixes to sync up with latest changes.
[SETUPLDR]: Do not build on ARM. On a side note, I offer a bountry for "if ARCH != ARM" support in .rbuild files, instead of only allowing ==.

svn path=/trunk/; revision=45525
2010-02-09 03:05:49 +00:00
Sir Richard ba9fe881da [FREELDR]: Remove C++ style indirected "UI" component from FreeLDR ARM, for several reasons that ought to be considered on x86 too:
- It redraws the screen in two different ways (zero memory and character-by-character fill) over 15 times for a single boot. You notice these things on a little ARM chip!
    - It keeps coping data from/to an "off-screen buffer" way too much, instead of only when the video needs to be synced.
    - It makes assumptions about all Video Buffers supporting Character-Mode VGA.
    - It can be configured to draw cyan/yellow ponies, instead of a normal NT boot menu.
    The ARM build now uses a "directui.c" implementation which fixes all these issues and is efficient and to the point. It presents a normal Windows boot selection menu on ARM.
[FREELDR]: Do not build any of the video routines, or the UI routines, on ARM.

svn path=/trunk/; revision=45524
2010-02-09 02:53:45 +00:00
Sir Richard f0a8153aec [FREELDR]: No Linux support for ARM, no RS232 support for ARM, and no complex debug infrastructure for ARM either.
svn path=/trunk/; revision=45523
2010-02-09 02:38:23 +00:00
Timo Kreuzer 2e97a01a5d add setjmp/longjmp to libcntpr, just like in ms sdks
svn path=/trunk/; revision=45522
2010-02-09 02:34:42 +00:00
Sir Richard 85446d50ca [FREELDR]: Do not build Disk/Partition support for ARM, we use ram disks.
svn path=/trunk/; revision=45521
2010-02-09 02:33:31 +00:00
Sir Richard 7d76dde312 [FREELDR]: Do not build EXT2, ISO or NTFS support for ARM targets.
svn path=/trunk/; revision=45520
2010-02-09 02:32:59 +00:00
Sir Richard 9eea228a7d [FREELDR]: The WinLDR code forgot to update the File Path of boot driver entries from PA to VA as well, not just the registry path. It also tried to touch the PA LoaderBlock right after enabling the MMU. It should touch the VA LoaderBlock instead, since there is no guarantee that the address has been identity mapped (and hence the PA address interpreted as a VA address by the MMU is bogus).
svn path=/trunk/; revision=45519
2010-02-09 02:26:46 +00:00
evb 8e6d54f4b8 - New ARM HAL after 2 nights in the company of a madman.
- Many fixes, more implemented routines, support for ARMv7.
- Some Linux code, marked as GPL, from ARM Ltd in cache.s. All OS use this code.

svn path=/trunk/; revision=45518
2010-02-09 02:26:28 +00:00
Sir Richard 62cb7586f3 [FREELDR]: The hack to set pages from 0x100 to 0x1FF as busy so that the heap allocator wouldn't use them always restored the pages back to Free (since they usually were free on x86). However, if the pages were already being used in the first place, this made them appear free and corrupted existing memory. Fixed the hack so that it restores the previous state of the memory pages.
svn path=/trunk/; revision=45517
2010-02-09 02:22:08 +00:00
Sir Richard f44cf3f702 [NDK]: Use new ARMv6 PTE structures.
svn path=/trunk/; revision=45516
2010-02-09 02:14:58 +00:00
Sir Richard 92f6dfd7d4 [NTOS]: Tabula rasa (clean slate) on the old-MM page routines for ARM. Get rid of all of them for now.
[NTOS]: Implement MmInitGlobalKernelPageDirectory as the first ARM page function in the new file.
That's it for the kernel.

svn path=/trunk/; revision=45515
2010-02-09 02:14:20 +00:00
Sir Richard 9a43c209d4 [NTOS]: All calls to DbgPrint will go to DbgPrintEarly for now.
[NTOS]: More header fixes to match new definitions.

svn path=/trunk/; revision=45514
2010-02-09 02:12:27 +00:00
Sir Richard 16ab546411 [NTOS]: Make system startup match x86 code as closely as possible, instead of mixing MIPS/PPC code. Only rip out parts that are obviously x86-specific. Also fix code to use new KPCR definitions.
[NTOS]: Implement a DbgPrintEarly function that directly uses KDCOM to print to the serial console, instead of going through the Debug Service Interrupt.

svn path=/trunk/; revision=45513
2010-02-09 02:11:18 +00:00
Sir Richard 6995f3fca6 [NTOS]: Update code to use new KPCR structure.
[NTOS]: Make all trap code currently spin forever, because it has not been reviewed yet.

svn path=/trunk/; revision=45512
2010-02-09 02:09:34 +00:00
Sir Richard ba3bc4340e [ARMDDK]: Use the same KPCR structure on ARM as on x86.
[ARMDDK]: Use the same addresses for KPCR and KUSER_SHARED_DATA on ARM as on x86. On ARM however, since there are no "segments", the KPCR is also mapped in user-mode, read-only, to have a static structure that can point to the current TEB.

svn path=/trunk/; revision=45511
2010-02-09 02:08:24 +00:00
Sir Richard 4deb6d8bf4 [ARM DDK]: Use the closest possible approximation to the x86 KPCR/KPRCB (in fact, the public KPCR is identical, just the KIPCR is different, internally), instead of a mashup of PPC and MIPS structures.
svn path=/trunk/; revision=45510
2010-02-09 02:06:29 +00:00
Sir Richard bf39d09670 [NTOS]: Sync up KiDispatchException with x86 code (and going back to C comment formatting).
svn path=/trunk/; revision=45509
2010-02-09 02:00:52 +00:00
Sir Richard d685272dc0 [NTOS]: Get rid of fixed TLB entries on ARM, I don't think that idea makes sense (unlike IA64 or MIPS where they are lot more flexible), since they only allow 1MB sections, not pages.
svn path=/trunk/; revision=45508
2010-02-09 02:00:15 +00:00
Sir Richard 60fd785e82 [NTOS]: Forgot to setup an IRQ stack, the kernel was working by magic since in previous incarnations of the ARM port, 0xFFFFyyyy was mapped, so a stack of 0 worked (going downwards).
[NTOS]: Now FreeLDR just calls the KiSystemStartup routine correctly, without any "magic", so fix the code to use a1 instead of a2 (argument 1/2).

svn path=/trunk/; revision=45507
2010-02-09 01:54:14 +00:00
Sir Richard acb344ee2a [ARM SDK]: Use real Versatile base addresses instead of the old hacked FreeLDR base addresses.
svn path=/trunk/; revision=45506
2010-02-09 01:47:54 +00:00
Sir Richard 68410c584a [ARMLLB]: PutChar should be a UCHAR routine, this way we can print characters above 127 (extended ASCII). This is needed for the progress bar, for example.
svn path=/trunk/; revision=45505
2010-02-09 01:46:01 +00:00