-
-
Save anonymous/dd5057f4c7f1cad763f7 to your computer and use it in GitHub Desktop.
MultiROM v16 - booting all your things
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# This paste has been copied from http://pastebin.com/nECqHGai simply because Pastebin doesn't allow linking to specific lines. | |
* Now talking on #multirom | |
* Topic for #multirom is: MultiROM v16 - booting all your things | mako: http://bit.ly/GG7O4D | flo: http://bit.ly/1huZdNx | grouper: http://bit.ly/15UzSHH | |
* Topic for #multirom set by Tassadar at Mon Oct 7 01:43:19 2013 | |
<yuga> While porting multirom to the Xperia Z, I found that TWRP was using the multirom binary from the Internal storage. I was wondering why can't it just use the binary that is already in the ramdisk> | |
<yuga> ? | |
* Tassadar pokes alvinmobileltd | |
<alvinmobileltd> Why me??? :( | |
<Tassadar> well I don't have multirom in ramdisk) | |
<alvinmobileltd> It hurts :( | |
<yuga> Hmm. | |
<alvinmobileltd> Actually, I think the original one puts trampoline directly in the Android ramdisk | |
<yuga> Because the installer zip seems to repack the ramdisk with the binary | |
<Tassadar> yeah, of course, it's the init | |
<alvinmobileltd> Nexus devices and most non-Xperia devices doesn't have the concept of combinedroot | |
<alvinmobileltd> Mine using combinedroot is quite a different approach | |
<yuga> Yup. Alvin has a different structure. What I was trying was to see if we could port Tasssadar's binary. | |
<Tassadar> yuga: if you're using my branch and not alvinmobileltd's and by multirom binary you mean trampoline, then it's because | |
<Tassadar> well | |
<Tassadar> TWRP doesn't even use trampoline for anything | |
<yuga> Oh. | |
<Tassadar> it just installs it to the initrd, if requested | |
<Tassadar> the multirom binary isn't in ramdisk | |
<yuga> My bad, then | |
<yuga> So yours just repacks the ramdisk with trampoline > init? | |
<Tassadar> *shouldn't be, I've noticed that omnirom builds of TWRP have multirom binaries on root, but it's not intentional and who cares) | |
<Tassadar> yeah | |
<Tassadar> well and moves some symlinks so they point to the real init | |
<Tassadar> *in root | |
<yuga> ueventd? | |
<yuga> watchdog? | |
<yuga> That's all right? | |
<alvinmobileltd> The recovery ramdisk is copied from the boot ramdisk and then modified | |
<Tassadar> yeah | |
<yuga> Ok, i'll go try this. | |
<alvinmobileltd> So if you build multirom and then build recovery, multirom will get copied to recovery | |
<alvinmobileltd> in Tassadar's approach. | |
* alvinmobileltd is now known as alvinhochun-away | |
<Tassadar> rw,relatime,fmask=0022,dmask=0022,codepage=437,iocharset=ascii,shortname=mixed,errors=remount-ro | |
<Tassadar> (just need to note that somewhere..) | |
<Tassadar> http://www.xda-developers.com/android/boot-multiple-roms-on-the-htc-droid-dna-with-unofficial-multirom-port/ multirom's getting on all the phones these days Oo | |
<yuga> Great news :D | |
<Tassadar> alvinhochun-away: by the way, are you interested in that Android app I made for MultiROM? It should be pretty doable to have it working even with unofficial ports | |
* alvinhochun-away is now known as alvinmobile | |
<alvinmobile> hm, what does it do? | |
<Tassadar> installs MultiROM, it's recovery and kernel, checks for updates, can rename and delete installed ROMs and boot into that ROM directly from android | |
<Tassadar> (and also installs Ubuntu Touch, if the device supports it) | |
<Tassadar> *its | |
<alvinmobile> Not sure how it will work with all my changes | |
<Tassadar> installation consists of dd'ing the recovery to the partition and flashing the ZIPs via recovery (using OpenRecoveryScript) | |
<Tassadar> ...and I forgot you don't have recovery partition | |
<Tassadar> never mind then | |
<alvinmobile> For instance, the way of installing multirom itself and recovery is already not the same. I still haven't started modifying the zip | |
<alvinmobile> And I am still rewriting some parts of multirom | |
<alvinmobile> Also my modified multirom now only boots ext4 images, by replacing block device like I've mentioned before | |
<Tassadar> the app doesn't care about that, the only problem is with installing the recovery (and rebooting into it), which is completely different in your version | |
<alvinmobile> Don't know if I'll add back bind-mount or symlink since it requires changing init.rc too much | |
<alvinmobile> How do you autoboot other rom in a secondary rom? | |
<alvinmobile> I mean where do you store the info? | |
<Tassadar> it runs "multirom --boot-rom=nameoftherom" in su shell, and MultiROM takes care of that - it loads ROM list as usual and either directly kexecs the required kernel or sets force-autoboot into rom X (which saves into multirom.ini) and reboots | |
<Tassadar> it's in multirom git | |
<Tassadar> https://github.com/Tasssadar/multirom/commit/1eb2fe13a013b033f88928d96343752b41096cf4 | |
<Tassadar> (there are some fixes for that in following commits) | |
<alvinmobile> oh I see, it kexec directly from Android | |
<alvinmobile> I currently place multirom in ramdisk and it is deleted before actually booting internal rom, and secondary rom's ramdisk does not have it. | |
<Tassadar> I may have not realized how many changes you made when I suggested you use that app) | |
<alvinmobile> Yep, a lot of changes | |
<alvinmobile> Well, maybe in the future I can look into merging my changes back to yours tree, but if I really do this it will certainly cause breaking changes to one of the two | |
<alvinmobile> maybe even both | |
<alvinmobile> Perhaps with some hacky way I can make your app work with mine | |
<Tassadar> to be honest, I don't really want to support devices with such practices like not having boot partition | |
<alvinmobile> Will look into it when I get twrp working | |
<Tassadar> *recovery partition | |
<alvinmobile> Actually it's not really that bad. Have you seen what my trampoline now does? | |
<Tassadar> eeh no | |
<Tassadar> yeah, you replace the initrd | |
<Tassadar> still, I simply don't get why they don't have recovery partition, it doesn't make any sense - who was like "hm, I think merging it with boot so that it has the same kernel is a good idea, let's put our programmers to make that happen instead of having them do something else" | |
<alvinmobile> Xperia devices doesn't even have stock recovery | |
<Tassadar> how do they do updates, via computer? | |
<alvinmobile> 1. Via PC, with a special flash mode | |
<alvinmobile> or, 2. There is a special partition called FOTAkernel, which I believe hosts a special recovery used to do FOTA updates | |
<Tassadar> and that partition is too small to host an actuall recovery, I guess? | |
<alvinmobile> It's 15MB, already too big | |
* Tassadar realizes that actual has only one l and that he has to stop writing -ll | |
<Tassadar> why don't you use that for recovery? | |
<alvinmobile> Because reboot recovery doesn't boot that | |
<Tassadar> how do you make it boot from that partition? | |
<alvinmobile> I think it needs to be reboot oem-f | |
<alvinmobile> I haven't tried though | |
<Tassadar> that still seems much better than messing with it in boot | |
<alvinmobile> It's in the kernel source so I suspect that's it | |
<alvinmobile> Actually I can modify the kernel to make reboot recovery boot that | |
<alvinmobile> But it seems that most Xperia devs uses the combinedroot way | |
<alvinmobile> There're actually a lot of things I can do, but I am scared of bricking it | |
<Tassadar> does it have fastboot? | |
<alvinmobile> Yes it has fastboot | |
<alvinmobile> Anyway, combinedroot is actually a nice way since there can be multiple recovery systems | |
<Tassadar> how big is your boot? | |
<alvinmobile> 20mb | |
<alvinmobile> the kernel is just 6mb btw | |
<alvinmobile> It's funny that they don't just make a recovery partition directly but made it something else | |
<Tassadar> Dees_Troy of TWRP says that Sony will stop doing that in their future phones, according to some people he knows in Sony | |
<alvinmobile> oh, that's better | |
* alvinmobile has quit (Quit: Leaving) | |
* zz_rirozizo is now known as rirozizo | |
* Disconnected (Connection reset by peer). | |
* yuga sets mode +i yuga | |
-NickServ- This nickname is registered. Please choose a different nickname, or identify via /msg NickServ identify <password>. | |
* Now talking on #multirom | |
* Topic for #multirom is: MultiROM v16 - booting all your things | mako: http://bit.ly/GG7O4D | flo: http://bit.ly/1huZdNx | grouper: http://bit.ly/15UzSHH | |
* Topic for #multirom set by Tassadar at Mon Oct 7 01:43:19 2013 | |
* Disconnected (Connection reset by peer). | |
* yuga sets mode +i yuga | |
-NickServ- This nickname is registered. Please choose a different nickname, or identify via /msg NickServ identify <password>. | |
* Now talking on #multirom | |
* Topic for #multirom is: MultiROM v16 - booting all your things | mako: http://bit.ly/GG7O4D | flo: http://bit.ly/1huZdNx | grouper: http://bit.ly/15UzSHH | |
* Topic for #multirom set by Tassadar at Mon Oct 7 01:43:19 2013 | |
* Disconnected (Connection reset by peer). | |
* yuga sets mode +i yuga | |
-NickServ- This nickname is registered. Please choose a different nickname, or identify via /msg NickServ identify <password>. | |
* Now talking on #multirom | |
* Topic for #multirom is: MultiROM v16 - booting all your things | mako: http://bit.ly/GG7O4D | flo: http://bit.ly/1huZdNx | grouper: http://bit.ly/15UzSHH | |
* Topic for #multirom set by Tassadar at Mon Oct 7 01:43:19 2013 | |
* alvinmobileltd (~asd@203.145.92.162) has joined #multirom | |
* Disconnected (Connection reset by peer). | |
* yuga sets mode +i yuga | |
-NickServ- This nickname is registered. Please choose a different nickname, or identify via /msg NickServ identify <password>. | |
* Now talking on #multirom | |
* Topic for #multirom is: MultiROM v16 - booting all your things | mako: http://bit.ly/GG7O4D | flo: http://bit.ly/1huZdNx | grouper: http://bit.ly/15UzSHH | |
* Topic for #multirom set by Tassadar at Mon Oct 7 01:43:19 2013 | |
* alvinhochun-away is now known as alvinmobile |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment