Porting Arla to Linux/390
Magnus Ahltorp
ahltorp at nada.kth.se
Sat Jul 22 00:17:48 CEST 2000
> I am working at IBM in porting Arla to Linux/390. When I try make, I
> get the message that process.o was not found or created. Upon
> further investigation, I found out that there were several process.S
> files for different architectures such as i386, powerpc, etc.
> I need to write one for the S390 architechture and these files are
> all in assembly language. I have not found any documentation about
> what the process.S file does, so I would appreciate if someone would
> explain in words, what the functions in process.S do.
The assembly code in process.S implements stack switching. There are
two functions, savecontext and returnto.
savecontext saves the current context (normally registers) by pushing
all registers on the stack and then saving the stack pointer to the
struct savearea (the second argument). It sets the stack pointer to
newsp(the third argument) and jumps to the function f (the first
argument).
returnto restores the context to a previously saved context, i.e.
restores the stack pointer and pops all registers from the stack.
/Magnus
More information about the Arla-drinkers
mailing list