From: pageexec
Date: Mon Nov 08 2004 - 14:06:32 EST

> Shouldn't the ESP value pointed to by KSTK_ESP() point to the beginning of
> the pt_regs structure for the user space application?

first of all, anything can be on the userland stack at the time the
app issued a syscall. but you don't have to bother with the userland
stack at all, pt_regs is created on the kernel stack, check out the
SAVE_ALL macro (and its uses) in arch/i386/kernel/entry.S .

To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at
Please read the FAQ at