Porting Voodoo

This page is about Voodoo beta4 and is now obsolete

Porting Voodoo to your Galaxy S phone should be fairly straightforward.
Team Voodoo will certainly be able to help you in this task.

Here are the steps you’ll need to follow:

Build a Samsung Kernel

Make sure you already know how to build a kernel using

Does your kernel work and boot ?

To follow the standard Voodoo configuration, you’ll need to add

  • Ext4 filesystem support:

    CONFIG_EXT4_FS=y
    # CONFIG_EXT4DEV_COMPAT is not set
    CONFIG_EXT4_FS_XATTR=y
    CONFIG_EXT4_FS_POSIX_ACL=y
    CONFIG_EXT4_FS_SECURITY=y
    CONFIG_JBD=y
    CONFIG_JBD2=y

  • Tunneling support: (tun.ko)

    CONFIG_TUN=m

How to point kernel to your Ramdisk ?

It’s so much easier than found in most docs. In menuconfig or in .config, set:

CONFIG_INITRAMFS_SOURCE=”/home/you/sources/ramdisk”
That’s right, just the directory name :)
No initramfs_list *headaches* or pre-build cpio archive

In order to set the ramdisk files UID to root, you will need to set these to config options too: (UID and GID specified in source ramdisk will be translated to 0 in destination)

CONFIG_INITRAMFS_ROOT_UID=1005
CONFIG_INITRAMFS_ROOT_GID=1005

If it’s alright, let’s go to the next step.

Fetch the latest Voodoo ramdisk

You can download the latest ramdisk using git (not ready yet) or from /downloads/
Take the latest file named like this sample: Voodoo-beta4-GT-I9000-ramdisk.tar.bz2

Customize the ramdisk with your model specificities

Each variant has a few differences in the ramdisk. Here is a list of known unique files:

  • /sbin/init

    This file is use like a BIOS by Samsung, it initializes a bunch of hardware parameters and then run the Android OS

  • /*.rc

    Most phones  have customized init.rc, you’ll need to check for differences in there. The easiest way is simply to copy the files from your original ramdisk.
    After that, see Voodoo’s additions in init.rc by searching for “Voodoo here” notes, and replicate them to your init.rc.
    init.rc in Voodoo’s ramdisk is actually a symbolic link to init.rc-standard and this symlink is dynamically modified to init.rc-debug if the debug mode is detected at boot.
    init.rc-debug has only one difference. It forces adb daemon to be started no matter what at boot to help debug tricky situations.

  • /etc/asound.conf

    This file can differ between phones to be sure you’ll play all the oh-so-cool :) robot voices when Voodoo work at migrating data, copy the asound.conf present in your firmware’s /system/etc/asound.conf

  • /lib/modules/*

    The /lib/modules directory contains 2 files type: pre-build closed sources ones related to OneNAND & RFS, and those you build using sources.

    It’s safe to copy from your stock ramdisk:
    drop_caches.ko, fsr.ko, fsr_stl.ko, j4fs.ko, param.ko, rfs_fat.ko, rfs_glue.ko

    Other modules compiled from source will need to be copied to your Voodoo ramdisk:
    ./linux-2.6.29/drivers/scsi/scsi_wait_scan.ko, ./linux-2.6.29/drivers/net/tun.ko, ./modules/bcm4329/dhd.ko, ./modules/fm_si4709/Si4709_driver.ko, ./modules/s3clcd/s3c_lcd.ko, ./modules/vibetonz/vibrator.ko, ./modules/multipdp/multipdp.ko, ./modules/s3cbc/s3c_bc.ko, ./modules/dpram/dpram.ko, ./modules/pvrsrvkm/pvrsrvkm.ko

Build your first Voodoo kernel

With all previous steps completed, you should now be able to build your first Voodoo kernel. Because you need to copy modules in ramdisk, of course you will need at least 2 builds. On the second build, the kernel scripts will actually include the proper ramdisk in zImage.

zImage can be included in a tar usable with Odin:

tar cvf custom-pda.tar zImage

You can also use it with an update.zip template like this one

Comments are closed.