Yes, I've just checked, starting at 64K...
> Maybe we could just
> do the same for OSF/1 binaries by setting TASK_UNMAPPED_BASE
> appropriately?
No. I've changed in load_aout_binary() set_personality(PER_LINUX) to
set_personality(PER_LINUX_32BIT), and now I have another error.
You will laugh, but...
$ netscape
665:/usr/lib/netscape/netscape-communicator: : Fatal Error: mmap available address is not larger than requested
This happens after
mmap(0x7fdc8000, 40960, PROT_READ|PROT_WRITE|PROT_EXEC, MAP_PRIVATE|MAP_ANONYMOUS, -1, 0) = 0x40018000
And note, this is the message from loader, not from netscape itself.
So I think my second patch is an easiest solution for now.
Look, compared with the code in Linus' tree:
- it doesn't add any overhead in general case (addr == 0);
- if the specified address is too high and we can't find a free
area above it, we just continue search from TASK_UNMAPPED_BASE
as usual;
- if address is too low, extra cost is only compare and taken branch.
I think it's clean enough.
Ivan.
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/