[Q] Grand Unified Boot Loader (GRUB) for Ideos X5 / U8800 - Huawei Ideos X5 U8800

Now that we have Recovery and Overclocker boot images, can we make a menu based bootloader like GRUB that could chainload a chosen OS from a chosen storage device?
In our case, we could choose to load, say, our choice Froyo, Gingerbread, Generic Linux or even a FreedomBox kernel during recovery boot. This from the SD card instead of internal Nand if we choose!
Much less likely to wear out our irreplaceable internal 4gb internal nand storage than all this flashing that we will otherwise be doing.

Once we have the choice of all of these it would be very nice to see!

Recka said:
Once we have the choice of all of these it would be very nice to see!
Click to expand...
Click to collapse
Haha I think you're a bit ambitous man. I would be happy with a stock/root/overclock rom for now. A quick googling doesn't show anything worthwhile. have you seen this done before? Can you post the link?

Recka said:
Once we have the choice of all of these it would be very nice to see!
Click to expand...
Click to collapse
thats possible

Snapdragon boot factors
I hope I'm not being too ambitious. If our purple "access storage device" screen slots us into the boot process before the Kernel (Command Core) part of the Android OS is loaded, then a multi option boot menu should be quite easy to do.
Can anyone here confirm where in the boot the purple screen is?
I read somewhere that the recovery image must be signed, so I guess the Purple Screen is BEFORE the Cryptographic Look-aside Processor (CLP) has finished doing its thing and hands over to the Secondary Boot Loader (SBL). Is this correct?
It could be as easy as modifying the factory recovery menu if the Huawei source code files include it, or modify Clockwork or Stockwell's menus for which we probably have quite good source code listings.
There are good resources that describe the Snapdragon processors' (Arm 9 & 11 combo) boot process on the 'net too.
I've not seen GRUB working in the Android phone world but there are a few dual boot solutions, including one right here at XDA, 100+ pages of it!. The "Gen.Y DualBOOT: Dual boot solution for Windows Mobile devices with XDANDROID". http://forum.xda-developers.com/showthread.php?t=623792
Poulsen8r said:
Haha I think you're a bit ambitous man. I would be happy with a stock/root/overclock rom for now. A quick googling doesn't show anything worthwhile. have you seen this done before? Can you post the link?
Click to expand...
Click to collapse

Related

[ATTN] - 3991 and 4349+ VIEWSONIC-RECALLED BOOTLOADER INFO here - UPD 5/8/11

Updated 05/08/11
ATTENTION - IF YOU ARE ON STOCK 4349+ or any MOD BASED OFF 4349+ USING THE NEW RECALLED BOOTLOADER! READ PLEASE!
Starting with the most recent but recalled update to Tap N Tap Viewsonic has introduced a new Bootloader being called the 1.2 bootloader. This bootloader is not compatible with mods or Roms based off of the Viewsonic Current Bootloader being called the 1.1 bootloader! This bootloader provides absolutely no known advantage other than being able to boot any new STOCK kernels. If you would like to use any of our stable ROM's (i.e. Vegan 5.1.1, Vegan GingerEdition and currently CM7) using Viewsonics currently supported and shipping bootloader (1.1) you must Downgrade your bootloader and TNT Version before you flash a new kernel or a new ROM.
Please download the following downgrade update.zip and place it on your sdcard renaming it to "update.zip".
http://www.gtabdevs.com/releases/4349_Downgrade.zip
Then power down your device. And power back up while holding the power button and vol + till your display says "recovery key detected" in the top left corner.
Using the volume keys to navigate up/down in the menu highlight "Apply Internal update.zip" if you copied the update.zip to the internal memory or "Apply External SDCard update.zip" if you happened to place it on an external SDCard and then inserted it before booting to recovery. Now select the menu choice using the menu key.
This process will take a few minutes. You will see a Box with an arrow and a progress bar while it applies the update.... when it is finished it will reboot to make the changes. Once the changes are complete your tablet will boot into Tap N Tap version 3588.
You are now free to follow all the tutorials about installing CWM and/or Kernels/Roms.
Thank you and good luck.
Be aware. I am not connected with Viewsonic in any way. I make no assertions as to the validity nor the safety of anything in this post. Do anything above at your risk.
That is a handy utility to have. Thanks!
How do we check if the bootloader is locked? I'm curious if the bootloader.bin in 3991 (which is based off the same branch) has this same issue.
Thanks!
Strange. One step forward and two steps back for Viewsonic. But, maybe, this means there is still some interest from Viewsonic for our tablet and chance for further development (maybe even Honeycomb).
roebeet said:
How do we check if the bootloader is locked? I'm curious if the bootloader.bin in 3991 (which is based off the same branch) has this same issue.
Thanks!
Click to expand...
Click to collapse
If it too will not boot any other kernel besides a stock kernel built specifically for their new bootloader. That bootloader.bin also appears to be locked.
gojimi said:
If it too will not boot any other kernel besides a stock kernel built specifically for their new bootloader. That bootloader.bin also appears to be locked.
Click to expand...
Click to collapse
Does that mean it's locked, or does that mean that we just don't have the new source code to build custom kernels? I just want to distiguish because, if it's the latter, we can just ask them to release that like they did the 1.1-based source. EDIT: Already tweeted them. I see "1.1" in the source that's there, and we know that this is "1.2", so maybe there's new source code to be requested? Not sure.
I know that we can check for a locked bootloader with something like fastboot, but I don't think that works here. That's why I was asking.
Thanks again!
gojimi said:
If it too will not boot any other kernel besides a stock kernel built specifically for their new bootloader. That bootloader.bin also appears to be locked.
Click to expand...
Click to collapse
what could the thinking possibly be to locking the bootloader on a product like ours?
I'm seriously asking, besides being dicks, what would the reasoning be?
roebeet said:
Does that mean it's locked, or does that mean that we just don't have the new source code to build custom kernels? I just want to distiguish because, if it's the latter, we can just ask them to release that like they did the 1.1-based source.
I know that we can check for a locked bootloader with something like fastboot, but I don't think that works here. That's why I was asking.
Thanks again!
Click to expand...
Click to collapse
By all means ask for their new source... though I do not believe at this point they are required to give... maybe they are. So for the purposes of everyone else's understanding this is a LOCKED bootloader in the sense that we are LOCKED to their kernel...... nothing ever stays locked forever.... this is not however LOCKED in the terms that a select few who already know what's going on with this bootloader typically use the term LOCKED. Take it as you will.
snapz54 said:
what could the thinking possibly be to locking the bootloader on a product like ours?
I'm seriously asking, besides being dicks, what would the reasoning be?
Click to expand...
Click to collapse
To be honest they are probably tired of all the people calling viewsonic support with issues that are not on OFFICIAL viewsonic software... most companies try to do something to deter this activity in some regards.
Does nv flash still works to downgrade everything?
gojimi said:
To be honest they are probably tired of all the people calling viewsonic support with issues that are not on OFFICIAL viewsonic software... most companies try to do something to deter this activity in some regards.
Click to expand...
Click to collapse
I understand this for "most companies" but Viewsonic is the company that openly linked on their product page that XDA is the place to be if you need support or any real use from your gtab.
We had to fight them to finally stop doing that. It doesn't really add up.
The only thing this does if it works is effectively pull the plug on the life support that was pumping any further life into the tablet.
We still have great "legacy" roms and infrastructure that make the tablet great. but moving forward all this does is concentrate our efforts towards them. releasing a workable open solution keeps us busy tinkering with it for months. Locking things down only sends us back to twitter and the like but now we have more members thanks to the new OD, TD, and amazon users.
I thought VS said they were going to work with the devs. Didnt they contact you guys? I thought they would of asked or told you guys what the best way for them to go would be. Did this never happen?
Pazzu510 said:
Does nv flash still works to downgrade everything?
Click to expand...
Click to collapse
Yes, maybe. I had to NVflash mine because I accidentally flashed CWM over 4349 while i was playing in the 4349 recovery screen. The NVflash process worked, but for some reason my touch screen was borked (no touches were registered). Couldn't do anything. In the past a couple restarts with calibration.ini on the external SD would clear that for me, but didn't this time. I ended up doing NVflash with CWM as part9.img and then repartitioned with CMW and NVflashed again with stock recovery part9.img. Screen was still borked but cleared up with a couple restarts with calibration.ini on an external SD. So the answer is yes you can, but it may not be as smooth as you are used to. Of course it may work fine for you.
Matt
jasco13 said:
Yes, maybe. I had to NVflash mine because I accidentally flashed CWM over 4349 while i was playing in the 4349 recovery screen. The NVflash process worked, but for some reason my touch screen was borked (no touches were registered). Couldn't do anything. In the past a couple restarts with calibration.ini on the external SD would clear that for me, but didn't this time. I ended up doing NVflash with CWM as part9.img and then repartitioned with CMW and NVflashed again with stock recovery part9.img. Screen was still borked but cleared up with a couple restarts with calibration.ini on an external SD. So the answer is yes you can, but it may not be as smooth as you are used to. Of course it may work fine for you.
Matt
Click to expand...
Click to collapse
I've nvflashed back to 1105 at least a dozen times since last night (was doing upgrade / downgrade scenarios). So far, so good.
The bootloader is provided by viewsonic I think, it may be the key for some chipset feature, some other brand of tablet like the adam already has the same exact one
it's probably not locked but only doing something different like you said!
if I had to guess, they didn't lock it to be pricks...odds are it is locked to prevent people from flashing our current kernels to this to avoid messing things up...
so here's prolly how we'll be structuring our ROMs/Kernels now...1.1-based Froyo ROM; 1.2-based Froyo ROM; 1.1-based Froyo Kernel; 1.2-based Froyo Kernel and so on for GB if we're lucky HC in the future.
It's going to be a pain in the butt in the short-term, but long-term it'll only benefit current and future gTab owners as a whole if we stick to the 1.2 path alongside the vendor. This will keep confusion to a minimum, features to a maximum, and upgradability easy.
Thanks to all devs for their future support even through some of the PITA times
i have no options to choose between, aka no menu when i do all that, it just goes to a box picture and then reboots and loads normally.
Edited...You can't fix stupid
iamnottypingthis said:
i have no options to choose between, aka no menu when i do all that, it just goes to a box picture and then reboots and loads normally.
Click to expand...
Click to collapse
There is no menu. It takes you back to 3588 and the ability to flash all current roms.
So this "rollback" is jsut a stock 3588 image, or is it something different?

[Q] Boot Linux in RAM with Fastboot [Experienced users only]

Plot: I have a Nexus 4 with a broken nand memory, I bought a £32 nexus 4 16gb from eBay with a broken glass and broken digitizer, I replaced the motherboards and voila, I have a working Nexus 4 and a device with a broken digitizer that won't go pass boot.
So, my "broken" nexus 4 doesn't have a working touchscreen, nor a NAND memory, but what it has 2GB of RAM and a nice processor it's the ability to boot an image with Fastboot, eg: I've booted stuff like Clockworkmod Touch Recovery or TWRP Touch Recovery.
What I would love to do is to boot a Linux version on my broken nexus and use it as a web server, or other stuff like ... display my CCTV cameras, since the display still works...
I tried multiple ARM variants, and the closest I got was with distro.ibiblio.org/tinycorelinux/4.x/armv6/piCore.gz . It was the only image small enough to download via fastboot, but... it's stuck at booting, probably I need to do smt else for it.
Has anybody got any tips for me? Anybody tried it before?
My plan would be:
1. Boot successfully any linux kernel
2. Buy an OTG Y cable to connect an external HDD.
3. Create a linux image that would boot from that external HDD
4. Control my new "linux server" via SSH
Hope this post will get some attention, I think it could be a nice thing for old unused phones as well as phones with broken displays that nobody took the time to repair.
tcr92 said:
Plot: I have a Nexus 4 with a broken nand memory, I bought a £32 nexus 4 16gb from eBay with a broken glass and broken digitizer, I replaced the motherboards and voila, I have a working Nexus 4 and a device with a broken digitizer that won't go pass boot.
So, my "broken" nexus 4 doesn't have a working touchscreen, nor a NAND memory, but what it has 2GB of RAM and a nice processor it's the ability to boot an image with Fastboot, eg: I've booted stuff like Clockworkmod Touch Recovery or TWRP Touch Recovery.
What I would love to do is to boot a Linux version on my broken nexus and use it as a web server, or other stuff like ... display my CCTV cameras, since the display still works...
I tried multiple ARM variants, and the closest I got was with distro.ibiblio.org/tinycorelinux/4.x/armv6/piCore.gz . It was the only image small enough to download via fastboot, but... it's stuck at booting, probably I need to do smt else for it.
Has anybody got any tips for me? Anybody tried it before?
My plan would be:
1. Boot successfully any linux kernel
2. Buy an OTG Y cable to connect an external HDD.
3. Create a linux image that would boot from that external HDD
4. Control my new "linux server" via SSH
Hope this post will get some attention, I think it could be a nice thing for old unused phones as well as phones with broken displays that nobody took the time to repair.
Click to expand...
Click to collapse
Sounds like an interesting project, but why not you just replace the phone? Google will accept your phone (even if you didn't buy it from them) in almost any condition and give you a replacement if you call them (85583NEXUS is the number)
If you are really interested, I was able to get a 3.6 kernel running on my galaxy nexus about a year ago by building it myself. Any prebuilt images will surely not work. Even though I got the kernel running, it was basically worthless as I did not have any mechanisms of controlling it, you could try configuring it to boot from your hard drive to get an SSH session running.
How come you didn't go through warranty for the initial NAND issue?
That said, you might be able to modify a ramdisk to point your partitions to those on a usb disk (of course with an otg capable kernel). Or perhaps you could look into multirom/kexec hardboot, and be reliant on the initial fastboot boot just to kick that into action. Multirom bases off twrp though, so that'd be hard to execute without a working digitizer. If anything, you could branch off that idea (if you can't manage to directly tweak your ramdisk to mount everything off a usbdisk)..
If anything, see if it's google would replace the phone for the bad nand. Swap the board back.. Then you'd end up with "just" a back digitizer and be in a much better position.
ziddey said:
How come you didn't go through warranty for the initial NAND issue?
That said, you might be able to modify a ramdisk to point your partitions to those on a usb disk (of course with an otg capable kernel). Or perhaps you could look into multirom/kexec hardboot, and be reliant on the initial fastboot boot just to kick that into action. Multirom bases off twrp though, so that'd be hard to execute without a working digitizer. If anything, you could branch off that idea (if you can't manage to directly tweak your ramdisk to mount everything off a usbdisk)..
If anything, see if it's google would replace the phone for the bad nand. Swap the board back.. Then you'd end up with "just" a back digitizer and be in a much better position.
Click to expand...
Click to collapse
I don't think google would have accepted it because:
- NAND Memory failed 99% because I flashed Franco Kernel's nightly version every... night.
- Obviously the phone's bootloader was unlocked and for some reason I haven't managed to lock it
- The back was cracked
I guess I can use my working version to play around with the kernel till it does what I want, I'll look into multirom/kexec. Any idea where can I get a good OTG Y-Cable. I've seen some, but I want to go for one proven to work well.
Bleh, there are times when I'm testing some code and end up flashing boot 100 times a day.
ziddey said:
Bleh, there are times when I'm testing some code and end up flashing boot 100 times a day.
Click to expand...
Click to collapse
Yeah, me flashing may not be the reason, however, my phone had the back cracked and a bit of the middle line damaged, so I bet nobody would have fixed it on warranty. I got really cheap and fast getting a replacement on ebay with a broken screen and do the swap, I posted two images below to show that the nand was really just... write only (is).
i.imgur.com/2VrVw6U.png - Via LG's Own Recovery Software (I know the DLL is wrong, but it's supposed to work) // i.imgur.com/SJDmTk9.png (Via Fastboot)
Sorry for not being able to post images, still have to go up to 10 posts. I've been quite selfish so far and only got info from XDA, promise if I will get anywhere with this threat I'll make a tutorial of how to do it and an example of a useful thing you can do with a broken phone .
==============
Anw, back on the subject, can anybody help me with how to install MultiBoot on a USB Stick? I would assume the things will go as follows: Have some magic on the USB stick, have a boot image that boots from there (via FASTBOOT) ==> multiboot boots my desired OS from the USB stick as well.
not sure what you're doing there for the second picture. Looks like some sort of script..
first pic looks fine. It's supposed to only get to 85%.
As for multirom, it's on you to learn how to create a ramdisk->boot.img that will mount usb partitions instead of mmcblock.
ziddey said:
not sure what you're doing there for the second picture. Looks like some sort of script..
first pic looks fine. It's supposed to only get to 85%.
As for multirom, it's on you to learn how to create a ramdisk->boot.img that will mount usb partitions instead of mmcblock.
Click to expand...
Click to collapse
It's supposed to get to 85% and restart. However it does not, I restarted it manually into bootloader, and tried to use flash-all.bat from the flashfactory for my model.. and then I get all of those write errors (as before) (that was a try to flash a custom recovery with Nexus Toolkit, I tried it manually). As a note, erasing all the partition works, formatting emmc partition obviously doesn't, formatting ext4 partitions: starts creating the filesystem, the partition is sent and then ... BOOM failed flash write failure as when I am trying to flash anything else.
As for the ramdisk and all, I shall use my medium Linux experience to dig into that and I'll let you guys know if I will get anywhere. For now I'm doing my best to make my own Y Cable ... this will be tricky.
Thanks to all of you who support my post, it's really cool to find a place where I can talk about stuff like this. I really hope if I manage to get somewhere I will make a tutorial that will help someone to put their old/bricked phones to good use.

Android to Windows Hack or Dual boot Option?

So im thinking of purchasing one of these when the come out here and i was wondering about an android to windows os hack. Will there be one in the immediate future and will dual booting be an option?
The hardware is exactly the same.
There must be a way to dual boot, hopefully others on this forum can figure out how to do this if Lenovo doesn't facilitate dual boot themselves
Best
I believe there's a different BIOS for Win vs Android. Could have sworn I saw the Windows BIOS posted on the Lenovo support site prior to the Oct 17 launch. It seems gone now though, unless I'm missing something or went to the wrong link? Unlikely you can install Win without a different BIOS.
There is some clear hardware differences with the Android and Windows tablets. Specifically, 2 different physical layouts for the halo keyboard, where the windows one has defined left and right mouse click buttons. There doesn't seem to be any way of accessing the BIOS on the Android tablet, and it does have the usual Android power + volume up, power + volume down recovery options, so it looks like it boot directly to the boot loader.
The Bios is still there ... but how would you flash it?
http://support.lenovo.com/de/de/products/Tablets/Yoga-Series/YOGA-Book/downloads/DS119182
ok so there is also android open source code available in their site, any chance of making a custom rom?
I wonder if we could flash the Chuwi 12 roms onto this given that Chuwi12 has dual boot already?
This is reallly really stupid to me, why not provide dual boot in the first place? I would not mind shelling out $100 more for a dual boot version. Now if I want the windows version I will need to spend another $550 to get another OS with the same device. I will end up having 2 same devices, but that is so anti-mobile really. Do I have to carry 2 hardware devices so i can have 2 OSes at the same time?
Lenovo get some grip please and provide a dual OS version.
win 10 driver
Today, the windos 10 drivers are online..
The drivers you get with levono support with input of the serial number
It must now be possible to build a dual system
Tastertur chipset audio and more .
igelelf said:
Today, the windos 10 drivers are online..
The drivers you get with levono support with input of the serial number
It must now be possible to build a dual system
Tastertur chipset audio and more .
Click to expand...
Click to collapse
Could you post the link for the windows 10 drivers? also any idea on how to unlock the bootloader?
Hi,
earthCallingAngela did unlock the bootlader. .
My background knowledge about booting is very low. But I think there are huge differences between Android and Windows. I think If a system can boot via PC-Bios or Android-Boot-Loader is "on the chip". If this is correct you would need a Android-Boot-Loader that does boot into a windows ... IMO this is no "easy to do". May be the guys who did create Remix OS found a way to do that ...?
Can we use Chuwi 12's disk image somehow? It comes with dual boot.
hajkan said:
Can we use Chuwi 12's disk image somehow? It comes with dual boot.
Click to expand...
Click to collapse
Are the two the same hardware? My understanding is that unless the hardware is very similar, you can't use other ROMs without a *TON* of work.
so i was able to install android x86 6.0 on my yoga book, unfortunately i managed to do it over my windows install so now i just need to reinstall windows lol.....
---------- Post added at 06:35 PM ---------- Previous post was at 05:54 PM ----------
decided to install 7.0 over my 6.0 install i just made and messed everything up. now im back to just trying to get gparted to run so i can reformat and start over.
bisharat said:
Could you post the link for the windows 10 drivers? also any idea on how to unlock the bootloader?
Click to expand...
Click to collapse
http://support.lenovo.com/kr/en/pro... and Software|Drivers and Software&beta=false
you can download yogabook win10(64bit) driver here.
edited--
you should change operating system dropdown menu from android to windows10
Hi & Happy New Year
Now it's possible to get root with android version
I have a YogaBook with Windows version ; Someone can make a backup Android version?
Maybe it's possible to create a dual boot with the windows version I cross the fingers :fingers-crossed:
Where and how?
ThomasHardy said:
Hi & Happy New Year
Now it's possible to get root with android version
Click to expand...
Click to collapse
someone can said me, where i found an android image? (original yoga book, of course) i try to install Remix OS and Android-x86 6.0-r1 released from Android-x86.org but, its can't run. graphics issues and reboot.
i install in a MicroSD and boot it booting yogabook hold volume up + power boton and select boot menu, but it fail on boot.
i have yoga book windows. any idea?
thanks
sorry for my english..
I'm exploring this as well.
Since the BIOS and drivers available (just tested with my serial#), it does seem like it would be relatively easy to dual-boot, provided you can get past the loader issue.
I've done many dual-boot setups, just not since the Win7 days, with the Win8 and forward it's gotten quite a bit trickier, the loader does a bunch of "extra" stuff, boot timing and such, to protect itself.
I've also never done an Android/Windows dual-boot, mostly just Win/Win or Win/Unix.
I think you'd have to figure out how to bootstrap these, so the custom loader can take over, and load from there, but this is a bit beyond my Android capabilities.
Has anyone even tried this? I assume the power/volume keys must work, to get at the loader?
Hi there !
I've just unlocked my Yoga Book's android bootloader and made a backup. I'm trying to install Windows 10 and replace Android with it. The problem is that I don't know how to boot the device from the USB drive.
Does anyone know how to do that ? Even if rooting is required ?
P.S. : I can't google it as all results link to "how to boot a PC from android device", which is the reverse...
Totjoss said:
Hi there !
I've just unlocked my Yoga Book's android bootloader and made a backup. I'm trying to install Windows 10 and replace Android with it. The problem is that I don't know how to boot the device from the USB drive.
Does anyone know how to do that ? Even if rooting is required ?
P.S. : I can't google it as all results link to "how to boot a PC from android device", which is the reverse...
Click to expand...
Click to collapse
simple...you can't do that! it's not possible to boot usb from android bootloader or recovery.

EFIDroid

Just wondering if anyone has looked into this, and what it could possibly mean for our device if we could be merged. Apparently there's no need for special kernel modules, bootloader edits, or KEXEC, and I think it would be pretty cool to be able to use multi ROM to boot back and forth between stock and AOSP.
Why don't you explain what this is and provide a few links?
lafester said:
Why don't you explain what this is and provide a few links?
Click to expand...
Click to collapse
https://www.xda-developers.com/efidroid-is-a-second-stage-bootloader/
This article was the first I'd heard of it. But it does seem like it might be something easy to implement. It's basically multi ROM, but without all the requirements.
Looks interesting.
is it possible to dualboot into that one OS called sailfish or something? even ubuntu mobile?
gecko702 said:
is it possible to dualboot into that one OS called sailfish or something? even ubuntu mobile?
Click to expand...
Click to collapse
This is to make the phone able to boot two different working roms. Say, you will be able to boot stock or RR without changing roms in TWRP. It won't boot roms that haven't been ported to our phone...
This is very, very interesting. I love the thought of just using LineageOS or RR for everyday things and then just switching to stock when I want to use media and enjoy the fantastic sound.
I'm not a developer, but I'd like to help/contribute in any way possible if someone's working on bringing unofficial support to the Axon 7.
jimbo77 said:
This is to make the phone able to boot two different working roms. Say, you will be able to boot stock or RR without changing roms in TWRP. It won't boot roms that haven't been ported to our phone...
Click to expand...
Click to collapse
Very true. However, it makes ROMs easier to port and for more people to test, as then people can try them out without wiping their phone each time they want to try.
I was able to port and build right up until the last step where you generate lk.img and fastboot it to the phone. I'm running Linux inside a virtual machine and it doesn't seem to want to communicate, though adb does work.
I might try on the weekend to boot linux off a hard drive and see if it will work..
In the mean time, if someone else wants to try to build, it's really simple just follow these two guides:
https://github.com/efidroid/projectmanagement/wiki/[EFIDroid]-Getting-Started
https://github.com/efidroid/projectmanagement/wiki/[EFIDroid]-Porting-a-new-device
I tried again, but when I fastboot the generated lk.img to the phone, it just turns off instead of loading the splash screen.
I used the TWRP recovery .img for the create_device step. Maybe that's unacceptable, though it built the lk.img without error.
Anyone else trying this?
twoi said:
I tried again, but when I fastboot the generated lk.img to the phone, it just turns off instead of loading the splash screen.
I used the TWRP recovery .img for the create_device step. Maybe that's unacceptable, though it built the lk.img without error.
Anyone else trying this?
Click to expand...
Click to collapse
Did you try this fix for arm64 devices?
https://github.com/efidroid/projectmanagement/issues/89
Seems you need to dump aboot to check what's the correct address for LK to boot.
Edit: also did you try using freeza Beastmode boot.img? Probably that's better
Thanks for the reply.
I dumped aboot and replaced the address but sadly it just makes the phone reboot, I used the beastmode boot.img at the same time.
I'm a bit in over my head at this point hah, but someone in that thread had the same results..
twoi said:
Thanks for the reply.
I dumped aboot and replaced the address but sadly it just makes the phone reboot, I used the beastmode boot.img at the same time.
I'm a bit in over my head at this point hah, but someone in that thread had the same results..
Click to expand...
Click to collapse
Yeah that's he creator of Efidroid... Why don't you reply to that issue tracker and add the Axon 7 to the list of devices that don't boot because of the arm64 arch
twoi said:
Thanks for the reply.
I dumped aboot and replaced the address but sadly it just makes the phone reboot, I used the beastmode boot.img at the same time.
I'm a bit in over my head at this point hah, but someone in that thread had the same results..
Click to expand...
Click to collapse
yes you are on right track
twoi said:
Thanks for the reply.
I dumped aboot and replaced the address but sadly it just makes the phone reboot, I used the beastmode boot.img at the same time.
I'm a bit in over my head at this point hah, but someone in that thread had the same results..
Click to expand...
Click to collapse
have you replied or keep track of this
https://github.com/efidroid/projectmanagement/issues/89
the dev was asking for something
Druboo666 said:
have you replied or keep track of this
https://github.com/efidroid/projectmanagement/issues/89
the dev was asking for something
Click to expand...
Click to collapse
I'll try the suggestion of using lk_origdtb.img. I'll have to ask about his instructions to rebuild lk.img, I'm not sure how to repack it.
This might get me close http://android-dls.com/wiki/index.php?title=HOWTO:_Unpack,_Edit,_and_Re-Pack_Boot_Images
But this is lower level than I'm used to, I'm not sure which file(s) constitutes the ramdisk.
twoi said:
I'll try the suggestion of using lk_origdtb.img. I'll have to ask about his instructions to rebuild lk.img, I'm not sure how to repack it.
This might get me close http://android-dls.com/wiki/index.php?title=HOWTO:_Unpack,_Edit,_and_Re-Pack_Boot_Images
But this is lower level than I'm used to, I'm not sure which file(s) constitutes the ramdisk.
Click to expand...
Click to collapse
you should contact with the dev he may help you OP3 and A7 got same chipset so yeah it will help
I tried lk_origdtb.img and the repacked lk.img (Image.gz-dtb) but got the same results, device reboot.
I would love someone else to try this. If you have linux and coding experience at all I think you could manage building it.
twoi said:
I tried lk_origdtb.img and the repacked lk.img (Image.gz-dtb) but got the same results, device reboot.
I would love someone else to try this. If you have linux and coding experience at all I think you could manage building it.
Click to expand...
Click to collapse
you can contact @npjohnson or @m1cha with your compiled LK or boot maybe they can help
as they have fix Nexus 6P LK with no uefi boot

PC recovery similarities to TWRP

What would be the PC equivalent of Custom Recovery software like TWRP?
Would it be something like Acronis TrueImage ?
Also, would it make sense to say that a locked bootloader in a phone (PS: Notice I won't say 'Android Device', because the bootloader comes into play BEFORE the Android OS) is the equivalent of having 'secure boot' enabled in UEFI in a Windows PC? Thereby implying that the process of disabling Secure Boot in UEFI in a PC is the same as unlocking the bootloader in phones?
BIG_BADASS said:
What would be the PC equivalent of Custom Recovery software like TWRP?
Would it be something like Acronis TrueImage ?
Also, would it make sense to say that a locked bootloader in a phone (PS: Notice I won't say 'Android Device', because the bootloader comes into play BEFORE the Android OS) is the equivalent of having 'secure boot' enabled in UEFI in a Windows PC? Thereby implying that the process of disabling Secure Boot in UEFI in a PC is the same as unlocking the bootloader in phones?
Click to expand...
Click to collapse
I really don't think you get how phones work bro. Unlocking a bootloader can only be done by manufacturing or through more aggressive means when possible. The H812 still hasn't had its bootloader unlocked by lg and at this point probably never will
Sent from my LG-H812 using Tapatalk
SpyderAByte said:
I really don't think you get how phones work bro. Unlocking a bootloader can only be done by manufacturing or through more aggressive means when possible. The H812 still hasn't had its bootloader unlocked by lg and at this point probably never will
Sent from my LG-H812 using Tapatalk
Click to expand...
Click to collapse
That doesn't answer my question. I asked the theoretical side, not practical.
Before you do anything, you must understand the FULL boot sequence and structure of Smartphone with ARM chipset, and compare it to Intel x86 Chipset..... and know the relationships well... THEN only you can safely say "I know this" ... THEN only you can safely play around and tinker with the smart phones.....
I thought I knew alot.. but turns out I know NOTHING.... so I go back to square 1 and learn EVERYTHING from scratch again.....
Before I do anything, I must familiarize WHAT is TWRP.. You can say "TWRP is custom recovery", okay, 'WHAT IS CUSTOM RECOVERY' ? You must be able to clearly explain what it is, what parts of the boot sequence it affects.... what is the equivalent in an Intel x86 PC of TWRP or custom recovery????
WHat is a ROM? We all know ROM in smartphone world is more than just the operating system... So what other components does it replace besides the operating system???
We have to think like this and analyze EVERYTHING, all the relationships between all the entities.....
I am now learning about EMBEDDED LINUX ... and the boot sequence of it... as smartphone is just another version of embedded linux......
This is what I'm doing now... when I am familiar with EVERYTHING.... then I will tinker....
BIG_BADASS said:
That doesn't answer my question. I asked the theoretical side, not practical.
Click to expand...
Click to collapse
Secure boot on windows acts as a UEFI (modernized motherboard BIOS meant to work better and faster with x64 and newer systems)
Locker to prevent UEFI from booting into unsigned/unrecognized system images (as far as I know, anybody feel free to correct me)
Bootloaders on smartphones would be the equivalent of a UEFI for the arm architecture. Meant to guide the system into booting from a specified mount. Bootloaders are coded by the manufacturer, either locked or unlocked. Unlocked bootloaders provide a way for users to enter recovery mode and potentially flash unsigned/custom images. If the manufacturer decides to lock the bootloader, the only options are wait for a way to unlock from manufacturer or find a way to crack it if you have the know how
Some manufacturers use the same bootloader for all or most variants of one phone, or can use a different bootloader for each variety of a phone, choosing which bootloaders to unlock or leave locked
For example with the Lg G4, the international variant H815 I believe is unlocked, while the H812 is still to this day locked, while unfortunately their has not been enough interest in trying to reverse engineer or find a loophole if even possible
SpyderAByte said:
Secure boot on windows acts as a UEFI (modernized motherboard BIOS meant to work better and faster with x64 and newer systems)
Locker to prevent UEFI from booting into unsigned/unrecognized system images (as far as I know, anybody feel free to correct me)
Bootloaders on smartphones would be the equivalent of a UEFI for the arm architecture. Meant to guide the system into booting from a specified mount. Bootloaders are coded by the manufacturer, either locked or unlocked. Unlocked bootloaders provide a way for users to enter recovery mode and potentially flash unsigned/custom images. If the manufacturer decides to lock the bootloader, the only options are wait for a way to unlock from manufacturer or find a way to crack it if you have the know how
Some manufacturers use the same bootloader for all or most variants of one phone, or can use a different bootloader for each variety of a phone, choosing which bootloaders to unlock or leave locked
For example with the Lg G4, the international variant H815 I believe is unlocked, while the H812 is still to this day locked, while unfortunately their has not been enough interest in trying to reverse engineer or find a loophole if even possible
Click to expand...
Click to collapse
Thank you bro... now we're getting somewhere....
So PCs also have a bootloader.... but the way I understand, "Bootloader" in the smartphone is a combination of BIOS and MBR in the pc world, right? It is all combined into one entity called "Bootloader"...
Also, the MBR usually has a Stage 1 bootloader, which points to a stage 2 bootloader, which is installed somewhere in the permanent memory (hard disk in PC).... but this structure is not the same in smartphone I believe?
The arm architecture is completely different than the x86 or x64 architectures.
As Asus and MSI and acer etc have their own bios,
Samsung, lg, HTC Huawei Google etc have their own bootloaders. Twrp for example is a custom open source bootloader that anybody can get the source and add to. Phone companies do not give out the source code for their bootloaders usually and it is in their own power to lock and unlock them
Sent from my LG-H812 using Tapatalk
SpyderAByte said:
Maybe just get an unlocked international variant of your next phone and let the big boys do the work for you
Sent from my LG-H812 using Tapatalk
Click to expand...
Click to collapse
Yes, that would be the easy way around...
I have the H815 now which I got in exchange for H812... anyways.... if I didn't have it the hard way, I wouldn't learn anything..... If I had the unlockable H815 from day 1, I wouldn't be this curious... therefore I wouldn't learn.. I'd just be living in ignorance thinking I know everything there is to know .....
Why don't you start by finding the twrp out for the h815 and tinkering with it, making it your own. Try finding a stock ROM and tinkering with that building your own. Plenty of guides around the internet. Learn java and take flight bud
Sent from my LG-H812 using Tapatalk
SpyderAByte said:
The arm architecture is completely different than the x86 or x64 architectures.
As Asus and MSI and acer etc have their own bios,
Samsung, lg, HTC Huawei Google etc have their own bootloaders. Twrp for example is a custom open source bootloader that anybody can get the source and add to. Phone companies do not give out the source code for their bootloaders usually and it is in their own power to lock and unlock them
Sent from my LG-H812 using Tapatalk
Click to expand...
Click to collapse
SpyderAByte said:
The arm architecture is completely different than the x86 or x64 architectures.
As Asus and MSI and acer etc have their own bios,
Samsung, lg, HTC Huawei Google etc have their own bootloaders. Twrp for example is a custom open source bootloader that anybody can get the source and add to. Phone companies do not give out the source code for their bootloaders usually and it is in their own power to lock and unlock them
Sent from my LG-H812 using Tapatalk
Click to expand...
Click to collapse
Yes, in the x86 world they do have different motherboard architectures, hence different BIOS's ... but the rest of the boot sequence follows the same order......
So that brings me to my next question... why is it that we can hard brick a phone, but not a PC? I mean.. technically it is possible to brick a PC if you screw up a bios flash.... but that just leads me to believe a "ROM" in smartphone world actually consists of BIOS + OS ...
So that leads me to wonder.. what else has combined functionality? What is the BIOS equivalent in Android? I mean.. technically it is possible to brick a PC if you screw up a bios flash.... but that just leads me to believe a "ROM" in smartphone world actually consists of BIOS + OS ...
So that leads me to wonder.. what else has combined functionality? What is the BIOS equivalent in Android?
The bootloader partition/iso and the data/android partition/ROM are 2 different things
You can independently swap your recovery if it's unlocked and keep your data. Or you can independently change ROMs and keep your bootloader. You don't seem to understand this pretty basic concept
You can brick a phone flashing the bootloader incorrectly or by flashing the ROM incorrectly
Likewise on a PC if you flash the bios/UEFI incorrectly you can brick your motherboard, and corrupting your OS installation can cause issues
The reason you've bricked phones more than you've bricked computers - when was the last time you tried flashing a custom bios or UEFI? Or a version of Linux/windows that your bios won't allow
Computers are usually pretty plug and play so you can swap HDDs/ram/processors and simply upgrade needed drivers to works
Smartphones are greasy and closed source and the manufacturer usually wants it their way, that's why you see them blocking root access and custom roms
Sent from my LG-H812 using Tapatalk
SpyderAByte said:
The bootloader partition/iso and the data/android partition/ROM are 2 different things
You can independently swap your recovery if it's unlocked and keep your data. Or you can independently change ROMs and keep your bootloader. You don't seem to understand this pretty basic concept
You can brick a phone flashing the bootloader incorrectly or by flashing the ROM incorrectly
Likewise on a PC if you flash the bios/UEFI incorrectly you can brick your motherboard, and corrupting your OS installation can cause issues
The reason you've bricked phones more than you've bricked computers - when was the last time you tried flashing a custom bios or UEFI? Or a version of Linux/windows that your bios won't allow
Computers are usually pretty plug and play so you can swap HDDs/ram/processors and simply upgrade needed drivers to works
Smartphones are greasy and closed source and the manufacturer usually wants it their way, that's why you see them blocking root access and custom roms
Sent from my LG-H812 using Tapatalk
Click to expand...
Click to collapse
So basically, the ROM is more than just the operating system, no? Flashing a rom in smartphone is NOT exactly the same as installing Ubuntu or Debian in a PC, right? There's something else you're replacing, am I right?
Also.. the way I understand... Bootloader is the very first software that runs once you power on the smartphone? (equivalent of BIOS) ?
BIG_BADASS said:
So basically, the ROM is more than just the operating system, no?
Click to expand...
Click to collapse
The ROM is the operating system, the included apps and packages and any other information that android needs to run after the bootloader
Sent from my LG-H812 using Tapatalk
SpyderAByte said:
The ROM is the operating system, the included apps and packages and any other information that android needs to run after the bootloader
Sent from my LG-H812 using Tapatalk
Click to expand...
Click to collapse
So when you flash a rom, you're not replacing the original bootloader? Or BIOS?
No as I stated in my previous post. You can use your bootloader or a PC through fastboot to flash ROMs as long as your bootloader is unlocked
On a galaxy for instance you could first install twrp if possible leaving your stock touchWiz ROM perfectly intact but now you have twrp
Then later you can use twrp to install paranoid Android or CM for instance, replacing your stock touchWiz ROM, but leaving your newly installed twrp untouched
I used to have a galaxy s4 Canadian variant, and the bootloader was locked and still is to this day. The only way to flash a custom ROM was to bypass the stock bootloader using a method found by someone experienced with Samsung bootloaders (a rogue Samsung employee iirc)
Sent from my LG-H812 using Tapatalk
SpyderAByte said:
Bootloaders on smartphones would be the equivalent of a UEFI for the arm architecture. Meant to guide the system into booting from a specified mount. Bootloaders are coded by the manufacturer, either locked or unlocked. Unlocked bootloaders provide a way for users to enter recovery mode and potentially flash unsigned/custom images. If the manufacturer decides to lock the bootloader, the only options are wait for a way to unlock from manufacturer or find a way to crack it if you have the know how
Click to expand...
Click to collapse
The final outcome is the same, yes, but bootloader and BIOS/UEFI are completely separate, right? X86 PCs have a bootloader called NTLDR and it comes into play after the BIOS has finished POST and given control to the MBR....
BIOS > MBR (contains stage 1 bootloader) > Stage 1 bootloader points to Stage 2 bootloader in the HDD
Or is the functionality of bootloader and bios combined into one unit in the smartphone?
---------- Post added at 07:09 AM ---------- Previous post was at 07:05 AM ----------
SpyderAByte said:
No as I stated in my previous post. You can use your bootloader or a PC through fastboot to flash ROMs as long as your bootloader is unlocked
On a galaxy for instance you could first install twrp if possible leaving your stock touchWiz ROM perfectly intact but now you have twrp
Then later you can use twrp to install paranoid Android or CM for instance, replacing your stock touchWiz ROM, but leaving your newly installed twrp untouched
I used to have a galaxy s4 Canadian variant, and the bootloader was locked and still is to this day. The only way to flash a custom ROM was to bypass the stock bootloader using a method found by someone experienced with Samsung bootloaders (a rogue Samsung employee iirc)
Sent from my LG-H812 using Tapatalk
Click to expand...
Click to collapse
So TWRP comes into play before the operating system is loaded, correct? Meaning if you flash a corrupt operating system, you can still format the drive, because TWRP is on a lower layer?
So you can think of TWRP as those Windows Recovery disks?
Do you understand how partitions work? (Not attacking, honest question)
Your bootloader would sit on one partition of the phone emmc(like a small solid state drive/kind of like an sd card chip)
So your partition table would look kind of like this
Emmc1 - /boot (bootloader tells android to boot into recovery, download, fastboot, or android rom
Emmc2 - /recovery (recovery partition. User interface of twrp for example)
Emmc3 - /download mode (used to flash zips)
Emmc4 - /data (android rom that you install
Emmc5 - / (the root folder of your phone, where your storage starts
If you remember getting a 16gb iPhone or iPod and wondering why you only got 9-11gb when you have 100% free space, it's because the emmc is rated for 16gb but the data/ROM uses 5-7gb
Sent from my LG-H812 using Tapatalk
SpyderAByte said:
Do you understand how partitions work? (Not attacking, honest question)
Your bootloader would sit on one partition of the phone emmc(like a small solid state drive/kind of like an sd card chip)
So your partition table would look kind of like this
Emmc1 - /boot (bootloader tells android to boot into recovery, download, fastboot, or android rom
Emmc2 - /recovery (recovery partition. User interface of twrp for example)
Emmc3 - /download mode (used to flash zips)
Emmc4 - /data (android rom that you install
Emmc5 - / (the root folder of your phone, where your storage starts
If you remember getting a 16gb iPhone or iPod and wondering why you only got 9-11gb when you have 100% free space, it's because the emmc is rated for 16gb but the data/ROM uses 5-7gb
Sent from my LG-H812 using Tapatalk
Click to expand...
Click to collapse
Sorry man, I'm from the PC world.. this makes no sense to me.... please relate all the functionality to it's PC equivalent...
Also, what is the boot sequence of the smartphone? Does it have a BIOS? MBR? Hard Drive? RAM?
If smartphone doesn't have all these parts, then what part of the phone does the job of the BIOS, MBR, Hard drive, RAM, bootloader, etc?
---------- Post added at 07:27 AM ---------- Previous post was at 07:20 AM ----------
Maybe my approach here is wrong, maybe I shouldn't try to relate everything 1 to 1 ?
---------- Post added at 07:48 AM ---------- Previous post was at 07:27 AM ----------
SpyderAByte said:
Do you understand how partitions work? (Not attacking, honest question)
Your bootloader would sit on one partition of the phone emmc(like a small solid state drive/kind of like an sd card chip)
So your partition table would look kind of like this
Emmc1 - /boot (bootloader tells android to boot into recovery, download, fastboot, or android rom
Emmc2 - /recovery (recovery partition. User interface of twrp for example)
Emmc3 - /download mode (used to flash zips)
Emmc4 - /data (android rom that you install
Emmc5 - / (the root folder of your phone, where your storage starts
If you remember getting a 16gb iPhone or iPod and wondering why you only got 9-11gb when you have 100% free space, it's because the emmc is rated for 16gb but the data/ROM uses 5-7gb
Sent from my LG-H812 using Tapatalk
Click to expand...
Click to collapse
Also, lets say you format the entire memory of the phone, and reinstall Android.... will it automatically create all these partitions?
Holy **** man you say you know computers but it's almost the same as Linux. Android uses Linux at its absolute core so alot of it is pretty close. Look up a healthy Linux partiton setup and compare to my half assed partition table above and you'll see it's almost identical.
A HDD, SSD, or a memory block (phone internals, usb drives, sd cards) all can have seperate "partitions" which are basically seperate simulated drives, and all have a master boot record telling the device where to start.
There is a boot partition on the memory block which holds the core bootloader files and tells the phone what to do first.
If you hold down the recovery button it will tell the phone to boot to the recovery partition. If you hold down the download buttons it will tell the phone to boot into the download partition. If you allow the phone to boot regularly it will tell the phone to boot to the android /system partition which is where the android operating system is held
I can't explain how this works compared to windows because windows does its own thing in regarding to booting and it is not in my spectrum
The paranoidAndroid.iso file system you would try to flash for example would hold the
/system(android os)
/Data (user data and apps)
/ Or /root (main read/write accessable storage for user)
/Root would require root access to be able to get into and from there you can access the /system and /data mountpoints to modify system files, without root access you are usually not even able to view these folders
SpyderAByte said:
Holy **** man you say you know computers but it's almost the same as Linux. Android uses Linux at its absolute core so alot of it is pretty close. Look up a healthy Linux partiton setup and compare to my half assed partition table above and you'll see it's almost identical.
A HDD, SSD, or a memory block (phone internals, usb drives, sd cards) all can have seperate "partitions" which are basically seperate simulated drives, and all have a master boot record telling the device where to start.
There is a boot partition on the memory block which holds the core bootloader files and tells the phone what to do first.
If you hold down the recovery button it will tell the phone to boot to the recovery partition. If you hold down the download buttons it will tell the phone to boot into the download partition. If you allow the phone to boot regularly it will tell the phone to boot to the android /system partition which is where the android operating system is held
I can't explain how this works compared to windows because windows does its own thing in regarding to booting and it is not in my spectrum
The paranoidAndroid.iso file system you would try to flash for example would hold the
/system(android os)
/Data (user data and apps)
/ Or /root (main read/write accessable storage for user)
/Root would require root access to be able to get into and from there you can access the /system and /data mountpoints to modify system files, without root access you are usually not even able to view these folders
Click to expand...
Click to collapse
Yes I know Linux... but there is a HUGE difference between Embedded Linux and GNU/Linux you run on PC.....
If you were to completely wipe the phones internal memory, formatting each seperate partition into one blank one. You would need to find a way to recreate the partition table, install the bootloader onto its proper partition
Then you would use the bootloader to either recreate the partitions for the android rom, OR the ROM could self unpack and create it's needed /system, /data, and /root partitions

Categories

Resources