
16th February 2013, 02:03 AM
(Last edited by flar2; 16th February 2013 at 02:05 AM.)
|
Recognized Developer - OP
Thanks Meter 4538
Posts: 1,687
Join Date: Jun 2012
Location: Ottawa
DONATE TO ME
|
[KERNEL] Stock Kernel (no write protection)
This is the stock kernel without system write protection. Completely stock configuration, completely stock ramdisk. The only difference is it allows write to system
Uses Telstra 3.17.841.2 source from htcdev.com:
http://dl4.htc.com/RomCode/Source_an...10-240d4d5.zip
Devs who need a vanilla kernel are free to modify or include with ROMs
installer: http://goo.gl/64HJc
boot.img: http://goo.gl/IRZ9m
|
|
The Following 13 Users Say Thank You to flar2 For This Useful Post: [ Click to Expand ]
|
|
954wrecker (16th February 2013), area51avenger (16th February 2013), Blazeitup123 (16th February 2013), cr1960 (17th February 2013), dementor123 (16th February 2013), E.Cadro (16th February 2013), happilyaccosted (16th February 2013), logancruiser (20th February 2013), monkboy24 (16th February 2013), nickeedoo (18th February 2013), ronnie498 (20th February 2013), Silellak (16th February 2013), utkaar099 (16th February 2013)
|

16th February 2013, 02:08 AM
|
Senior Member
Thanks Meter 317
Posts: 807
Join Date: Sep 2012
Location: Toronto
|
Re: [KERNEL] Stock Kernel (no write protection)
Does this also uninstall any old modules?
Sent from my VENOMized HoxL
Phone: Telus HTC One X - Unlocked S-OFF!
Hboot: 1.09
Rom: ViperXL 3.2.7
Kernel: Elemental 6.5
|

16th February 2013, 02:42 AM
|
Recognized Developer - OP
Thanks Meter 4538
Posts: 1,687
Join Date: Jun 2012
Location: Ottawa
DONATE TO ME
|
Quote:
Originally Posted by area51avenger
Does this also uninstall any old modules?
Sent from my VENOMized HoxL
|
The installer deletes /system/lib/modules/wp_mod.ko and /system/lib/wp_mod.ko
There is no init.d support either, so it won't load any init scripts.
|

16th February 2013, 02:50 AM
|
Senior Member
Thanks Meter 1231
Posts: 893
Join Date: Jun 2012
Location: Boston
DONATE TO ME
|
Nice job, this should be useful!
Device History
Quote:
|
-HTC One Dev Edition [CURRENT]
-AT&T HTC One X [RETIRED]
-Sony Ericsson XPERIA X10 [SOLD]
-Crappy Nokia [I don't even know what happened to this one...]
|
Did I help you out? If so, no need to say thanks. Just hit that "thanks" button!
My Work
- Android File Host
- goo.im
|

16th February 2013, 12:49 PM
(Last edited by AlxMAX; 16th February 2013 at 12:58 PM.)
|
Senior Member
Thanks Meter 70
Posts: 380
Join Date: Sep 2007
Location: Bucharest
|
On my side, I had some problems. I have tried to compile the kernel, but I went a little bit further with the modifications: - disabled the /system write protection.
- integrated the prima_wlan source tree in drivers/staging. The sources were downloaded from the codeaurora.org site and the driver version was 3.1.7.16 (I have specifically chosen this version because it was the closest to the 3.1.7.0 version that exists in the stock ROM).
- compressed the vmlinux image with LZMA instead of gzip (this is an option in the configuration) to obtain the zImage file.
- compressed the ramdisk image with LZMA instead of gzip (in the configuration file, I have seen 3 enabled options: gzip, LZMA and XZ and I thought recompressing the ramdisk might not hurt).
The toolchain I have used was downloaded from android.googlesource.com. Then I have unpacked the original boot.img like this: trimmed the first 128 bytes from the file (up to the ANDROID magic label), then used the unpackbootimg tool (this was a tool I have found in a Gingerbread source tree). Then, I have used the new zImg, the LZMA compressed ramdisk and mkbootimg (this was also picked from the same Gingebread source tree) to build a new boot.img. I have booted in the recovery, flashed the new modules, then booted in fastboot mode and flashed the boot.img. The result was an annoying boot loop and it wasn't very easy to put the phone in fastboot mode again. - I have some questions about what I have done so far. Could you, please, tell me if there was a wrong manoeuvre/setting/thingie? I suspect the unpacking process has not produced the proper data (command line, base address ...). What tool have you used to unpack the original boot.img file? I also suspect the packing process. Is a new mkbootimg required?
- And some questions about your work. What prima_wlan driver have you used in your boot.img? Have you modified the suffix added to the 3.4.10 version when you have configured the kernel in order to make it work?
HTC One XL X325u, O2 DE firmware 3.17.207.3.
HTC Desire A8181 (SLCD, PVT4), CyanogenMod 7 Nightly, Stock hboot.
Samsung Galaxy Tab 2 10.1 P5100, CyanogenMod 10.1
|

16th February 2013, 04:43 PM
|
Recognized Contributor / Recognized Developer
Thanks Meter 6279
Posts: 4,615
Join Date: Mar 2009
Location: Denver
DONATE TO ME
|
Quote:
Originally Posted by AlxMAX
On my side, I had some problems. I have tried to compile the kernel, but I went a little bit further with the modifications: - disabled the /system write protection.
- integrated the prima_wlan source tree in drivers/staging. The sources were downloaded from the codeaurora.org site and the driver version was 3.1.7.16 (I have specifically chosen this version because it was the closest to the 3.1.7.0 version that exists in the stock ROM).
- compressed the vmlinux image with LZMA instead of gzip (this is an option in the configuration) to obtain the zImage file.
- compressed the ramdisk image with LZMA instead of gzip (in the configuration file, I have seen 3 enabled options: gzip, LZMA and XZ and I thought recompressing the ramdisk might not hurt).
The toolchain I have used was downloaded from android.googlesource.com. Then I have unpacked the original boot.img like this: trimmed the first 128 bytes from the file (up to the ANDROID magic label), then used the unpackbootimg tool (this was a tool I have found in a Gingerbread source tree). Then, I have used the new zImg, the LZMA compressed ramdisk and mkbootimg (this was also picked from the same Gingebread source tree) to build a new boot.img. I have booted in the recovery, flashed the new modules, then booted in fastboot mode and flashed the boot.img. The result was an annoying boot loop and it wasn't very easy to put the phone in fastboot mode again. - I have some questions about what I have done so far. Could you, please, tell me if there was a wrong manoeuvre/setting/thingie? I suspect the unpacking process has not produced the proper data (command line, base address ...). What tool have you used to unpack the original boot.img file? I also suspect the packing process. Is a new mkbootimg required?
- And some questions about your work. What prima_wlan driver have you used in your boot.img? Have you modified the suffix added to the 3.4.10 version when you have configured the kernel in order to make it work?
|
use dsi xda kitchen to pack the boot.img for easy use
or
use this
unpackbootimg -i boot.img -o /directoryfordump
mkbootimg --cmdline 'console=ttyHSL0,115200,n8' --kernel zImage --ramdisk ramdisknew.gz --base 80400000 --ramdiskaddr 81900000 -o newboot.img
Building a better droid is the purpose of today
Android History
G1->mytouch 3g -> Mytouch slide -> Mytouch 4g -> HD2 magldr -> Thunderbolt -> Evo 3D -> Sensation -> Evo 4g -> Evo 3D -> HTC vivid -> One X -> One S -> ( Evo LTE (thanks xda) -> Droid DNA
I stay HTC.
Checkout my new project at EasyDevStudio
[showp1984] Times of day and sleep are something for weak people - I am a cybernetic organism, and have a sleep mode.
ლ(ಠ益ಠლ)
Come hangout
irc.freenode.net
#teamblackout
|
|
The Following User Says Thank You to Zarboz For This Useful Post: [ Click to Expand ]
|
|
|
|

18th February 2013, 06:56 AM
(Last edited by AlxMAX; 18th February 2013 at 05:50 PM.)
Reason: Details about mkbootimg and unpackbootimg...
|
Senior Member
Thanks Meter 70
Posts: 380
Join Date: Sep 2007
Location: Bucharest
|
Where have you got that ramdisk address from? unpackbootimg doesn't report it.
Quote:
Originally Posted by Zarboz
mkbootimg --cmdline 'console=ttyHSL0,115200,n8' --kernel zImage --ramdisk ramdisknew.gz --base 80400000 --ramdiskaddr 81900000 -o newboot.img
|
Edit: I have done some research on mkbootimg and unpackbootimg and their usage is a little bit confusing. The boot image header contains a kernel address, a ramdisk address and some other data (including the command line provided to the kernel by the bootloader). The mkbootimg tool like it is in the Android repository uses more measures: a base address, a kernel offset, a ramdisk offset etc. The kernel address is base + kernel offset and so on. When unpacking the boot image with unpackbootimg, one must suppose one of the parameters fixed, usually the kernel offset (0x00008000). Consequently, the base address is computed as the kernel address - the kernel offset. To conclude, the command line to use should be:
Code:
mkbootimg --cmdline 'console=ttyHSL0,115200,n8' --base 80400000 --ramdisk_offset 1408000 --kernel boot.img-zImage --ramdisk boot.img-ramdisk.gz -o boot-2.img
This produces the same boot.img as the one posted by flar2, except for the command line.
Edit 2: I have recompiled the kernel, disabled the /system protection, used the mkbootimg command line right above and now my phone boots and runs well. The prima_wlan.ko that I have compiled together with the kernel (3.1.7.16 from codeaurora source repository) doesn't work. It might be a matter of wi-fi firmware. Fortunately, the stock prima_wlan.ko (proprietary 3.1.7.0) module works well.
HTC One XL X325u, O2 DE firmware 3.17.207.3.
HTC Desire A8181 (SLCD, PVT4), CyanogenMod 7 Nightly, Stock hboot.
Samsung Galaxy Tab 2 10.1 P5100, CyanogenMod 10.1
|
|
The Following User Says Thank You to AlxMAX For This Useful Post: [ Click to Expand ]
|
|
|
|

18th February 2013, 09:48 PM
|
Recognized Contributor / Recognized Developer
Thanks Meter 6279
Posts: 4,615
Join Date: Mar 2009
Location: Denver
DONATE TO ME
|
Quote:
Originally Posted by AlxMAX
Where have you got that ramdisk address from? unpackbootimg doesn't report it.
Edit: I have done some research on mkbootimg and unpackbootimg and their usage is a little bit confusing. The boot image header contains a kernel address, a ramdisk address and some other data (including the command line provided to the kernel by the bootloader). The mkbootimg tool like it is in the Android repository uses more measures: a base address, a kernel offset, a ramdisk offset etc. The kernel address is base + kernel offset and so on. When unpacking the boot image with unpackbootimg, one must suppose one of the parameters fixed, usually the kernel offset (0x00008000). Consequently, the base address is computed as the kernel address - the kernel offset. To conclude, the command line to use should be:
Code:
mkbootimg --cmdline 'console=ttyHSL0,115200,n8' --base 80400000 --ramdisk_offset 1408000 --kernel boot.img-zImage --ramdisk boot.img-ramdisk.gz -o boot-2.img
This produces the same boot.img as the one posted by flar2, except for the command line.
Edit 2: I have recompiled the kernel, disabled the /system protection, used the mkbootimg command line right above and now my phone boots and runs well. The prima_wlan.ko that I have compiled together with the kernel (3.1.7.16 from codeaurora source repository) doesn't work. It might be a matter of wi-fi firmware. Fortunately, the stock prima_wlan.ko (proprietary 3.1.7.0) module works well.
|
you have to do some haxxing to get the CAF prima to load up
Building a better droid is the purpose of today
Android History
G1->mytouch 3g -> Mytouch slide -> Mytouch 4g -> HD2 magldr -> Thunderbolt -> Evo 3D -> Sensation -> Evo 4g -> Evo 3D -> HTC vivid -> One X -> One S -> ( Evo LTE (thanks xda) -> Droid DNA
I stay HTC.
Checkout my new project at EasyDevStudio
[showp1984] Times of day and sleep are something for weak people - I am a cybernetic organism, and have a sleep mode.
ლ(ಠ益ಠლ)
Come hangout
irc.freenode.net
#teamblackout
|

20th February 2013, 03:49 PM
|
Senior Member
Thanks Meter 70
Posts: 380
Join Date: Sep 2007
Location: Bucharest
|
Quote:
Originally Posted by Zarboz
you have to do some haxxing to get the CAF prima to load up
|
I am interested of that hack. Could you, please, send me a link to some documentation about it?
HTC One XL X325u, O2 DE firmware 3.17.207.3.
HTC Desire A8181 (SLCD, PVT4), CyanogenMod 7 Nightly, Stock hboot.
Samsung Galaxy Tab 2 10.1 P5100, CyanogenMod 10.1
|

22nd February 2013, 03:50 AM
|
Recognized Contributor / Recognized Developer
Thanks Meter 6279
Posts: 4,615
Join Date: Mar 2009
Location: Denver
DONATE TO ME
|
Re: [KERNEL] Stock Kernel (no write protection)
Quote:
Originally Posted by AlxMAX
I am interested of that hack. Could you, please, send me a link to some documentation about it?
|
There isn't any I have found just trial and error
Sent from my HTC One X using xda app-developers app
Building a better droid is the purpose of today
Android History
G1->mytouch 3g -> Mytouch slide -> Mytouch 4g -> HD2 magldr -> Thunderbolt -> Evo 3D -> Sensation -> Evo 4g -> Evo 3D -> HTC vivid -> One X -> One S -> ( Evo LTE (thanks xda) -> Droid DNA
I stay HTC.
Checkout my new project at EasyDevStudio
[showp1984] Times of day and sleep are something for weak people - I am a cybernetic organism, and have a sleep mode.
ლ(ಠ益ಠლ)
Come hangout
irc.freenode.net
#teamblackout
|
| Thread Tools |
Search this Thread |
|
|
|
| Display Modes |
Linear Mode
|
|
|