MoDaCo is undergoing planned maintenance. Site functionality may be reduced - follow @modaco or @paulobrien on Twitter for updates.

  • Announcements

    • Reminder - MoDaCo position on illegal content

      ILLEGAL CONTENT I'd like to just reaffirm MoDaCo's position regarding piracy and illegal content in the light of some recent questions / postings. Posts will be censored by myself or my moderation team if the contain or link to: Illegal / pirated / cracked software or sites that host such software
      Nintendo emulators / ROMs or sites hosting them (in light of Nintendo's legal stance)


      CUSTOM ROMS

      You may discuss and post links to custom device ROMs on MoDaCo, provided the following rules are adhered to: ROMs must not be hosted directly in topic via the MoDaCo attachment system
      ROMs must not contain any illegal 3rd party software (this includes trial versions included without permission)
      ROMs must give full credit to the original author
      This decision has been taken in light of the huge amount of interest in this area of device customisation within the community, and member feedback! Please note that custom ROM discussion should be kept in specific device sub-areas, (e.g. Kaiser.MoDaCo.com for Kaiser based devices). ISSUES If you have any issues with this policy, please contact me directly via PM. P
    • Support MoDaCo by signing up to a MoDaCo Silver or Gold membership

      To sign up to an annual MoDaCo Silver subscription which will eliminate all ads from the site (as well as giving you access to the MoDaCo Online Kitchens for Android) for only £9.99 using PayPal, Credit or Debit Card, ensure you are logged in to the site, and then click the link below, which will take you directly to the subscription store! You can also sign up to an annual MoDaCo Gold subscription for £29.99, which adds the benefits listed below! PURCHASE A MODACO SUBSCRIPTION - FREE Titanium Backup Mobile for Android worth $5.99! - FREE 1 year PrivateInternetAccess.com worth $39.95! - FREE 1 year LastPass Premium worth $12! - FREE CalcConvert for Pocket PC from Binaryfish worth $17.95! - FREE Calendar Bar for Pocket PC from OmegaOne worth $9.99! - FREE CamerAware for Pocket PC and Smartphone from MoDaCo worth £19.99 / $30! - FREE Chronos for Pocket PC from ActiveKitten worth $14.95! - FREE CodeWallet Pro for Smartphone and Pocket PC from DeveloperOne worth up to $24.95! - FREE Concentrix for Pocket PC from eSoft Interactive worth $9.95! - FREE FlexMail for Pocket PC and Smartphone from WebIS worth up to $59.90! - FREE FTouchSL for Pocket PC from Vekoff s.r.o. worth 10 euro / $12.50! - FREE Jewel Challenge for Pocket PC from eSoft Interactive worth $9.95! - FREE John Cody's Alerts Pro for Smartphone from Omnisoft worth $14.95! - FREE LingvoSoft Talking Dictionary 2008 English <-> Dutch for Pocket PC from Lingvosoft worth $49.95! - FREE LingvoSoft Talking Dictionary 2008 English <-> French for Pocket PC from Lingvosoft worth $49.95! - FREE LingvoSoft Talking Dictionary 2008 English <-> German for Pocket PC from Lingvosoft worth $49.95! - FREE LingvoSoft Talking Dictionary 2008 English <-> Italian for Pocket PC from Lingvosoft worth $49.95! - FREE LingvoSoft Talking Dictionary 2008 English <-> Spanish for Pocket PC from Lingvosoft worth $49.95! - FREE LingvoSoft Dictionary English <-> Dutch for Smartphone from Lingvosoft worth $49.95! - FREE LingvoSoft Dictionary English <-> French for Smartphone from Lingvosoft worth $49.95! - FREE LingvoSoft Dictionary English <-> German for Smartphone from Lingvosoft worth $49.95! - FREE LingvoSoft Dictionary English <-> Russian for Smartphone from Lingvosoft worth $49.95! - FREE LingvoSoft Dictionary English <-> Turkish for Smartphone from Lingvosoft worth $49.95! - FREE Note2Self for Pocket PC and Smartphone from WebIS worth up to $19.90! - FREE Opera 8.60 for Pocket PC and Smartphone from Opera Software worth up to $48! - FREE Pocket Informant for Pocket PC and Smartphone from WebIS worth up to $59.90! - FREE Pocket Launcher for Pocket PC and Smartphone from Conduits worth $9.95! - FREE PTab for Pocket PC and Smartphone from z4soft worth up to $60! - FREE Resco Explorer for Pocket PC and Smartphone from Resco worth up to $49.90! - FREE Safemode for Pocket PC from monocube worth $12.95 - FREE SplashPhoto for Pocket PC and Smartphone from SplashData worth up to $59.90! - FREE Sprite Backup for Pocket PC and Smartphone from Sprite Software worth $29.95! - FREE Teksoft Glyphs UI for Pocket PC and Smartphone from Teksoft €9.95! - FREE Teksoft HeadsetRemote for Pocket PC and Smartphone from Teksoft €4.95! - FREE Traffic Jam for Pocket PC from eSoft Interactive worth $9.95! - FREE unlock (1 per year) from imei-check.co.uk - DISCOUNT of 10% at MoDaCo FairDeal - DISCOUNT of 10% at Semsons.com - FORUM - AD FREE SITE - FORUM - custom rank / title - FORUM - double competition entries - FORUM - double post attachment space - FORUM - no search flood control - FORUM - priority event registration - FORUM - triple PM space
    • Reminder: Selling items on the forum directly is not allowed

      Please note that selling items on the forum directly is not allowed by the forum rules. There is a forum for eBay auctions whereby you can list the items on eBay and link to them there. This is the ONLY forum for this type of activity. You may also advertise links to the eBay forum in your signature. Please note that selling directly in contravention of these rules will result in a warning / suspensions / ban.
Sign in to follow this  
Followers 0

[Kernel] init.d support for ZTE Blade V

25 posts in this topic

Posted (edited) · Report post

What is this?
It's a boot image which adds support for init.d scripts.

What does that mean?
By flashing this to your phone, it gives support for custom scripts to be executed at boot time.  There are plenty of examples of the kind of mods this will allow, see this post as an example.

Prerequisites
You must be rooted and ideally have CWM recovery installed.  This post tells you how to do both of these things.

Next, boot the phone to recovery and MAKE A BACKUP - flashing a new boot image is not without risk.

How do I test if it will work for me?
You can test the install without permanently flashing it to your phone, I'd suggest you do this first if you have any concerns.  You will need to have set up the ZTE USB drivers and have fastboot working on your computer, again see this post for details.

1. Download init.d-test.zip and put it somewhere on your phone that you can find it again, for example in the root folder
2. Download boot-gah0.9-8225uk2.2.img and put in on your computer in the folder that contains fastboot.exe
3. Connect your phone via a USB cable to the same computer
4. Reboot your phone and hold volume down to boot into CWM recovery
5. install zip → choose zip from sdcard → (find init.d-test.zip) → Yes to install
6. +++++ Go Back +++++ → advanced → reboot to bootloader
7. When the green android appears, on your computer navigate to the folder containing boot-gah0.9-8225uk2.2.img and type
 

fastboot boot boot-gah0.9-8225uk2.2.img

Give your phone a few seconds and it should boot normally.  To check that the new boot image has worked, use a file explorer to navigate to /data/local/tmp and look for a file named 00confirm.txt.  If the file exists, congratulations, the boot image works for you.  You can safely delete /data/local/tmp/00confirm.txt and also /system/etc/init.d/00confirm (make sure you use a root explorer to mount /system as rw first).

You can now permanently flash the image if you wish.

How do I install after testing?
If you haven't done a test install, I suggest you try the above first.  To flash the image you will need to have set up the ZTE USB drivers and have fastboot working on your computer, again see this post for details.

1. Download boot-gah0.9-8225uk2.2.img and put in on your computer in the folder that contains fastboot.exe
2. Connect your phone via a USB cable to the same computer
3. Reboot your phone and hold volume down to boot into CWM recovery
4. advanced → reboot to bootloader
5. When the green android appears, on your computer navigate to the folder containing boot-gah0.9-8225uk2.2.img and type
 

fastboot flash boot boot-gah0.9-8225uk2.2.img
fastboot reboot

Congratulations, your Blade V now has init.d support!

What next?
Create a script to do something cool and put it in the /system/etc/init.d folder.  Don't forget to give the script execute permissions (755 suggested).  The script should run every time your phone is booted.  If it's really cool, make sure you share :)

Technical details
I extracted boot.img from the UK v2.2 stock ROM, specifically, this.  I split the image, unpacked the ramdisk, added a hook to execute init.d scripts to init.rc then repacked it all.  The kernel itself is untouched, only the ramdisk was modified.

Credits
100% of the credit for this goes to KonstaT.  Not only did he encourage me and patiently tell me where I was repeatedly going wrong, he also wrote most of the code!
 

[edit]

Update links.

Edited by shiftyc
1

Share this post


Link to post
Share on other sites

Posted · Report post

I can confirm that the kernel works as intended. Nice one!

0

Share this post


Link to post
Share on other sites

Posted · Report post

Great, thanks for confirming.  Hope it helps with your project.

0

Share this post


Link to post
Share on other sites

Posted (edited) · Report post

Thanks guys!

Edited by djfnz
1

Share this post


Link to post
Share on other sites

Posted · Report post

Great stuff! Does this mean overclocking cpu is possible now?

0

Share this post


Link to post
Share on other sites

Posted · Report post

I don't think so.  I think the kernel would need higher frequencies added to it for that to work.  Then once that's done, init'd would be one way (amongst others) of setting the desired frequency.

0

Share this post


Link to post
Share on other sites

Posted · Report post

Correct, I didn't modify the kernel itself because I couldn't get ZTE's source to compile.

 

I've now got it to compile which should open up more possibilities, including overclocking.  Oddly, the zImage from my compile is 5MB whereas the one ZTE released is 4.5MB so that's not a great start.

0

Share this post


Link to post
Share on other sites

Posted · Report post

Oddly, the zImage from my compile is 5MB whereas the one ZTE released is 4.5MB so that's not a great start.

Does your kernel boot? What defconfig did you use?
 
You can extract defconfig from a running device (/proc/config.gz) or from stock zImage by using extract-ikconfig script.
0

Share this post


Link to post
Share on other sites

Posted · Report post

Thanks, I did extract the defconfig from my running phone.  Kernel boots just fine.

0

Share this post


Link to post
Share on other sites

Posted · Report post

Im sorry for off-topic i need to ask something KonstaT, here is my problem i have flashed MIUI for blade V in my blade III pro with Blade V boot.img and rom booted but touch dont works only power key is working and i tried with my stock boot.img, apps were optimizing the same procedure as blade V boot.img but the phone after apps optimizing again goes to bootanimation and its stucked here and only LED Notification is going on here is logcat:

https://drive.google.com/file/d/0B0LcuL3pgqjydEhmRnRpTV9STUU/edit?usp=sharing

0

Share this post


Link to post
Share on other sites

Posted · Report post

Thanks, I did extract the defconfig from my running phone.  Kernel boots just fine.

What toolchain did you use? It can make a small difference in size (0.1-0.2 mb) but I doubt that much. I can't remember if the kernel I built had any major differences in size compared to stock.
 
Most likely it just indicates that ZTE has releases non-GPL compliant source that doesn't match the binary kernels shipped in devices.
0

Share this post


Link to post
Share on other sites

Posted (edited) · Report post

 

What toolchain did you use? It can make a small difference in size (0.1-0.2 mb) but I doubt that much. I can't remember if the kernel I built had any major differences in size compared to stock.

 

I used r7 of the android NDK, I guess I could try a newer revision.  Oddly my boot.img comes out at 7.1mb versus 7mb for the stock, so the bloated zImage compresses well.

 

[edit]

I reset everything and compiled with the r9d toolchain.  This time zImage is 4.8mb and boot.img is 6.9mb.  So zImage still larger, boot.img smaller (??)  Still seems to boot OK so I'll go with the smaller boot.img and pretend that the reduced size is due to my "optimisations" lol.

 

 

Most likely it just indicates that ZTE has releases non-GPL compliant source that doesn't match the binary kernels shipped in devices.

 

 

I came to the same conclusion.  The fact that it doesn't even compile without tweaking means it can't be the version they shipped.

 

I've been running my compiled version for almost 48 hours without any issues so it looks fine.

 

I started to read up on adding governors, I thought I'd start with smartassV2 as it's one I've used before in CM etc.  But it's a huge learning curve, so much to understand and so much of the info our there is contradictary.  Anyway, I was making some reasonable progress in understanding when I came across a recent IRC chat log where an experienced kernel dev was ridiculing someone for adding smartassV2 to a dual core device, as it was originally intended for single core.  And here I am trying to add it to a quad core.  Maybe back to the drawing board!

Edited by shiftyc
0

Share this post


Link to post
Share on other sites

Posted · Report post

Interesting.  I'd just have used SmartAssv2 as well if it was in there.  Never considered the whole single vs multi-core thing!

0

Share this post


Link to post
Share on other sites

Posted · Report post

With smartassV2 it's not even a case of "just" adding it.  It works on a principle of what it calls "ideal" frequencies.  So before you even include it, you need to supply a value of what you believe is the ideal frequency to aim for when the device is awake and when it's suspended and the deltas for ramping up and down.

 

Like I said, a lot to get your head around and a lot of conflicting info.  I think instead of trying to reinvent the wheel I need to KANG someone's else's work!

0

Share this post


Link to post
Share on other sites

Posted · Report post

Any news guys?

0

Share this post


Link to post
Share on other sites

Posted · Report post

Is here some one who fix this problem ?

 

I have the same problem on stock rom and on miui rom too.

 

Notification sometime works sometimes doesnt. Its the same on wifi or 3g. Push notification have big dealey. I have this probem with facebook messages, whatsapp and others .... Have you got someone this problem?

 

thanks

0

Share this post


Link to post
Share on other sites

Posted · Report post

Any news guys?

 

Not really.  I tried a couple of governors but couldn't get them to compile, I seem to be missing a lot of dependencies.

 

If I'm reading the source correctly, the stock kernel includes some additional frequencies for our chipset, so I though overclocking would be easier.  I increased the maximum frequency that the kernel allows, but when I tried to install some overclocking apps, it didn't let me select anything higher than 1.21GHz.

 

There's also an option to enable USB OTG.  I tried this and got a bunch of compilation errors.  After a few hours of debugging I was able to get it compiled, but once again, when I tried a USB powered hub it didn't detect any devices.

 

So nothing very successful at all, and at the moment I have no time to work on it further.

 

Is here some one who fix this problem ?

 

I have the same problem on stock rom and on miui rom too.

 

Notification sometime works sometimes doesnt. Its the same on wifi or 3g. Push notification have big dealey. I have this probem with facebook messages, whatsapp and others .... Have you got someone this problem?

 

thanks

 

Sorry, I don't have the skills for that.  But I would question whether it's a kernel bug anyway because I don't have this problem.

0

Share this post


Link to post
Share on other sites

Posted · Report post

Hello, which .config did you use? I have tried the one from your kernel (/proc/config.gz) but it doesn't work(compiled, but I have some problems with screen)

1

Share this post


Link to post
Share on other sites

Posted (edited) · Report post

Hello, which .config did you use? I have tried the one from your kernel (/proc/config.gz) but it doesn't work(compiled, but I have some problems with screen)

Very nice to see someone working on kernel , hope to make it work good , so it will boost our phones more !!!!
Regards!!!!! Edited by gkalen
0

Share this post


Link to post
Share on other sites

Posted · Report post

As first thing , i have to get it working with default configuration. If it will work, then i can add some tweaks maybe

0

Share this post


Link to post
Share on other sites

Posted · Report post

As first thing , i have to get it working with default configuration. If it will work, then i can add some tweaks maybe

I understand , hope it will work !!!
0

Share this post


Link to post
Share on other sites

Posted · Report post

Hello, which .config did you use? I have tried the one from your kernel (/proc/config.gz) but it doesn't work(compiled, but I have some problems with screen)

 

I had the UK v2.2 stock installed on my phone and I extracted the .config from that.  I then used it to compile the UK v2.2 source.

 

What kernel source are you using?

0

Share this post


Link to post
Share on other sites

Posted · Report post

nothing, it don't even compile :angry:

0

Share this post


Link to post
Share on other sites

Posted · Report post

nothing, it don't even compile :angry:

 

Well if you want some help, you need to give more clues.  What OS?  What toolchain?  What did it say on screen, any errors?

0

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!


Register a new account

Sign in

Already have an account? Sign in here.


Sign In Now
Sign in to follow this  
Followers 0

MoDaCo is part of the MoDaCo.network, © Paul O'Brien 2002-2015. MoDaCo uses IntelliTxt technology.