Due to the fact that make doesnt work properly and the wireless drivers cannot be compiled and installed, we will build a custom kernel with the modules and components needed for the project.
The custom kernel should contain and ensure the following work properly:
- The zd1211 drivers and firmware (if possible)
- the dm-crypt module and ensure it works with the hardware capabilities of the plug
- any other modules that come in mind
There are three kernel distributions for the plug, the official ARM from kernel.org, the Orion tree from Marvell and the Feroecon which is the initial one distributed by Marvell with the plugs. We will use the Orion tree as it seems to be the most successful one on the plug, with the minimum of problems. The current version is 2.6.32-rc2 “dirty”.
Various patches specially for the plug will also be used, as well as the .config file (albeit changed) from sheeva.with-linux.
We will do a cross-compiling as its much faster, and use the CodeSourcery toolchain for compiling as its the most documented.
The work machine here will be a VM on Sun’s VirtualBox running Slackware. Slackware was chosen as it already has many of the tools and libraries needed for compiling and general development and to have an excuse to check out Slackware.
Update:
Slackware is great, but unfortunately the cross-compiler used (Codesourcery) does not fully support x6 4, so the cross-compiling will be done on my laptop with ubuntu 9.04.
Through the instructions in the official wiki and the computerplugs wiki, and after many runs, the compilation has completed. Initially I tried just taking the module zd1211rw.ko and installing it on the plug using insmod as per ruidc’s, but it wouldnt allow it as the kernel version is different on the new compiled kernel.
I have then proceeded to modify the installer as per rooster’s instructions, so as to reflash the plug directly into my compiled kernel,but Im now having problems with openocd connecting to the plug. Until they are resolved, here are the modules and options I enabled in my kernel:
- zd1211rw support, obviously.
- floating point emulation
- wireless – enable developer warnings
- cryptoloop support
- fusion MPT device support
- ethernet 1000mbit
- enable wireless USB extensions
- wireless USB host controller interface driver
- Marvell’s cryptographic engine
- device mapper support
- crypt target support
- SHA256 digest
- AES cipher
- loadable module support – important, the kernel wont allow modules to be compiled if this hasnt been enabled prior to initial compilation.
The various cryptographic modules and options should help with the crypto side of the project.
I cannot yet clarify on the results of the custom kernel, will report ASAP.
Update:
After unsuccessful runs with the installer, both in Windows and Linux and following all the tips about connectivity such as the following:
- rmmod the ftdi_sio device sudo rmmod ftdi_sio
- re-initialize the device sudo modprobe ftdi_sio vendor=0×9e88 product=0×9e8f
- using the statically linked openocd
- as well as the usual power cycling tips
the installer still refuses to flash the plug. As a matter of fact, the minute the installer script is being run the plug reboots, and as u-boot has a delay of 3 seconds to allow for user intervention, im suspecting that the script is simply timing out.
To put the new kernel and modules on the plug, ive resorted to modify one of the README-x.x.x.x scripts available from sheeva.with-linux. These scripts originally are meant to download and install the kernel’s from that specific site. I simply bypassed the download part and re-wrote the script to process local files on the plug. Result: It worked! here is an output of lsmod (lists all active modules):
root@ubuntu:~# lsmod
Module Size Used by
zd1211rw 43479 0
ipv6 236187 10
dm_crypt 11202 0
dm_mod 57396 1 dm_crypt
and an iwconfig shows the wireless device:
root@ubuntu:~# iwconfig
lo no wireless extensions.eth0 no wireless extensions.
wlan0 IEEE 802.11bg Mode:Managed Access Point: Not-Associated
Tx-Power=0 dBm
Retry long limit:7 RTS thr:off Fragment thr:off
Encryption key:off
Power Management:off
If anyones interested, the uImage for this kernel can be found here, and the modules here. The modified readme is here.
Now we can proceed in making the wireless adaptor to work as an AP.
Back to Plug Computing





