Quote:
Originally Posted by hedpe
Hey romracer,
Could you include a script or guide on how to build your kernel? I have been following this guide, but I'm a little nervous about Step 10 in creating the boot.img. I don't want to create a bad kernel or brick my phone. That guide is supposedly also for the i727, but I want to be sure.
I extracted initramfs directly from your boot.img. Then, I built your kernel (using msm8660_celox_usa_att_rev02_defconfig) to get the kernel modules (*.ko) and the kernel zImage.
Then, the guide provided a link to these mkbootfs scripts: http://www.mediafire.com/?w06d1m6n1dgo4op ... I want to confirm these are the proper scripts to use.
Then it says:
Code:
./mkbootfs initramfs | gzip > ramdisk.gz
mkbootimg-sg2x --kernel zImage --ramdisk ramdisk.gz --cmdline "androidboot.hardware=qcom msm_watchdog.appsbark=0 msm_watchdog.enable=1 loglevel=4" -o boot.img --base 0x40400000 --pagesize 2048
But, I'm a little bit nervous about that --base 0x40400000 parameter.
It'd be great if you could verify that guide or include your initramfs and scripts in your github kernel repo.
Thanks a bunch!
|
That guide looks to be mostly how I do it. I use split_bootimg.pl to break down boot.img into the kernel and a ramdisk archive. I like split_bootimg.pl because it will print the kernel command line for you (for copying/pasting later). I break down the ramdisk with:
Code:
mkdir ramdisk ; cd ramdisk ; gzip -dc ../*-ramdisk.gz | cpio -i
I don't know what mkbootimg-sg2x is; I use what I thought was the standard "mkbootimg". The guide mentions needing that -sg2x one because of the ramdisk, but the command line provided (mkbootimg command line, not kernel command line) does not have anything special that I see. That base address is correct. You can find our base address in the kernel source in the defconfig file; its the CONFIG_PHYS_OFFSET variable. I use the following command to copy my kernel modules - hell of a lot easier than all those individual ones  :
Code:
find . -name '*.ko' -exec cp {} $INITRAMFSDIR/lib/modules/ \;
The only thing I do that I don't see in that guide is the following command after the boot.img is built to change a magic number (Rogers is 90h or "\\x90"):
Code:
echo -ne \\x80 | dd conv=notrunc bs=1 count=1 of=boot.img seek=22
Maybe that's what mkbootimg-sg2x does? In my experience, if you don't do that then your phone will not boot. You'll see the Samsung logo and then the screen will blip and it will reboot. You can fix it by just booting into recovery and flashing another kernel (or fixing your kernel and reflashing it). It's not a brickable mistake.
Quote:
Originally Posted by droid512
Rom, did you ever get a chance to look into that slide to wake mod i messaged you about? The creator of the the mod wanted me to have you email him (bponury@gmail.com) so he can give you the source
|
Sorry, I did not. I'll review your post. Edit: emailed him.
Samsung Galaxy S III
(old) Samsung Galaxy S2 Skyrocket
(old) Motorola Atrix 4G
(old) HTC Desire
(old) Google Nexus One
|