|
From: Jeremy F. <je...@go...> - 2004-07-05 17:21:45
|
On Mon, 2004-07-05 at 09:44 +0100, Nicholas Nethercote wrote: > Can we pass the info from stage1 to stage2 without using the auxv? Could > it be done just with two global variables? stage1 is still in memory when > stage2 starts, so this shouldn't be too hard, right? Well, yes, but there's a problem of finding the rendezvous memory. I guess we could just pick a fixed constant address and put some info there. I used the AUXV because its the standard way of passing this kind of info between kernel and userspace at exec time, and I'm just piggybacking a bit. > If it's possible to do it this way, that would be better than doing it via > auxv and not being certain if it's going to work or going to clobber some > random memory location miles away. Well, glibc already uses AT_ entries bigger than 32 so it would be a generic bug if they're still doing that now. J |