summaryrefslogtreecommitdiffstats
path: root/src/kernel/start.S
Commit message (Collapse)AuthorAgeFilesLines
* pore_gen_cpuregMark Wenning2012-11-071-5/+6
| | | | | | | | | Change-Id: Ic5cb0817118bf0de7d706124708e5b8551ba4258 RTC: 41425 Reviewed-on: http://gfw160.austin.ibm.com:8080/gerrit/1899 Tested-by: Jenkins Server Reviewed-by: Van H. Lee <vanlee@us.ibm.com> Reviewed-by: A. Patrick Williams III <iawillia@us.ibm.com>
* Terminate Immediate Structure defintionMissy Connell2012-10-241-0/+10
| | | | | | | | | | - Add include files into the fsp.tar Change-Id: I12a50f7e09f70b1bc6acf436d896b6f3747a7507 RTC:50578 Reviewed-on: http://gfw160.austin.ibm.com:8080/gerrit/2115 Tested-by: Jenkins Server Reviewed-by: A. Patrick Williams III <iawillia@us.ibm.com>
* Memory Leak task_endBill Schwartz2012-10-121-1/+1
| | | | | | | | Change-Id: Idb7a2d8d72a55f644efd0b2548eca5df5d062e6d RTC: 47491 Reviewed-on: http://gfw160.austin.ibm.com:8080/gerrit/2011 Tested-by: Jenkins Server Reviewed-by: A. Patrick Williams III <iawillia@us.ibm.com>
* Fixes for winkle state.Patrick Williams2012-09-211-1/+1
| | | | | | | | | | | | | | | | | | | The memory profiling tools sometimes encountered a condition where the kernel stack was becoming corrupted. I tracked it down to the winkle code storing the winkle-save state at the wrong end of the stack. Moving the winkle-save area to the bottom of the stack, which is where I originally intended it to go. Also noticed that the task issuing the winkle was in "running" state while waiting for the cores to come out of winkle. Ensure that the kernel updates the task state with a non-running status while we are waiting for winkle to complete. Change-Id: I07a56ea6f24cbc09362f9227d81915da5bc9f148 Reviewed-on: http://gfw160.austin.ibm.com:8080/gerrit/1737 Tested-by: Jenkins Server Reviewed-by: Douglas R. Gilbert <dgilbert@us.ibm.com> Reviewed-by: Daniel M. Crowell <dcrowell@us.ibm.com>
* Nap instruction sometimes executed with wrong permissions.Patrick Williams2012-09-061-57/+44
| | | | | | | | | | | | | | | | | | | When executing the nap instruction, all thread state can be lost. This was causing r0 to be lost, which contained the system-call number for the idle thread to request permission to execute nap and as a result 'task-yield' was executed instead of 'cpu-nap' after the idle thread took its first nap. Re-arranged the sreset code that handles nap-wakeup to deal with thread-state being lost when entering nap and instead using the previously saved task-state from the 'cpu-nap' system call. Change-Id: Id7468a8577c4d7b273b23bc97e7dd040555e7b67 Reviewed-on: http://gfw160.austin.ibm.com:8080/gerrit/1567 Tested-by: Jenkins Server Reviewed-by: A. Patrick Williams III <iawillia@us.ibm.com>
* Allow processors on logical nodes != 0.Patrick Williams2012-09-061-9/+18
| | | | | | | | | | | | | | | | | Created per-node arrays of CPU objects rather than a single array for the entire system. These are created dynamically as CPUs are enabled. Also disabled support for P7 due to the PIR layout being different and hence would have needed two different sets of assembly code. We have been running exclusively on the P8 Mambo model for a while. RTC: 42815 Change-Id: Ib92de8a7c07c2e700a3b7f0c03c64d484b447ca2 Reviewed-on: http://gfw160.austin.ibm.com:8080/gerrit/1630 Tested-by: Jenkins Server Reviewed-by: Daniel M. Crowell <dcrowell@us.ibm.com> Reviewed-by: A. Patrick Williams III <iawillia@us.ibm.com>
* Set "high" thread priority as 2 rather than 3.Patrick Williams2012-09-051-4/+4
| | | | | | | | | | | | | | | | | | | | | The Power processor has instructions of the form 'or a,a,a' that allow code to change the priority of a hw-thread relative to the others. We initially used 'or 1,1,1' as low priority and 'or 3,3,3' as high priority. This is used in, for instance, spinlocks to reduce the priority of a hw-thread while waiting for another thread to perform an activity. This code originally came from HAL. In reading the Power ISA closer I realized that 'or 3,3,3' has no effect when in user-space code, which means that a spinlock-like effect in user code is going to end up with the thread stuck at low priority until the next context switch. To prevent this we are going to change from 1/3 to 1/2 as the priority levels. Change-Id: I60ee866cde37499106f5e1e1d68a0b5ddeedf403 Reviewed-on: http://gfw160.austin.ibm.com:8080/gerrit/1569 Tested-by: Jenkins Server Reviewed-by: A. Patrick Williams III <iawillia@us.ibm.com>
* Write scratch register in start_payload / shutdown.Patrick Williams2012-09-041-4/+26
| | | | | | | | | | Change-Id: I47a8ad7914c6833c476a7944be5d352f45467f3a RTC: 47725 Reviewed-on: http://gfw160.austin.ibm.com:8080/gerrit/1646 Tested-by: Jenkins Server Reviewed-by: Mark W. Wenning <wenning@us.ibm.com> Reviewed-by: Douglas R. Gilbert <dgilbert@us.ibm.com> Reviewed-by: A. Patrick Williams III <iawillia@us.ibm.com>
* Ensure PHYP thread order is correct.Patrick Williams2012-08-221-64/+0
| | | | | | | | | | | * Choose thread with the lowest PIR as the last to enter payload. * Use HRMOR update process from Murano Book IV. RTC: 43166 Change-Id: I629f4a55cba1967a13c31a16095697b7142ca407 Reviewed-on: http://gfw160.austin.ibm.com:8080/gerrit/1529 Tested-by: Jenkins Server Reviewed-by: A. Patrick Williams III <iawillia@us.ibm.com>
* Support for master winkle.Patrick Williams2012-08-101-60/+121
| | | | | | | | | RTC: 44730 Change-Id: Ifaeecc659e1bfd8ded4744dc591fc993471519ba Reviewed-on: http://gfw160.austin.ibm.com:8080/gerrit/1471 Tested-by: Jenkins Server Reviewed-by: Mark W. Wenning <wenning@us.ibm.com> Reviewed-by: A. Patrick Williams III <iawillia@us.ibm.com>
* Execute 'doze' in idle loop.Patrick Williams2012-07-281-6/+73
| | | | | | | | | Change-Id: Ifd611129c2d7173b5e0dec36c870e06a4d851009 Reviewed-on: http://gfw160.austin.ibm.com:8080/gerrit/1384 Tested-by: Jenkins Server Reviewed-by: Douglas R. Gilbert <dgilbert@us.ibm.com> Reviewed-by: Daniel M. Crowell <dcrowell@us.ibm.com> Reviewed-by: A. Patrick Williams III <iawillia@us.ibm.com>
* cpu_spr_value syscall for SLW image build.Patrick Williams2012-07-181-22/+35
| | | | | | | | | | | | Task 44887 Change-Id: If87b6e80b974bb4cbff13844d8a3f055a17282d2 Reviewed-on: http://gfw160.austin.ibm.com:8080/gerrit/1378 Tested-by: Jenkins Server Reviewed-by: Daniel M. Crowell <dcrowell@us.ibm.com> Reviewed-by: Douglas R. Gilbert <dgilbert@us.ibm.com> Reviewed-by: Mark W. Wenning <wenning@us.ibm.com> Reviewed-by: A. Patrick Williams III <iawillia@us.ibm.com>
* Support for core_activate via IPI.Patrick Williams2012-07-161-0/+1
| | | | | | | | RTC: 37009 Change-Id: I56669805c86d9659a20ad7c26e5e9860c7a248c7 Reviewed-on: http://gfw160.austin.ibm.com:8080/gerrit/1087 Tested-by: Jenkins Server Reviewed-by: A. Patrick Williams III <iawillia@us.ibm.com>
* Allow kernel to shutdown-to-payload.Patrick Williams2012-04-241-0/+64
| | | | | | | | | | | | | | | This code is currently unused, due to InitService not having the payload address and the start_host_os IPL step being unimplemented. For testing purposes the 'shutdown' call in initservice.C can be changed to pass a non-zero base address (such as 256MB). RTC: 40871 Change-Id: I0f4b6bae62ede1853aabbcb28082300005e31897 Reviewed-on: http://gfw160.austin.ibm.com:8080/gerrit/926 Reviewed-by: A. Patrick Williams III <iawillia@us.ibm.com> Tested-by: Jenkins Server Reviewed-by: Douglas R. Gilbert <dgilbert@us.ibm.com>
* Handle hype_fac_unavail exception.Patrick Williams2012-02-201-0/+16
| | | | | | | | | | | | | | | | | | | | | | | | The P8 processor (in RFC02230 targeted for ISA 2.07) adds a new SPR register HFSCR (Hypervisor Facility Status and Control Register). This register allows the hypervisor to disable access to some resources, such as floating point and VSX, from a partition. The purpose of this is to save time in saving the partition context when switching partitions. Since we sometimes enable floating point instructions we need to also enable the HFSCR[FP]. We could do this when enabling floating point in the MSR, but the SPR does not exist in P7. Instead we'll do it as-needed on the hw-thread the first time it executes a FP instruction. The FP instruction will cause the hype_fac_unavail exception and the exception handler will set HFSCR appropriately. Change-Id: I6c1e75939bb59142cbcf692fa56deb2271d6bdc3 Reviewed-on: http://gfw160.austin.ibm.com:8080/gerrit/676 Tested-by: Jenkins Server Reviewed-by: Daniel M. Crowell <dcrowell@us.ibm.com> Reviewed-by: Douglas R. Gilbert <dgilbert@us.ibm.com> Reviewed-by: A. Patrick Williams III <iawillia@us.ibm.com>
* GCOV supportPatrick Williams2012-02-071-0/+11
| | | | | | | Change-Id: I73a446754cd03178055459eb75c7b2f87b51b0f3 Reviewed-on: http://gfw160.austin.ibm.com:8080/gerrit/635 Tested-by: Jenkins Server Reviewed-by: A. Patrick Williams III <iawillia@us.ibm.com>
* Interrupt presenter implementationDoug Gilbert2012-01-051-1/+1
| | | | | | | | Change-Id: If6b499d819b71298b8a64e096e1eb83c639ad645 Reviewed-on: http://gfw160.austin.ibm.com:8080/gerrit/517 Tested-by: Jenkins Server Reviewed-by: Daniel M. Crowell <dcrowell@us.ibm.com> Reviewed-by: A. Patrick Williams III <iawillia@us.ibm.com>
* Add debug message for MC exception.Patrick Williams2011-09-161-1/+7
| | | | | | | | Change-Id: Ic8c0a5567f4f1e008014a4d54fb640dda6669cbc Reviewed-on: http://gfw160.austin.ibm.com:8080/gerrit/346 Tested-by: Jenkins Server Reviewed-by: Douglas R. Gilbert <dgilbert@us.ibm.com> Reviewed-by: Daniel M. Crowell <dcrowell@us.ibm.com>
* FP Denormalization support.Patrick Williams2011-09-121-0/+25
| | | | | | | Change-Id: I529e6f072993c0dd0a638fe7e53bcc871e6a928c Reviewed-on: http://gfw160.austin.ibm.com:8080/gerrit/326 Tested-by: Jenkins Server Reviewed-by: A. Patrick Williams III <iawillia@us.ibm.com>
* Floating point support.Patrick Williams2011-09-121-1/+108
| | | | | | | Change-Id: I859cac1c01bf631d12223702d68813b45339b65f Reviewed-on: http://gfw160.austin.ibm.com:8080/gerrit/295 Tested-by: Jenkins Server Reviewed-by: A. Patrick Williams III <iawillia@us.ibm.com>
* Ensure scratch operations happen on master core.Patrick Williams2011-08-311-0/+26
| | | | | | | | Change-Id: I970d645108de041d410599847edce877cb794015 Reviewed-on: http://gfw160.austin.ibm.com:8080/gerrit/275 Tested-by: Jenkins Server Reviewed-by: Daniel M. Crowell <dcrowell@us.ibm.com> Reviewed-by: A. Patrick Williams III <iawillia@us.ibm.com>
* Add copyright headers to all source files.Patrick Williams2011-08-241-0/+22
| | | | | | | Change-Id: I205f2409e56032cfc0aaf01d7e26d357f0b86373 Reviewed-on: http://gfw160.austin.ibm.com:8080/gerrit/277 Reviewed-by: A. Patrick Williams III <iawillia@us.ibm.com> Tested-by: Jenkins Server
* Add initial scratch (sprc/sprd) support.Patrick Williams2011-08-221-2/+20
| | | | | | | Change-Id: Ica416251241a2881459b2eb1ae0ad3c746de1200 Reviewed-on: http://gfw160.austin.ibm.com:8080/gerrit/267 Tested-by: Jenkins Server Reviewed-by: A. Patrick Williams III <iawillia@us.ibm.com>
* Create initial stack-frame from userspace.Patrick Williams2011-08-221-1/+9
| | | | | | | | Change-Id: Ie1133bd079e7b9a8f2f82daa06efc426bf0fd0d6 Reviewed-on: http://gfw160.austin.ibm.com:8080/gerrit/268 Tested-by: Jenkins Server Reviewed-by: Douglas R. Gilbert <dgilbert@us.ibm.com> Reviewed-by: Daniel M. Crowell <dcrowell@us.ibm.com>
* Add handling for HvEmu exception.Patrick Williams2011-08-011-2/+11
| | | | | | | | Change-Id: I03a7460b347b47f4653a6f457d1d7711fc0a0512 Reviewed-on: http://gfw160.austin.ibm.com:8080/gerrit/209 Tested-by: Jenkins Server Reviewed-by: Douglas R. Gilbert <dgilbert@us.ibm.com> Reviewed-by: MATTHEW S. BARTH <msbarth@us.ibm.com>
* Reduce working threads to first core.Patrick Williams2011-07-251-20/+32
| | | | | | | | | | | | | This is required to reduce the memory footprint of the kernel so we can fit within 2MB. This patch will cause (in simics) all other cores/threads to execute a 'doze' instruction and cease executing. In VBU, only 1 core will be active anyhow. Change-Id: If1bdc01393b02d802ba7595a88dcf3331efc2d4e Reviewed-on: http://gfw160.austin.ibm.com:8080/gerrit/203 Tested-by: Jenkins Server Reviewed-by: Daniel M. Crowell <dcrowell@us.ibm.com> Reviewed-by: Douglas R. Gilbert <dgilbert@us.ibm.com>
* Add user-space stub for task entry.Patrick Williams2011-07-181-0/+23
| | | | | | | | | | | This will prevent kernel space from needing to dereference user-space addresses for starting a task, which is safer and is easier for VMM. Change-Id: Icad3b832550cedbf291ed8b032840f4049fba18e Reviewed-on: http://gfw160.austin.ibm.com:8080/gerrit/202 Tested-by: Jenkins Server Reviewed-by: Douglas R. Gilbert <dgilbert@us.ibm.com> Reviewed-by: MATTHEW S. BARTH <msbarth@us.ibm.com>
* Add HMER access syscalls (as fastpath).Patrick Williams2011-06-021-1/+41
| | | | | | | | Change-Id: Icc7494986d19950a18cc9ee53fd5125c86096a72 Reviewed-on: http://gfw160.austin.ibm.com:8080/gerrit/105 Tested-by: Jenkins Server Reviewed-by: Douglas R. Gilbert <dgilbert@us.ibm.com> Reviewed-by: Andrew J. Geissler <andrewg@us.ibm.com>
* Additional weak-consistency fixes.Patrick Williams2011-04-211-0/+1
| | | | | | | Change-Id: I6d6304851a1794e117782277f6e3aee7544afcc7 Reviewed-on: http://gfwr801.rchland.ibm.com:8080/gerrit/6 Tested-by: Jenkins Server Reviewed-by: Andrew J. Geissler <andrewg@us.ibm.com>
* Fix size mismatch on store of 'kernel_other_thread_spinlock.Patrick Williams2011-04-061-2/+2
|
* Support running a full system worth of threads.Patrick Williams2011-03-071-12/+22
|
* Thread priorities in idle and init spinlock.Patrick Williams2011-03-051-1/+9
|
* Merge of PowerHAL project up to commit:Patrick Williams2011-03-051-0/+4
| | | | dd45c30bd53d8e6c123165b83842d08117558a3c
* Add linker in preparation for modules.Patrick Williams2010-08-201-4/+0
|
* MMIO mapping support and syscalls.Patrick Williams2010-07-081-5/+5
|
* SMT support.Patrick Williams2010-07-071-8/+44
|
* Memory map and execution fixes for simics.Patrick Williams2010-07-021-1/+3
|
* Change 0x17C to 'attn' instruction.Patrick Williams2010-06-281-1/+1
|
* Fix SPRs overwriting GPRs in restore.Patrick Williams2010-06-281-5/+5
|
* Move SPR restore to end of dispatch sequence.Patrick Williams2010-06-281-9/+10
|
* Place-holder for breakpoint attention / PHYP start address.Patrick Williams2010-06-281-0/+5
|
* Program exception handling and emulated instruction for mfsprg3.Patrick Williams2010-06-221-1/+1
|
* Turn interrupt vectors into macros.Patrick Williams2010-06-221-122/+49
|
* Typo for XER save.Patrick Williams2010-06-041-1/+1
|
* Add stub for decrementer interrupt.Patrick Williams2010-06-031-4/+26
|
* Fix form of ori instruction.Patrick Williams2010-06-031-1/+1
|
* Add stub for syscall.Patrick Williams2010-06-031-1/+10
|
* Implement task saving and dispatching.Patrick Williams2010-06-031-0/+218
|
* Import register constants from KIS codebase, update start.S to use.Patrick Williams2010-06-031-31/+33
|
* Initial cpu / task structs.Patrick Williams2010-06-021-8/+0
|
OpenPOWER on IntegriCloud