diff options
author | Marty Gloff <mgloff@us.ibm.com> | 2017-05-09 12:05:35 -0500 |
---|---|---|
committer | William G. Hoffa <wghoffa@us.ibm.com> | 2017-05-23 12:43:03 -0400 |
commit | 20ceedc8a8622b7f06dad251163a56e77c4bf943 (patch) | |
tree | bd2eb94439a590e1a0a6e58155281463b0a315b9 /src/bootloader | |
parent | 280883b46812d44f94c079de68043dd644aa5c43 (diff) | |
download | talos-hostboot-20ceedc8a8622b7f06dad251163a56e77c4bf943.tar.gz talos-hostboot-20ceedc8a8622b7f06dad251163a56e77c4bf943.zip |
Save space in Bootloader image with single thread and task end
Bootloader checks for only being a single thread and handles other
thread instances. It also has task end code to suport this checking.
This code can be removed to save space.
Change-Id: I906740efec02e1799a36edd82963d038fd42ce7e
Reviewed-on: http://ralgit01.raleigh.ibm.com/gerrit1/40286
Tested-by: Jenkins Server <pfd-jenkins+hostboot@us.ibm.com>
Tested-by: Jenkins OP Build CI <op-jenkins+hostboot@us.ibm.com>
Tested-by: FSP CI Jenkins <fsp-CI-jenkins+hostboot@us.ibm.com>
Reviewed-by: Corey V. Swenson <cswenson@us.ibm.com>
Reviewed-by: Christian R. Geddes <crgeddes@us.ibm.com>
Reviewed-by: William G. Hoffa <wghoffa@us.ibm.com>
Diffstat (limited to 'src/bootloader')
-rw-r--r-- | src/bootloader/bl_start.S | 41 |
1 files changed, 0 insertions, 41 deletions
diff --git a/src/bootloader/bl_start.S b/src/bootloader/bl_start.S index 210089c34..1e3120296 100644 --- a/src/bootloader/bl_start.S +++ b/src/bootloader/bl_start.S @@ -82,18 +82,7 @@ _start: _start_postmsr: - ;// Determine if this is the first thread. - li r4, 2 - ;// Read spinlock value. - lis r2, kernel_other_thread_spinlock@h - ori r2, r2, kernel_other_thread_spinlock@l lwsync -1: - ldarx r3, 0, r2 - cmpwi r3, 0 ;// Non-zero means this thread wasn't first. - bnel cr0, _other_thread_error ;// Handle having multiple threads started - stdcx. r4, 0, r2 ;// Attempt to store 2. - bne 1b ;// Loop until sucessful at stwcx. isync ;// _main: @@ -313,31 +302,6 @@ HYPE_INTERRUPT(hype_fac_unavail, HBBL_hype_fac_unavail) STD_INTERRUPT(softpatch, HBBL_softpatch) STD_INTERRUPT(debug, HBBL_debug) -;// @fn _other_thread_error: -;// Used for threads other than first to handle this unexpected condition. -_other_thread_error: - ;// Read spinlock value. - lis r2, kernel_other_thread_spinlock@h - ori r2, r2, kernel_other_thread_spinlock@l -1: - ld r3, 0(r2) - ;// Loop until value is 1... - cmpi cr0, r3, 1 - beq task_end_stub ;// End the multiple threads - or 1,1,1 ;// Lower thread priority. - b 1b - - - ;// @fn task_end_stub - ;// Stub to call a TASK_END syscall in the event that a task 'returns' from - ;// its entry point. We cannot call task_end() directly because profiling - ;// inserts garbage code into the task_end C function. -.global task_end_stub -task_end_stub: - mr r4, r3 ;// Move current rc (r3) to status value (r4) - li r3, 2 ;// TASK_END -> r3 (syscall number) - sc - ;// @fn enterHBB ;// Leave the Bootloader and switch to the Hostboot Base (HBB). @@ -388,11 +352,6 @@ switchToHBB: .section .data - .balign 8 -.global kernel_other_thread_spinlock -kernel_other_thread_spinlock: - .space 8 - .balign 16 .global hbi_ImageId hbi_ImageId: |