Author: tkreuzer Date: Thu Dec 31 22:23:01 2009 New Revision: 44835
URL: http://svn.reactos.org/svn/reactos?rev=44835&view=rev Log: [HAL] - Move the rest from halamd64 to halx86
Added: branches/ros-amd64-bringup/reactos/hal/halx86/generic/amd64/halinit.c - copied unchanged from r44833, branches/ros-amd64-bringup/reactos/hal/halamd64/generic/halinit.c branches/ros-amd64-bringup/reactos/hal/halx86/generic/amd64/misc.c - copied unchanged from r44833, branches/ros-amd64-bringup/reactos/hal/halamd64/generic/misc.c branches/ros-amd64-bringup/reactos/hal/halx86/generic/amd64/pic.c - copied unchanged from r44833, branches/ros-amd64-bringup/reactos/hal/halamd64/generic/pic.c branches/ros-amd64-bringup/reactos/hal/halx86/generic/amd64/usage.c - copied unchanged from r44833, branches/ros-amd64-bringup/reactos/hal/halamd64/generic/usage.c branches/ros-amd64-bringup/reactos/hal/halx86/mp/amd64/ (with props) branches/ros-amd64-bringup/reactos/hal/halx86/mp/amd64/mps.S - copied unchanged from r44833, branches/ros-amd64-bringup/reactos/hal/halamd64/generic/mps.S branches/ros-amd64-bringup/reactos/hal/halx86/mp/i386/ (with props) branches/ros-amd64-bringup/reactos/hal/halx86/mp/i386/mps.S - copied unchanged from r44833, branches/ros-amd64-bringup/reactos/hal/halx86/mp/mps.S branches/ros-amd64-bringup/reactos/hal/halx86/mp/i386/mpsboot.asm - copied unchanged from r44833, branches/ros-amd64-bringup/reactos/hal/halx86/mp/mpsboot.asm branches/ros-amd64-bringup/reactos/hal/halx86/mp/i386/spinlock.c - copied unchanged from r44833, branches/ros-amd64-bringup/reactos/hal/halx86/mp/spinlock.c Removed: branches/ros-amd64-bringup/reactos/hal/halamd64/ branches/ros-amd64-bringup/reactos/hal/halx86/mp/mps.S branches/ros-amd64-bringup/reactos/hal/halx86/mp/mpsboot.asm branches/ros-amd64-bringup/reactos/hal/halx86/mp/spinlock.c Modified: branches/ros-amd64-bringup/reactos/hal/hal.rbuild branches/ros-amd64-bringup/reactos/hal/halx86/hal_generic.rbuild branches/ros-amd64-bringup/reactos/hal/halx86/halamd64.rbuild branches/ros-amd64-bringup/reactos/hal/halx86/halmps.rbuild
Modified: branches/ros-amd64-bringup/reactos/hal/hal.rbuild URL: http://svn.reactos.org/svn/reactos/branches/ros-amd64-bringup/reactos/hal/ha... ============================================================================== --- branches/ros-amd64-bringup/reactos/hal/hal.rbuild [iso-8859-1] (original) +++ branches/ros-amd64-bringup/reactos/hal/hal.rbuild [iso-8859-1] Thu Dec 31 22:23:01 2009 @@ -15,9 +15,4 @@ <xi:include href="halarm/directory.rbuild" /> </directory> </if> - <if property="ARCH" value="amd64"> - <directory name="halamd64"> - <xi:include href="halamd64/directory.rbuild" /> - </directory> - </if> </group>
Modified: branches/ros-amd64-bringup/reactos/hal/halx86/hal_generic.rbuild URL: http://svn.reactos.org/svn/reactos/branches/ros-amd64-bringup/reactos/hal/ha... ============================================================================== --- branches/ros-amd64-bringup/reactos/hal/halx86/hal_generic.rbuild [iso-8859-1] (original) +++ branches/ros-amd64-bringup/reactos/hal/halx86/hal_generic.rbuild [iso-8859-1] Thu Dec 31 22:23:01 2009 @@ -38,8 +38,12 @@ </if> <if property="ARCH" value="amd64"> <directory name="amd64"> + <file>halinit.c</file> <file>irq.s</file> + <file>misc.c</file> + <file>pic.c</file> <file>systimer.S</file> + <file>usage.c</file> </directory> </if> </directory>
Modified: branches/ros-amd64-bringup/reactos/hal/halx86/halamd64.rbuild URL: http://svn.reactos.org/svn/reactos/branches/ros-amd64-bringup/reactos/hal/ha... ============================================================================== --- branches/ros-amd64-bringup/reactos/hal/halx86/halamd64.rbuild [iso-8859-1] (original) +++ branches/ros-amd64-bringup/reactos/hal/halx86/halamd64.rbuild [iso-8859-1] Thu Dec 31 22:23:01 2009 @@ -7,7 +7,6 @@ <include base="ntoskrnl">include</include> <define name="_DISABLE_TIDENTS" /> <define name="_NTHAL_" /> - <library>hal_generic_amd64</library> <library>hal_generic</library> <library>hal_generic_up</library> <library>ntoskrnl</library> @@ -17,7 +16,9 @@ <file>halup.rc</file> </directory>
- <!--directory name="mp"> - <file>apic.c</file> - </directory --> + <directory name="mp"> + <directory name="amd64"> + <file>mps.S</file> + </directory> + </directory> </module>
Modified: branches/ros-amd64-bringup/reactos/hal/halx86/halmps.rbuild URL: http://svn.reactos.org/svn/reactos/branches/ros-amd64-bringup/reactos/hal/ha... ============================================================================== --- branches/ros-amd64-bringup/reactos/hal/halx86/halmps.rbuild [iso-8859-1] (original) +++ branches/ros-amd64-bringup/reactos/hal/halx86/halmps.rbuild [iso-8859-1] Thu Dec 31 22:23:01 2009 @@ -16,12 +16,14 @@ <file>ioapic.c</file> <file>ipi_mp.c</file> <file>mpconfig.c</file> - <file>mps.S</file> - <file>mpsboot.asm</file> <file>mpsirql.c</file> <file>processor_mp.c</file> - <file>spinlock.c</file> <file>halmp.rc</file> + <directory name="i386"> + <file>mps.S</file> + <file>mpsboot.asm</file> + <file>spinlock.c</file> + </directory> </directory> </module> </group>
Propchange: branches/ros-amd64-bringup/reactos/hal/halx86/mp/amd64/ ------------------------------------------------------------------------------ --- bugtraq:logregex (added) +++ bugtraq:logregex Thu Dec 31 22:23:01 2009 @@ -1,0 +1,2 @@ +([Ii]ssue|[Bb]ug)s? #?(\d+)(,? ?#?(\d+))*(,? ?(and |or )?#?(\d+))? +(\d+)
Propchange: branches/ros-amd64-bringup/reactos/hal/halx86/mp/amd64/ ------------------------------------------------------------------------------ bugtraq:message = See issue #%BUGID% for more details.
Propchange: branches/ros-amd64-bringup/reactos/hal/halx86/mp/amd64/ ------------------------------------------------------------------------------ bugtraq:url = http://www.reactos.org/bugzilla/show_bug.cgi?id=%BUGID%
Propchange: branches/ros-amd64-bringup/reactos/hal/halx86/mp/amd64/ ------------------------------------------------------------------------------ tsvn:logminsize = 10
Propchange: branches/ros-amd64-bringup/reactos/hal/halx86/mp/i386/ ------------------------------------------------------------------------------ --- bugtraq:logregex (added) +++ bugtraq:logregex Thu Dec 31 22:23:01 2009 @@ -1,0 +1,2 @@ +([Ii]ssue|[Bb]ug)s? #?(\d+)(,? ?#?(\d+))*(,? ?(and |or )?#?(\d+))? +(\d+)
Propchange: branches/ros-amd64-bringup/reactos/hal/halx86/mp/i386/ ------------------------------------------------------------------------------ bugtraq:message = See issue #%BUGID% for more details.
Propchange: branches/ros-amd64-bringup/reactos/hal/halx86/mp/i386/ ------------------------------------------------------------------------------ bugtraq:url = http://www.reactos.org/bugzilla/show_bug.cgi?id=%BUGID%
Propchange: branches/ros-amd64-bringup/reactos/hal/halx86/mp/i386/ ------------------------------------------------------------------------------ tsvn:logminsize = 10
Removed: branches/ros-amd64-bringup/reactos/hal/halx86/mp/mps.S URL: http://svn.reactos.org/svn/reactos/branches/ros-amd64-bringup/reactos/hal/ha... ============================================================================== --- branches/ros-amd64-bringup/reactos/hal/halx86/mp/mps.S [iso-8859-1] (original) +++ branches/ros-amd64-bringup/reactos/hal/halx86/mp/mps.S (removed) @@ -1,109 +1,0 @@ -/* $Id$ - * - * COPYRIGHT: See COPYING in the top level directory - * PROJECT: ReactOS kernel - * FILE: ntoskrnl/hal/x86/mps.S - * PURPOSE: Intel MultiProcessor specification support - * PROGRAMMER: Casper S. Hornstrup (chorns@users.sourceforge.net) - * UPDATE HISTORY: - * Created 12/04/2001 - */ - -/* INCLUDES ******************************************************************/ - -#include <ndk/asm.h> - -/* FUNCTIONS *****************************************************************/ - -#define BEFORE \ - cld; \ - pusha; \ - pushl %ds; \ - pushl %es; \ - pushl %fs; \ - pushl %gs; \ - movl $(KGDT_R0_DATA), %eax; \ - movl %eax, %ds; \ - movl %eax, %es; \ - movl %eax, %gs; \ - movl $(KGDT_R0_PCR), %eax; \ - movl %eax, %fs; - -#define AFTER \ - popl %gs; \ - popl %fs; \ - popl %es; \ - popl %ds; \ - popa; - -.global _MpsIpiInterrupt -_MpsIpiInterrupt: - /* Save registers */ - BEFORE - - /* Call the C handler */ - call _MpsIpiHandler - - /* Return to the caller */ - AFTER - iret - - -.globl _MpsErrorInterrupt -_MpsErrorInterrupt: - /* Save registers */ - BEFORE - - /* Call the C handler */ - call _MpsErrorHandler - - /* Return to the caller */ - AFTER - iret - - -.globl _MpsSpuriousInterrupt -_MpsSpuriousInterrupt: - /* Save registers */ - BEFORE - - /* Call the C handler */ - call _MpsSpuriousHandler - - /* Return to the caller */ - AFTER - iret - -.global _MpsTimerInterrupt -_MpsTimerInterrupt: - cld - pusha - movl $0xef,%ebx - pushl %ds - pushl %es - pushl %fs - pushl %gs - movl $0xceafbeef,%eax - pushl %eax - movl $(KGDT_R0_DATA),%eax - movl %eax,%ds - movl %eax,%es - movl %eax,%gs - movl $(KGDT_R0_PCR),%eax - movl %eax,%fs - pushl %esp - pushl %ebx - call _MpsTimerHandler - popl %eax - popl %eax - popl %eax - popl %gs - popl %fs - popl %es - popl %ds - popa - iret - - - -/* EOF */
Removed: branches/ros-amd64-bringup/reactos/hal/halx86/mp/mpsboot.asm URL: http://svn.reactos.org/svn/reactos/branches/ros-amd64-bringup/reactos/hal/ha... ============================================================================== --- branches/ros-amd64-bringup/reactos/hal/halx86/mp/mpsboot.asm [iso-8859-1] (original) +++ branches/ros-amd64-bringup/reactos/hal/halx86/mp/mpsboot.asm (removed) @@ -1,118 +1,0 @@ -; -; COPYRIGHT: See COPYING in the top level directory -; PROJECT: ReactOS kernel -; FILE: ntoskrnl/hal/x86/mpsboot.c -; PURPOSE: Bootstrap code for application processors -; PROGRAMMER: Casper S. Hornstrup (chorns@users.sourceforge.net) -; UPDATE HISTORY: -; Created 12/04/2001 -; - -; -; Memory map at this stage is: -; 0x2000 Location of our stack -; 0x3000 Startup code for the APs (this code) -; - -; -; Magic value to be put in EAX when multiboot.S is called as part of the -; application processor initialization process -; -AP_MAGIC equ 12481020h - - -X86_CR4_PAE equ 00000020h - -; -; Segment selectors -; -%define KERNEL_CS (0x8) -%define KERNEL_DS (0x10) - -section .text - -global _APstart -global _APend - -; 16 bit code -BITS 16 - -_APstart: - cli ; Just in case - - xor ax, ax - mov ds, ax - mov ss, ax - - mov eax, 3000h + APgdt - _APstart - lgdt [eax] - - mov eax, [2004h] ; Set the page directory - mov cr3, eax - - mov eax, [200ch] - cmp eax,0 - je NoPae - - mov eax,cr4 - or eax,X86_CR4_PAE - mov cr4,eax - -NoPae: - - mov eax, cr0 - or eax, 80010001h ; Turn on protected mode, paging and write protection - mov cr0, eax - - db 0eah - dw 3000h + flush - _APstart, KERNEL_CS - -; 32 bit code -BITS 32 - -flush: - mov ax, KERNEL_DS - mov ds, ax - mov es, ax - mov fs, ax - mov gs, ax - mov ss, ax - - ; Setup a stack for the AP - mov eax, 2000h - mov eax, [eax] - mov esp, eax - - ; Jump to start of the kernel with AP magic in ecx - mov ecx, AP_MAGIC - mov eax,[2008h] - jmp eax - - ; Never get here - - -; Temporary GDT descriptor for the APs - -APgdt: -; Limit - dw (3*8)-1 -; Base - dd 3000h + gdt - _APstart - -gdt: - dw 0x0 ; Null descriptor - dw 0x0 - dw 0x0 - dw 0x0 - - dw 0xffff ; Kernel code descriptor - dw 0x0000 - dw 0x9a00 - dw 0x00cf - - dw 0xffff ; Kernel data descriptor - dw 0x0000 - dw 0x9200 - dw 0x00cf - -_APend:
Removed: branches/ros-amd64-bringup/reactos/hal/halx86/mp/spinlock.c URL: http://svn.reactos.org/svn/reactos/branches/ros-amd64-bringup/reactos/hal/ha... ============================================================================== --- branches/ros-amd64-bringup/reactos/hal/halx86/mp/spinlock.c [iso-8859-1] (original) +++ branches/ros-amd64-bringup/reactos/hal/halx86/mp/spinlock.c (removed) @@ -1,201 +1,0 @@ -/* - * COPYRIGHT: See COPYING in the top level directory - * PROJECT: ReactOS kernel - * FILE: ntoskrnl/hal/x86/spinlock.c - * PURPOSE: Implements spinlocks - * PROGRAMMER: David Welch (welch@cwcom.net) - * Eric Kohl (ekohl@rz-online.de) - * UPDATE HISTORY: - * 09/06/2000 Created - */ - -/* - * NOTE: On a uniprocessor machine spinlocks are implemented by raising - * the irq level - */ - -/* INCLUDES ****************************************************************/ - -#include <hal.h> -#define NDEBUG -#include <debug.h> - -/* Hmm, needed for KDBG := 1. Why? */ -#undef KeGetCurrentIrql - -/* FUNCTIONS ***************************************************************/ - -#undef KeAcquireSpinLock -VOID NTAPI -KeAcquireSpinLock ( - PKSPIN_LOCK SpinLock, - PKIRQL OldIrql - ) -/* - * FUNCTION: Acquires a spinlock - * ARGUMENTS: - * SpinLock = Spinlock to acquire - * OldIrql (OUT) = Caller supplied storage for the previous irql - */ -{ - *OldIrql = KfAcquireSpinLock(SpinLock); -} - -KIRQL FASTCALL -KeAcquireSpinLockRaiseToSynch ( - PKSPIN_LOCK SpinLock - ) -{ - KIRQL OldIrql; - - OldIrql = KfRaiseIrql(CLOCK2_LEVEL); - KiAcquireSpinLock(SpinLock); - - return OldIrql; -} - -#undef KeReleaseSpinLock -VOID NTAPI -KeReleaseSpinLock ( - PKSPIN_LOCK SpinLock, - KIRQL NewIrql - ) -/* - * FUNCTION: Releases a spinlock - * ARGUMENTS: - * SpinLock = Spinlock to release - * NewIrql = Irql level before acquiring the spinlock - */ -{ - KfReleaseSpinLock(SpinLock, NewIrql); -} - -LOGICAL -FASTCALL -KeTryToAcquireQueuedSpinLock( - KSPIN_LOCK_QUEUE_NUMBER LockNumber, - PKIRQL OldIrql) -{ - UNIMPLEMENTED; - - return FALSE; -} - - -BOOLEAN -FASTCALL -KeTryToAcquireQueuedSpinLockRaiseToSynch( - KSPIN_LOCK_QUEUE_NUMBER LockNumber, - PKIRQL OldIrql) -{ - UNIMPLEMENTED; - - return FALSE; -} - -KIRQL FASTCALL -KfAcquireSpinLock ( - PKSPIN_LOCK SpinLock - ) -{ - KIRQL OldIrql; - - ASSERT(KeGetCurrentIrql() <= DISPATCH_LEVEL); - - OldIrql = KfRaiseIrql(DISPATCH_LEVEL); - KiAcquireSpinLock(SpinLock); - - return OldIrql; -} - -VOID FASTCALL -KfReleaseSpinLock ( - PKSPIN_LOCK SpinLock, - KIRQL NewIrql - ) -/* - * FUNCTION: Releases a spinlock - * ARGUMENTS: - * SpinLock = Spinlock to release - * NewIrql = Irql level before acquiring the spinlock - */ -{ - ASSERT(KeGetCurrentIrql() == DISPATCH_LEVEL || KeGetCurrentIrql() == SYNCH_LEVEL); - KiReleaseSpinLock(SpinLock); - KfLowerIrql(NewIrql); -} - - -/* - * @unimplemented - */ -VOID -FASTCALL -KeAcquireInStackQueuedSpinLock( - IN PKSPIN_LOCK SpinLock, - IN PKLOCK_QUEUE_HANDLE LockHandle - ) -{ - UNIMPLEMENTED; -} - -/* - * @unimplemented - */ -VOID -FASTCALL -KeAcquireInStackQueuedSpinLockRaiseToSynch( - IN PKSPIN_LOCK SpinLock, - IN PKLOCK_QUEUE_HANDLE LockHandle - ) -{ - UNIMPLEMENTED; -} - - -/* - * @unimplemented - */ -VOID -FASTCALL -KeReleaseInStackQueuedSpinLock( - IN PKLOCK_QUEUE_HANDLE LockHandle - ) -{ - UNIMPLEMENTED; -} - -/* - * @unimplemented - */ -KIRQL -FASTCALL -KeAcquireQueuedSpinLock(IN KSPIN_LOCK_QUEUE_NUMBER Number) -{ - UNIMPLEMENTED; - return 0; -} - -/* - * @unimplemented - */ -KIRQL -FASTCALL -KeAcquireQueuedSpinLockRaiseToSynch(IN KSPIN_LOCK_QUEUE_NUMBER LockNumber) -{ - UNIMPLEMENTED; - return 0; -} - -/* - * @unimplemented - */ -VOID -FASTCALL -KeReleaseQueuedSpinLock(IN KSPIN_LOCK_QUEUE_NUMBER Number, - IN KIRQL OldIrql) -{ - UNIMPLEMENTED; -} - -/* EOF */