GP2X Compiling Kernel Modules


dominicbeesley

Still Fresh
Joined
Aug 30, 2006
Messages
23
Hello all,

I've been trying to get the gp2x to work as an NFS client (I can't find anybody else documenting how to do this)....

I'm fairly sure the nfs client stuff is working as it complained until I'd got everything set right in etc/fstab but then failed with "no such device"

So then I've tried building the modules for the kernel-nfs client

I've so far tried:

Downloaded firmware 2.0.0
Downloaded the "old" arm-dev gcc toolchain 2.9.5....version (newer compilers don't work with kernel)
done some menuconfigery and a make modules_install got the relevant (I think) modules:
- nfs.o
- sunrpc.o
- lockd.o
and copied them onto gp2x
insmod the modules order

all is well so far...but when I try to mount a mount on my server the gp2x pauses for about 5 minutes (it then actually does mount the nfs mount WOO YAY! at last!)

Any ideas why this is pausing like this?

Cheers

Dom
 
my guess would be because you are not actually running the rpc userspace stuff, like locking and such. try mount with the nolock parameter
 
Redeeman posted on Oct 25 2006 at 10:48 PM said:
my guess would be because you are not actually running the rpc userspace stuff, like locking and such. try mount with the nolock parameter

Thanks that did it...Do you think its worth documenting? I know its going to make life much more pleasant now I can build up an image on my hard disk and run from there!
 
Last edited by a moderator:
brahms posted on Oct 26 2006 at 12:20 PM said:
Redeeman posted on Oct 25 2006 at 10:48 PM said:
my guess would be because you are not actually running the rpc userspace stuff, like locking and such. try mount with the nolock parameter

Thanks that did it...Do you think its worth documenting? I know its going to make life much more pleasant now I can build up an image on my hard disk and run from there!
it would be good if documented indeed, I just find it weird to use samba to mount my home partition :D
 
Last edited by a moderator:
a wiki page about how to mount nfs may be nice, also with compile instructions and such.. (and perhaps some host for the binary modules?)

anyway, just remember that when you mount without locking, well.. you dont have file locking :)
 
Redeeman posted on Oct 26 2006 at 03:12 PM said:
a wiki page about how to mount nfs may be nice, also with compile instructions and such.. (and perhaps some host for the binary modules?)

anyway, just remember that when you mount without locking, well.. you dont have file locking :)

I may well try and get the locking working soon too.

However it now "works" for a while but if left alone for a few minutes it seems to lose the connection and I get permission denied errors until I umount and re-mount? Any ideas?

Cheers

dom
 
Last edited by a moderator:
Lint posted on Oct 27 2006 at 12:49 PM said:
could you please upload these NFS modules?

Not at the machine at the moment but will hopefully do something over the weekend

Dom
 
Last edited by a moderator:
Last edited by a moderator:
Hey man, many thanks, I really appreciate it!

about your wiki page, I think that would be wiser to change the following line:

$export PATH=/usr/local/arm-dev/bin
to
$export PATH=/usr/local/arm-dev/bin:"$PATH"

Now that I have the correct devkit I think I'll be capable of compiling it myself anyway :ph34r:
Have you ever tried to compile a whole new kernel instead of just modules?
 
Well, after decompressing arm-tools, I've found some missing links, I wonder if you got this links broken too?

/usr/local/arm-dev/arm-linux/include/asm -> /home/depss/DEPSS/linux/include/asm
/usr/local/arm-dev/arm-linux/include/linux -> /home/depss/DEPSS/linux/include/linux

I've linked against FW 2.0.0's asm/linux directories, but somebody should link it to a better place than /home/depss(?!?)
 
Lint posted on Oct 28 2006 at 05:03 PM said:
Hey man, many thanks, I really appreciate it!

about your wiki page, I think that would be wiser to change the following line:

$export PATH=/usr/local/arm-dev/bin
to
$export PATH=/usr/local/arm-dev/bin:"$PATH"

Whoops yes... I'll change that now!

Lint posted on Oct 28 2006 at 05:03 PM said:
Now that I have the correct devkit I think I'll be capable of compiling it myself anyway :ph34r:
Have you ever tried to compile a whole new kernel instead of just modules?

Glad somebody appreciates the work...I know its already saved me hours of messing about with using the cardreader!

I'm going to have a look at that when I get a spare moment and see if I can't do something about the worrying inability of the current firmware to flush files (even though they are mounted sync!)

Cheers

Dom

Lint posted on Oct 29 2006 at 01:45 PM said:
Well, after decompressing arm-tools, I've found some missing links, I wonder if you got this links broken too?

/usr/local/arm-dev/arm-linux/include/asm -> /home/depss/DEPSS/linux/include/asm
/usr/local/arm-dev/arm-linux/include/linux -> /home/depss/DEPSS/linux/include/linux

I've linked against FW 2.0.0's asm/linux directories, but somebody should link it to a better place than /home/depss(?!?)

Not one I've noticed, I just took the archive from the archive site and it worked! - I would love to be able to get all the right patches and build it from source though as it kind of screws up my build system having it where it is.

If anybody know how to recreate an arm-dev kit (as mentioned in the wiki article) from scratch or where to get the sources I'd love to know!

Cheers

dom
 
Last edited by a moderator:
Yeah, I don't wanna to loose my linux permissions and links on gp2x, so smb was no way to go (then after I discovered that there's a new extension on samba that would allow you to let samba transport/use linux permissions, but that's only avaiable on newer versions of smbd, maybe I'll try that later)

I think there shall be no much trouble compiling newer compilers/libs for gp2x, it just takes a horrendous amount of time and effort... I've downloaded that arm devkit which is a simple shellscript that download all files (glibc, binutils, gcc, etc...), configure and make'em, so there should be no big deal if you keep using the same versions and try to follow that script, but if you're trying to compile newer things than I wish you the best of luck :ph34r:

I've compiled gcc, glibc, and so on for PC, but not for gp2x... only once, when I installed that mentioned devkit
 
Back
Top