From fe8e18a98da76be5d989c70c95d0bcb81d6ce893 Mon Sep 17 00:00:00 2001 From: Joel Sherrill Date: Sun, 16 Apr 2000 17:01:18 +0000 Subject: [PATCH] Patch from Eric Norum to modify the generic m68k start code to setup the "environ" variable properly. With this patch, his EPICS application that runs on the gen68360 also runs on the mvmv167. --- c/src/lib/libbsp/m68k/shared/start.S | 15 +++++++++------ 1 file changed, 9 insertions(+), 6 deletions(-) diff --git a/c/src/lib/libbsp/m68k/shared/start.S b/c/src/lib/libbsp/m68k/shared/start.S index 4c9372e735..8a2273d2cc 100644 --- a/c/src/lib/libbsp/m68k/shared/start.S +++ b/c/src/lib/libbsp/m68k/shared/start.S @@ -91,8 +91,8 @@ loop: movel #0,a1@+ | to zero out uninitialized lea SYM (hiintstack),a0 | a0 = high end of intr stack movec a0,isp | set interrupt stack #endif - movel #0,a7@- | push environp - movel #0,a7@- | push argv + pea env | push environp + pea arg | push argv movel #0,a7@- | push argc jsr SYM (boot_card) @@ -115,6 +115,11 @@ END_CODE BEGIN_DATA + PUBLIC (environ) + .align 2 +SYM (environ): + .long env + PUBLIC (start_frame) SYM (start_frame): .space 4,0 @@ -123,10 +128,8 @@ END_DATA BEGIN_BSS - PUBLIC (environ) - .align 2 -SYM (environ): - .long 0 +env: .long 0 +arg: .long 0 PUBLIC (initial_isp) SYM (initial_isp):