Jivin David Howells lays it down ...
> Darwin Chen <[EMAIL PROTECTED]> wrote:
> 
> > I found a surprised code after I hacking the kernel with several weeks:
> > In linux-2.6.x/fs/binfmt_flat.c: Line 603:  
> > textpos = do_mremap(textpos, len, reallen, 
> >             MREMAP_FIXED, textpos);
> > 
> > But, in linux-2.6.x/mm/nommu.c, the code didn't support MREMAP_FIXED flag.
> > So, I always get this error.
> > 
> > Is this a kernel bug? Or how to fixed it?
> 
> You need an MMU if you want to implement that - at least for anything other
> than new_address == old_address.  So just like for MAP_FIXED, MREMAP_FIXED is
> not supported if CONFIG_MMU=n.

Ok,  but both the calls to do_mremap have newaddr and addr the same
(ie., textpos above).  And from mm/nommu.c:

        if (flags & MREMAP_FIXED && new_addr != addr)
                        return (unsigned long) -EINVAL;

So perhaps it is failing further down the do_mremap conditionals,

Cheers,
Davidm

-- 
David McCullough,  [EMAIL PROTECTED],   Ph:+61 734352815
Secure Computing - SnapGear  http://www.uCdot.org http://www.cyberguard.com
_______________________________________________
uClinux-dev mailing list
[email protected]
http://mailman.uclinux.org/mailman/listinfo/uclinux-dev
This message was resent by [email protected]
To unsubscribe see:
http://mailman.uclinux.org/mailman/options/uclinux-dev

Reply via email to