Skip to contentSkip to conversation

Stack layout/and register values for ret_from_sys_call

Alpha/Linux Aneesh Kumar K.V 2 participants 2 messages Dec 17, 2001 – Dec 29, 2001

lore
Share & tools
lore
#0 lore raw

Hi,

Can someone explain me what should be the stack layout and register
value( if there is any restriction ) before calling ret_from_syscall for Alpha. Again in entry.S i find may places where we make current ( Register 8) as below

lda $8,0x3fff
bic $30,$8,$8

If someone can expain what happens in the above two assembly statement it will be really helpful.

Thanks in advance.

-aneesh

#1 lore raw
Quoted 3 lines · Aneesh Kumar K.V

Can someone explain me what should be the stack layout and register
value( if there is any restriction ) before calling ret_from_syscall for Alpha.

Top of stack should contain a struct pt_regs. See asm/ptrace.h.

Quoted 5 lines

lda $8,0x3fff
bic $30,$8,$8

If someone can expain what happens in the above two assembly statement it will be really helpful.

This computes the value for "current". The stack plus task structure is aligned on a two-page boundary. See task_union in linux/sched.h.

r~