[DUMP] Motorola Atrix 4G U4_1.5.2 - Atrix 4G Android Development

Hi!
This is a dump of [FLASH_SBF] Motorola Atrix 4G U4_1.5.2
Kernel config, initramfs + recovery Code Group 56 / Partition 10 / Recovery --- Code Group 55 / Partition 11 / Kernel
Modem (new ver: oly17706 stock: oly17705) (Code Group 5)
/system - mirror (Code Group 57)
/osh (Code Group 58)
I'll post the other partitions shortly.
Stock ----------------
ro.build.id=OLYFR_U4_1.2.6
ro.build.display.id=OLYFR_U4_1.2.6
ro.build.version.incremental=1296900353
ro.build.date=Sat Feb 5 03:11:10 CST 2011
ro.build.date.utc=1296897070
ro.build.user=w19091
ro.build.host=il93lnxdroid46
ro.build.description=olympus-user 2.2.1 OLYFR_U4_1.2.6 1296900353 ota-rel-keys,release-keys
ro.build.fingerprint=MOTO/olyatt/olympus/olympus:2.2.1/OLYFR_U4_1.2.6/1296900353:user/ota-rel-keys,release-keys
ro.build.version.full=Blur_Version.4.1.26.MB860.ATT.en.US
Update ----------------
ro.build.id=OLYFR_U4_1.5.2
ro.build.display.id=OLYFR_U4_1.5.2
ro.build.version.incremental=1298398352
ro.build.date=Tue Feb 22 09:28:35 PST 2011
ro.build.date.utc=1298395715
ro.build.user=fpgh48
ro.build.host=ca25rhe85
ro.build.description=olympus-user 2.2.1 OLYFR_U4_1.5.2 1298398352 ota-rel-keys,release-keys
ro.build.fingerprint=MOTO/olyatt/olympus/olympus:2.2.1/OLYFR_U4_1.5.2/1298398352:user/ota-rel-keys,release-keys
ro.build.version.full=Blur_Version.4.1.52.MB860.ATT.en.US

Da_G said:
Hi!
This is a dump of [FLASH_SBF] Motorola Atrix 4G U4_1.5.2
System - [font size=-2]mirror[/font]
I'll post the other partitions shortly.
Click to expand...
Click to collapse
If I may ask, how did you pull the Dump?

hes da_g, thats how he did it.

There are a couple sbf tools available that will separate out the CGs (Code Groups) from the .sbf (which is a container for the CGs and a few other things)
I used RSD Lite which splits them out, each is an image of the partition (like one made with dd) so you can do:
Code:
mount -o loop ~/olyfr_u4_1.5.2_signed_olpsattspe_p012_hwolympus_1g_1ffCG57.smg /mnt/atrix
which mounts the filesystem to /mnt/atrix letting you read everything out

Ok so pretty much the currently available version of RSD (4.9) can read the SBF just not flash it to the Atrix. Thanks!
Da_G said:
There are a couple sbf tools available that will separate out the CGs (Code Groups) from the .sbf (which is a container for the CGs and a few other things)
I used RSD Lite which splits them out, each is an image of the partition (like one made with dd) so you can do:
Code:
mount -o loop ~/olyfr_u4_1.5.2_signed_olpsattspe_p012_hwolympus_1g_1ffCG57.smg /mnt/atrix
which mounts the filesystem to /mnt/atrix letting you read everything out
Click to expand...
Click to collapse

Si Senor. Yes Sir!

Sorry I am trying to learn all the limbo.. what the significance of a dump? is that a copy of the sbf?

It's a file archive (specifically .tar.gz, which is comparable to a .zip or a .rar) with all the files in the filesystem. So it's not a copy of the .sbf, but another way of presenting the same data. And with root you can shuffle these files in by remounting /system rw and copying them in, to try out new stuffs
edit: updated first post with /osh dump

Da_G said:
It's a file archive (specifically .tar.gz, which is comparable to a .zip or a .rar) with all the files in the filesystem. So it's not a copy of the .sbf, but another way of presenting the same data. And with root you can shuffle these files in by remounting /system rw and copying them in, to try out new stuffs
edit: updated first post with /osh dump
Click to expand...
Click to collapse
Hey G, exactly whats new in this? How do I remount the new stuff? You make everything sound so simple!

Well, for example, if you wanted to pull out an app you could grab the .apk from the dump, deodex it, and introduce it into your current rom..
I think it's likely possible to directly flash the .smgs to NAND too, bypassing the bootloader. I did some testing with Fenrir on IRC that resulted in a brick (all hail!) but before the brick happened we were successful in flashing a (signed) part of the NAND without issue.
(uploaded kernel config, initramfs, modem)

Da_G said:
Well, for example, if you wanted to pull out an app you could grab the .apk from the dump, deodex it, and introduce it into your current rom..
I think it's likely possible to directly flash the .smgs to NAND too, bypassing the bootloader. I did some testing with Fenrir on IRC that resulted in a brick (all hail!) but before the brick happened we were successful in flashing a (signed) part of the NAND without issue.
(uploaded kernel config, initramfs, modem)
Click to expand...
Click to collapse
Any exciting things inside? That are worth checking? Is the modem different?

Da_G said:
Well, for example, if you wanted to pull out an app you could grab the .apk from the dump, deodex it, and introduce it into your current rom..
I think it's likely possible to directly flash the .smgs to NAND too, bypassing the bootloader. I did some testing with Fenrir on IRC that resulted in a brick (all hail!) but before the brick happened we were successful in flashing a (signed) part of the NAND without issue.
(uploaded kernel config, initramfs, modem)
Click to expand...
Click to collapse
can you write to /sys folder with mounting ? if so i will stop what im doing as i have something to try

dumb question, but is there any rsd lite version that will flash this onto the atrix? not that i plan to do it, just want to learn.

t0dbld said:
im confused are you guys all not running this version already? I have 2 atrix in my hands this is same build i have ran sense day 1 are some of you running different versions? also what are than your build dates ?
Click to expand...
Click to collapse
I'm on Build # U4.1.2.6 so....

franciscojavierleon said:
dumb question, but is there any rsd lite version that will flash this onto the atrix? not that i plan to do it, just want to learn.
Click to expand...
Click to collapse
Not right now. Tomorrow maybe.

@Fixter:
The modem is 1 version higher (info in first post) changes are negligable.
@t0dbld:
Yes, you are free to read/write the whole /system partition. (with root) (edit: after talking on irc i realize you meant /sys which is a kernel interface rather than a partition, you can't write to it like a partition, but you can change some config settings there)
And should any (very) brave souls want to try flashing through a completely manual, arcane, scary, possibly deadly to your device method, I might have a way to bypass the bootloader for writing the sensitive areas of NAND that would normally be signature checked. With some testing were able to write a few 1KB chunks without issue, when tried a whole image it bricked, failing security check on next boot. Have some ideas how to get around that though, maybe better to try when a working RSD/SBF combo is available for easy recovery

Da_G said:
@Fixter:
The modem is 1 version higher (info in first post) changes are negligable.
@t0dbld:
Yes, you are free to read/write the whole /system partition. (with root)
And should any (very) brave souls want to try flashing through a completely manual, arcane, scary, possibly deadly to your device method, I might have a way to bypass the bootloader for writing the sensitive areas of NAND that would normally be signature checked. With some testing were able to write a few 1KB chunks without issue, when tried a whole image it bricked, failing security check on next boot. Have some ideas how to get around that though, maybe better to try when a working RSD/SBF combo is available for easy recovery
Click to expand...
Click to collapse
Hi, will this resolve my Atrix 4G's problem of unable to detece network carriers after using *#*#4636#*#* code to check the radio band?
My 4G now can only dial emergency calls. Can I share with u the attached docment and hopefully you can give me some advice if I can resolve my problem.
Thanks so much...

Da_G said:
There are a couple sbf tools available that will separate out the CGs (Code Groups) from the .sbf (which is a container for the CGs and a few other things)
I used RSD Lite which splits them out, each is an image of the partition (like one made with dd) so you can do:
Code:
mount -o loop ~/olyfr_u4_1.5.2_signed_olpsattspe_p012_hwolympus_1g_1ffCG57.smg /mnt/atrix
which mounts the filesystem to /mnt/atrix letting you read everything out
Click to expand...
Click to collapse
nice, just like the rfs files from the captivate
Da_G said:
@Fixter:
The modem is 1 version higher (info in first post) changes are negligable.
@t0dbld:
Yes, you are free to read/write the whole /system partition. (with root) (edit: after talking on irc i realize you meant /sys which is a kernel interface rather than a partition, you can't write to it like a partition, but you can change some config settings there)
And should any (very) brave souls want to try flashing through a completely manual, arcane, scary, possibly deadly to your device method, I might have a way to bypass the bootloader for writing the sensitive areas of NAND that would normally be signature checked. With some testing were able to write a few 1KB chunks without issue, when tried a whole image it bricked, failing security check on next boot. Have some ideas how to get around that though, maybe better to try when a working RSD/SBF combo is available for easy recovery
Click to expand...
Click to collapse
RSD 5 is in the release thread now, seems to be working here so far

t0dbld said:
can you write to /sys folder with mounting ? if so i will stop what im doing as i have something to try
Click to expand...
Click to collapse
Are you trying to write to /sys or /system? Also, what are you trying to do?

ok serious question that might sound dumb.
how far are from unlocked bootloader ?
i mean i see everyone is so excited. but i dont know what does that mean .
can someone explain to me in simple way so i can thank him ? lol

Related

[TOOL] NVflash Toolkit

*** NVflash Toolkit - Backup, Restore, Resize, Recovery, Rescue ***​
**** NOOBS READ THIS ****
What is the first thing you see when you boot up your phone?
It will be one of three things:
1. A white LG logo - you are running the original bootloader and partition layout.
2. A pink LG logo - you are running the new bootloader with the new partition layout.
**** It is important to know which one you are on before using nvflash or flashing any roms ****
I have put together a little toolkit to make NVflash a bit easier to use for the most common functions. The toolkit is still a work in progress, so not everything may work as intended! I would advise taking a nandroid backup to your external SD card and copying any important files from your internal SD to somewhere safe before trying this out. This version is for the original partition layout.
First, download and unzip the toolkit to your PC, it is available here: NVflash_Toolkit_0.2.zip - 218.14 MB
Second, connect your phone in NVflash mode (battery out, Volume UP+DOWN buttons pressed, connect to USB) and install the NVflash drivers if necessary (they are included in the download)
Third, run the nvflash-toolkit.bat batch file which will guide you through the functions.
After each NVflash attempt, I would recommend disconnecting and reconnecting the phone before the next flash - I had problems trying to recover the data partition in the same nvflash session as intitialising the partition layout.
The Internal SD card partition is too large to recover using NVflash, but you can mount the backed up internalsd.img file using something like DiskInternals Linux Reader if you want to access the files on it.
***NEW ICS TOOLKIT*** NVflash_ToolkitICS_02.zip - 291.39 MB
This is for the new ICS partition format with unlocked bootloader included.
1. Backup internal partitions (useful for rooting any new builds)
2. Flash v28e ICS rom or backed up partitions using new LG partitition table
3. Revert to gingerbread partition layout with normal and large (ICS) partition size (no rom included, boot to CWM only)
4. Restore ICS data partition
I will add more functions later...
Let me know if there are any other useful NVflash functions it would be worth putting into the toolkit. My initial version has a supersized option as well as large which has a larger 2Gb Data partition. Would it be better to have a 1Gb system partition rather than 512Mb in the supersized partition layout so that it is useful for anyone who is using dual boot? Also, I have put in v10b as a rescue rom for now, but I could put in a different one there, or even have a selection of rom images that could be used for a quick rescue of the phone. Tell me which you think would be the most useful one to have, since nobody actually uses v10b any more!!
Changelog
Version 0.2 - Fixed CWM 5.0.2.8 installation, Rescue rom now includes CWM 5.0.2.8
Thanks to Koush for his indispensable CWM recoveries, Rusty! for his NVflash recoveries which inspired me to make this script, and the search button for teaching me everything I know.
do you think this can be usefull with the RCs cm10 since we don t have any space left in system
mivv said:
do you think this can be usefull with the RCs cm10 since we don t have any space left in system
Click to expand...
Click to collapse
The main reason I made this was because it's going to be a struggle fitting modified ICS and CM10 roms into the original system partition, but we still want to use the original unlocked bootloader if we can get kernels that are compatible.
There are various threads with tips on how to use nvflash to change partition sizes, or go back to a stock rom in an emergency, or flash a recovery, but I thought it would be worth making a one stop shop for all the common nvflash functions. Also I haven't seen any discussions in the O2X forums about using nvflash for backup and restore, so those are the functions I am not quite so confident about yet...
Hi
I wanna thank for yet another fantastic tool. Trying it as writing. I have a wish for an updated resque rom like 20s if possible. And maybe add the dual boot development as an additional feature.
Anyways, great work
Please create a reliable mirror. Your chosen download site is down. Thank you!
Raum1807 said:
Please create a reliable mirror. Your chosen download site is down. Thank you!
Click to expand...
Click to collapse
+1
cant access it...maybe upload somewhere else
Thanks
Raum1807 said:
Please create a reliable mirror. Your chosen download site is down. Thank you!
Click to expand...
Click to collapse
SREEPRAJAY said:
+1
cant access it...maybe upload somewhere else
Thanks
Click to expand...
Click to collapse
OK, Guys!...
Code:
http://depositfiles.com/files/huuok0szl
I kind of think many would like to have your tool with bigger system partitions to avoid the risk of editing the file(s)
SuperSkill said:
I kind of think many would like to have your tool with bigger system partitions to avoid the risk of editing the file(s)
Click to expand...
Click to collapse
I'll probably put up versions with different rescue roms. AT the moment I'm most likely to be switching between LG leaks with the totally insane new partition layout (what the hell is that AP2 partition 6 all about?), and good old fashioned roms with a bigger system partition for better tweakability. I'll do a CM7 stable release, and then add a CM10 once it the milestone build is out.
Might not happen immediately as I am playing around with all the new leaks and my batch file is a mess just now because of all the switched partition numbering and tweaking it to help me use bitdomo's root method.
This is the Linux version, I hope will be useful.
INSTALLATION:
Decompress RAR and copy its contents into the folder NVflash_Toolkit_0.2
EDIT:
Correction of error in v0.2 and uploaded new version ICS
Homero2 said:
This is the Linux version, I hope will be useful.
INSTALLATION:
Decompress RAR and copy its contents into the folder NVflash_Toolkit_0.2
Click to expand...
Click to collapse
Thanks for that. I don't have a Linux machine at the moment.
If you have one you could try injecting the superuser files into a backed up v28 system image and then copying it back to the phone. That's how I was going to try rooting the v28 roms, and it might be simpler than the rather roundabout method of doing it using the old bootloader and recovery.
Not sure how that would work with file ownership and permissions though - my Linux skills are very rusty.
Sent from my LG-P990 using Tapatalk 2
Better late than never, great work. It is now easier to work with NVFlash
I have several NVFlash to CWM recovery and with system.img rooted.
The only problem is that with ICS I cannot mount the file system correctly, and course, if I don't ride I can not modify its contents.
But I'm still doing tests.
Homero2 said:
Better late than never, great work. It is now easier to work with NVFlash
I have several NVFlash to CWM recovery and with system.img rooted.
The only problem is that with ICS I cannot mount the file system correctly, and course, if I don't ride I can not modify its contents.
But I'm still doing tests.
Click to expand...
Click to collapse
There's still more chance of doing it in Linux as all the windows toold for reading EXT filesytems are read only.
I've just made a cfg file for the new ICS partitions layout, but without an unlocked bootloader and recovery it's not much use as nvflash cannot properly write the encrypted bootloader.
I'm going to try wkpark's unlocked bootloader for the SU660 and see what happens....
SUCCESS WITH THE UNLOCKED BOOTLOADER!! --- wkpark is officially an O2X Genius
....now, to get some kind of CWM working on it....
Great joy gives to try something and that works, really!?
Homero2 said:
Great joy gives to try something and that works, really!?
Click to expand...
Click to collapse
We need a new version of CWM compiled for the new partition layout, but the unlocked bootloader is great. I'm just uploading and nvflash version in the big ICS leak thread and will be updating my toolkit with a version for the new ICS partition layout with a few useful tools.
Rmein, how to change system partition to 768 with ur tool? As the max it go is 512. Tks
LG-P990
BB 1120
rmein said:
There's still more chance of doing it in Linux as all the windows toold for reading EXT filesytems are read only.
I've just made a cfg file for the new ICS partitions layout, but without an unlocked bootloader and recovery it's not much use as nvflash cannot properly write the encrypted bootloader.
I'm going to try wkpark's unlocked bootloader for the SU660 and see what happens....
Click to expand...
Click to collapse
Here's a tool that reads and writes EXT files in Windows:
http://www.linuxquestions.org/quest...artition-from-windows-7-a-799039/#post4394675
http://www.ext2fsd.com/
Sir rmein, I apologize now if my question is nubbish but you can add a tool to the option to back up only the data partition? In the section up to the number 3 option also includes the system and I think it would be a good thing that the two options are separated.
Thank you for your attention and for the great job you did with the tool.
bree1 said:
Sir rmein, I apologize now if my question is nubbish but you can add a tool to the option to back up only the data partition? In the section up to the number 3 option also includes the system and I think it would be a good thing that the two options are separated.
Thank you for your attention and for the great job you did with the tool.
Click to expand...
Click to collapse
Just uploading a toolkit for ICS partition layout which includes that function, and then I will go back to do another version of the GB toolkit to make that easier and include a supersized system partition which can fit dual boot roms.
***NEW ICS TOOLKIT*** NVflash_ToolkitICS.zip - 291.31 MB
This is for the new ICS partition format with unlocked bootloader included.
1. Backup internal partitions (useful for rooting any new builds)
2. Flash v28e ICS rom or backed up partitions using new LG partitition table
3. Revert to gingerbread partition layout with normal and large (ICS) partition size (no rom included, boot to CWM only)
4. Restore ICS data partition
I will add more functions later...

[RECOVERY][Experimental][OS2SD/Internal][f2fs]TWRP2.8.0.0-multi

TWRP 2.7.1.0 multi-mode recovery. 2.7.1.0 v3 was the first release for p500, (thanks to @HardLight for advising, testing, and posting it. And for making a p500 OS2SD ROM to justify it.)
v1 and up are for thunderc (Optimus V/S), there's a separate thread over there in the appropriate forum.
Now with f2fs! Thanks @HardLight
OS2SD/Internal All-In-One. Switch modes under Advanced. It tells you on the title bar which mode it's in.
It'll flash gapps or PurePerformances or what have you to either the p2/p4 sdcard partitions for OS2SD or the internal partitions.
This has a special partitioner to set up your card for OS2SD. In OS2SD mode, go to Advanced then Partition. Set your sizes, it isn't aware yet of the whole card size (yet) so it'll just tell you if you go over and refuse to format it.
Whatever is left after your system/swap/data is your /sdcard size.
If it's in Internal mode the partitioner does sd-ext and swap instead. same deal, the leftover space is your /sdcard size.
Under the Wipe -> advanced menu, you can now select either system or data and press the 'repair or change filesystem' bar at the bottom, select change filesystem, select f2fs.
TLS enabled, system/data MTD swap on internal mode to match post-7/12/2014 androidarmv6 builds. Won't flash older ROMS or ones without the MTD swap correctly.
I am working on making it compatible with older builds too... but not yet. You may have to use a new update-binary to flash older zips. Or grab the older one from this zip file.
download, shared folder here:
Experimental, may be glitchy! Enjoy!
source on github
reserved
reserved against whatever need
reserved
I suspect I'll need more than one extra post to cover important stuff that won't fit in the OP.
On the portal today was announced a recovery-switcher app. One could have the mtd swapped and not-mtd swapped recoveries, or a cwm and a twrp recovery on the sdcard and use the app to switch between them. Do not know if this baby would work on a P500, though.
Would rather have a decent all-in-one, but that 5meg limitation may make this impractical (for example, the cwm has lost its sdcard partitioning functions).
bigsupersquid said:
TWRP 2.7.1.0 multi-mode recovery. v4. ...
OS2SD/Internal All-In-One. Switch modes under Advanced. It tells you on the title bar which mode it's in.
It'll flash gapps or PurePerformances or what have you to either the p2/p4 sdcard partitions for OS2SD or the internal partitions.
Experimental, may be glitchy! Enjoy!
source on github
Click to expand...
Click to collapse
So if understand correctly i'll flash the mod "buttons search<->power" & other zip files normally and not have to put the files into the rom manually or edit the updater script etc.:victory: thanks a lot
testing...
Dovidhalevi said:
On the portal today was announced a recovery-switcher app. One could have the mtd swapped and not-mtd swapped recoveries, or a cwm and a twrp recovery on the sdcard and use the app to switch between them. Do not know if this baby would work on a P500, though.
Would rather have a decent all-in-one, but that 5meg limitation may make this impractical (for example, the cwm has lost its sdcard partitioning functions).
Click to expand...
Click to collapse
that thing on portal reflashes the recovery every time to change it.
you could just as easily use flashable zip recoveries...
xdema said:
So if understand correctly i'll flash the mod "buttons search<->power" & other zip files normally and not have to put the files into the rom manually or edit the updater script etc.:victory: thanks a lot
testing...
Click to expand...
Click to collapse
that specific mod, you'd have to fix the updater-script to use it for os2sd, because it specifies MTD mounts.
mount("yaffs2", "MTD", "system", "/system");
pa_gapps and CrossBreeder and other more generic zips use
busybox mount /system
//edit: proper syntax:
run_program("/sbin/busybox","mount","/system");
instead of trying to call out the filesystem type.
bigsupersquid said:
that thing on portal reflashes the recovery every time to change it.
you could just as easily use flashable zip recoveries...
that specific mod, you'd have to fix the updater-script to use it for os2sd, because it specifies MTD mounts.
mount("yaffs2", "MTD", "system", "/system");
pa_gapps and CrossBreeder and other more generic zips use
busybox mount /system
instead of trying to call out the filesystem type.
Click to expand...
Click to collapse
i'll check the updater script, thanks for the pureperformance thinks, i discover a another method to speed up the p500 :fingers-crossed:
bump
f2fs enabled for OS2SD.
uses updater script like so:
mount("f2fs", "EMMC", "/dev/block/mmcblk0p4", "/data");
to use f2fs /data go into Wipe menu, advanced, select data checkbox, press 'repair or change filesystem' bar, change filesystem, f2fs. accept.
you only have to do that once to change from the default ext4 partition type.
it handles /system f2fs as well.
mount("f2fs", "EMMC", "/dev/block/mmcblk0p2", "/system");
change the filesystem the same way as data.
new 3.0.101 kernel but I noticed no differences in recovery except the working f2fs. Thanks @HardLight.
for now, attached .img for you who really have to experiment. I haven't tested this one very much on thunderg, just thunderc. basics tested on thunderg.
flashable zip added to shared folder linked in OP.
there's a little something extra in the shared folder...
I'm also uploading ROMs for the adventurous.
f2fs-system and f2fs-data os2sd builds if you're brave enough to try them. change both system and data to f2fs in recovery before flashing the rom unless you've already done that with an earlier version.
I don't have cell service to test but it's basically an androidarmv6 build plus 3.0.101 kernel and f2fs os2sd. everything else looks like it works to me.
I added Email, Apollo, Speech Recorder (which tunes up voice search I think), emojii in messaging and aosp keyboard, and extra wallpapers. Including Grass live wallpaper (which does actually work on armv6, it just looks for some network function and errors out ... I patched it,) and it reverts to building libcamera. Plus hackers keyboard because I like arrow and tab in terminal. No voice search in hackers keyboard though.
...
bump for twrp 2.8.0.0
no other fixes or anything, just a rev up for twrp.
I'll upload in an hour or so. //edit: well, maybe not so soon. I can't test at the moment since my o1 went into a no-boot loop. perfectly good running rom on it too. bah.
take me the evening to fix it.
bigsupersquid said:
bump for twrp 2.8.0.0
no other fixes or anything, just a rev up for twrp.
I'll upload in an hour or so. //edit: well, maybe not so soon. I can't test at the moment since my o1 went into a no-boot loop. perfectly good running rom on it too. bah.
take me the evening to fix it.
Click to expand...
Click to collapse
i'm testing your's 0509
in this you made the on boot fix?
##fix "add_tid_to_cgroup failed to write" errors
chmod 0660 /dev/cpuctl
# allow reading kernel command line
chmod 0644 /proc/cmdline
Click to expand...
Click to collapse
thanks
could you say to me if it's normal this:
i make the wipe of the /system in twrp, then if i go to "repair or change fs" it show size 390mb, used 110mb
but if i make a wipe or a "change fs", used space shouldn't be 0mb?
is the same for /data.
i un/mounted the partitions before, but have always some mb used in both.
hum minitool show me that the two f2fs partitions are fully used, maybe it can't read the f2fs, however i've formatted the partitions again in ext4 and now retry the f2fs format via twrp
edit: however, after 2nd format in the end /data have 144 mb used, /system 110mb. so i suspect it's normal
xdema said:
i'm testing your's 0509
in this you made the on boot fix?
thanks
could you say to me if it's normal this:
i make the wipe of the /system in twrp, then if i go to "repair or change fs" it show size 390mb, used 110mb
but if i make a wipe or a "change fs", used space shouldn't be 0mb?
is the same for /data.
i un/mounted the partitions before, but have always some mb used in both.
hum minitool show me that the two f2fs partitions are fully used, maybe it can't read the f2fs, however i've formatted the partitions again in ext4 and now retry the f2fs format via twrp
edit: however, after 2nd format in the end /data have 144 mb used, /system 110mb. so i suspect it's normal
Click to expand...
Click to collapse
looks normal to me, ext4 uses "only" about 16MB after format but f2fs uses a lot more.
minitool will only work right if your kernel supports f2fs and I doubt m$ware does right now.
and the fix din't get migrated from the overrides in thunderc to p500 yet, sorry, was a 'for fun' build to share after a recent repo sync.
this one probably has a built libcamera instead of the froyo as well. (reversion)
reverted to twrp 2.7.1.0
2.8 kept bootlooping my o1.
one too many passes with kdz, it's total blackout no power, and I'll have to jtag it now.
be a while before I release another update unless I find an o1 with fastboot.
bigsupersquid said:
reverted to twrp 2.7.1.0
2.8 kept bootlooping my o1.
one too many passes with kdz, it's total blackout no power, and I'll have to jtag it now.
be a while before I release another update unless I find an o1 with fastboot.
Click to expand...
Click to collapse
My 01 does have fastboot e.e
andrea210701 said:
My 01 does have fastboot e.e
Click to expand...
Click to collapse
I meant that I can use. HardLight pointed me to the method to enable it... if I hadn't completely fried my firmware. no backlight even, much less lg logo or emergency mode.
eventually I'll find another p500 for development (I can't use gsm phone on my service) but the going rate on ebay is $50 and I can't justify that for a hobby.
unfortunately it's too tweaky and time consuming for me to remotely develop by having someone else debug, so any more p500 stuff will be untested and slightly sketchy because of that.
Project [F2FS] [OS2SD]
[F2FS] [OS2SD] it can work with any other rom? Thanks.
cwm6.0.5.3oldMTDmounts_p500.zip
I do not know what it is? Sorry for the little understood...
Any PlayStore said:
cwm6.0.5.3oldMTDmounts_p500.zip
I do not know what it is? Sorry for the little understood...
Click to expand...
Click to collapse
clockwork mod v 6.0.5.3 for pre-tls roms (before androidarmv6 swapped the system and data Mount points in the kernel) used for kitkat roms around July 2014 or earlier or other 4.4 roms without the MTD partition swap

Needed: stock "install-recovery.sh"

can someone please upload the stock "install-recovery.sh"?
It's located in /system/etc.
I forgot to backup it, while rooting the device.
I need it for the OTA updates.
thanks
@vel_tins
Do not flash the ota if you are rooted, you might get bootloop. Full unroot your device before attempting to update. Anyhow, the ota will most likely fail since you already modified your system partition. Your best option is to unroot your device and capture the ota link, modify the ota updater-script and remove the lines that are showing "unexpected contents" errors. The original "install-recovery.sh" is still there, supersu renamed it to something like "/system/etc/install-recovery_original.sh". Keep in mind, you might loose your custom recovery if you renamed it back to "install-recovery.sh".
Well, OTA was a pain in the a**.
Because I had no stock "install-recovery.sh", I've edited the updater-script and removed all the matching entries.
Executed a full un-root.
Tried to flash the modified update.zip via TWRP, but failed because TWRP couldn't mount partitions with this name scheme:
Code:
"/dev/block/platform/[B]7824900.sdhci/by-name/system[/B]", "/system",
(will investigate later, any ideas?)
Because too lazy to modify the updater-script again,
I've booted into fastboot and loaded my "modded" stock recovery, which accepts also self-signed .zips.
Flashing worked well, but on reboot, I got a nice bootloop because of the formerly installed Xposed framework.
Had to restore from a Nandroid Backup and after reboot, I removed Xposed completely.
Eventually, I was able to flash the OTA and got back a working device...
Gosh...
^^
??
vel_tins said:
Well, OTA was a pain in the a**.
Because I had no stock "install-recovery.sh", I've edited the updater-script and removed all the matching entries.
Executed a full un-root.
Tried to flash the modified update.zip via TWRP, but failed because TWRP couldn't mount partitions with this name scheme:
Code:
"/dev/block/platform/[B]7824900.sdhci/by-name/system[/B]", "/system",
(will investigate later, any ideas?)
Because too lazy to modify the updater-script again,
I've booted into fastboot and loaded my "modded" stock recovery, which accepts also self-signed .zips.
Flashing worked well, but on reboot, I got a nice bootloop because of the formerly installed Xposed framework.
Had to restore from a Nandroid Backup and after reboot, I removed Xposed completely.
Eventually, I was able to flash the OTA and got back a working device...
Gosh...
Click to expand...
Click to collapse
If you still have the original OTA zip, can you please post it for future reference?
As for TWRP mounting /dev/block/platform/7824900.sdhci/by-name/system, what error message did you get? Try running "ls -l /dev/block/platform/7824900.sdhci/by-name/" in both normal Android and TWRP, then compare the results.
pawitp said:
If you still have the original OTA zip, can you please post it for future reference?
Click to expand...
Click to collapse
No problem
pawitp said:
As for TWRP mounting /dev/block/platform/7824900.sdhci/by-name/system, what error message did you get? Try running "ls -l /dev/block/platform/7824900.sdhci/by-name/" in both normal Android and TWRP, then compare the results.
Click to expand...
Click to collapse
Stock and Cyanogen recovery are working with this partition naming scheme.
But in TWRP, I get the following error message:
Code:
ls: /dev/block/platform/7824900.sdhci/by-name: No such file or directory
For TWRP I have to use the following syntax in recovery.fstab:
Code:
/cache ext4 /dev/block/mmcblk0p29
/system ext4 /dev/block/mmcblk0p25
/data ext4 /dev/block/mmcblk0p31 length=-16384
.........etc.
vel_tins said:
No problem
Stock and Cyanogen recovery are working with this partition naming scheme.
But in TWRP, I get the following error message:
Code:
ls: /dev/block/platform/7824900.sdhci/by-name: No such file or directory
For TWRP I have to use the following syntax in recovery.fstab:
Code:
/cache ext4 /dev/block/mmcblk0p29
/system ext4 /dev/block/mmcblk0p25
/data ext4 /dev/block/mmcblk0p31 length=-16384
.........etc.
Click to expand...
Click to collapse
On TWRP, try running "find /dev/block/platform" and see if anything is created there.
The directory should have been populated by init. See https://android.googlesource.com/pl...0ab94b7d5a888f0b6920b156e5c6a075fa0741a^!/#F0.
That code should also be in TWRP, but something might have prevented it from working properly on this device. You might find some clues in dmesg or TWRP's logs.
Well, eventually I've got it.
In TWRP, the naming is a little bit different from stock or Cyanogen recovery.
I had to change:
Code:
/dev/block/platform/[COLOR="Red"]7824900.sdhci[/COLOR]/by-name/cache <--- STOCK
to
/dev/block/platform/[COLOR="Blue"]soc.0[/COLOR]/by-name/cache <--- TWRP
However, the "/dev/block/mmcblk0p" naming worked also in TWRP, so this was only a minor issue.
vel_tins said:
Well, eventually I've got it.
In TWRP, the naming is a little bit different from stock or Cyanogen recovery.
I had to change:
Code:
/dev/block/platform/[COLOR="Red"]7824900.sdhci[/COLOR]/by-name/cache <--- STOCK
to
/dev/block/platform/[COLOR="Blue"]soc.0[/COLOR]/by-name/cache <--- TWRP
However, the "/dev/block/mmcblk0p" naming worked also in TWRP, so this was only a minor issue.
Click to expand...
Click to collapse
IMO, you should fix TWRP so that it has the same naming convention. Otherwise OTA packages using the "stock" naming convention can't be flashed on TWRP.
Personally, I prefer the "by-name" mapping rather than the "/dev/block/mmcblk0p" because it is harder to make mistakes if you use a name. With numbers, if a wrong number is typed, then you might end up flashing the wrong partition and bricking the device.
EDIT: It might have something to do with the "system/core" repository you've used to build your recovery. Which Android tree did you use to build Cyanogen Recovery and which one did you use to build TWRP?
vel_tins said:
Well, OTA was a pain in the a**.
Because I had no stock "install-recovery.sh", I've edited the updater-script and removed all the matching entries.
Executed a full un-root.
Tried to flash the modified update.zip via TWRP, but failed because TWRP couldn't mount partitions with this name scheme:
Code:
"/dev/block/platform/[B]7824900.sdhci/by-name/system[/B]", "/system",
(will investigate later, any ideas?)
Because too lazy to modify the updater-script again,
I've booted into fastboot and loaded my "modded" stock recovery, which accepts also self-signed .zips.
Flashing worked well, but on reboot, I got a nice bootloop because of the formerly installed Xposed framework.
Had to restore from a Nandroid Backup and after reboot, I removed Xposed completely.
Eventually, I was able to flash the OTA and got back a working device...
Gosh...
Click to expand...
Click to collapse
Hi sir ,
Please share to us , how you do this , because I have status 7. Install-recovery.sh problem
I have stock recovery , and I'm only make a root for my device by kingroot .
Please share update.zip file and tel me how to make ota update
pawitp said:
IMO, you should fix TWRP so that it has the same naming convention. Otherwise OTA packages using the "stock" naming convention can't be flashed on TWRP.
Click to expand...
Click to collapse
Exactly this is the point...
pawitp said:
EDIT: It might have something to do with the "system/core" repository you've used to build your recovery. Which Android tree did you use to build Cyanogen Recovery and which one did you use to build TWRP?
Click to expand...
Click to collapse
I have to correct myself, Cyanogen has exactly the same problem.
I've used the latest CM 12.1 and Omnirom source trees to build TWRP, but with the same result.
TWRP/Cyanogen only detects "soc.0" instead of "7824900.sdhci" and that will break compatibility with OTA packages (Until you patch "updater-script").
So how you made this ota update after all ?
theeteempire said:
So how you made this ota update after all ?
Click to expand...
Click to collapse
OTA doesn't work with rooted devices.
Do a full un-root and try again.
vel_tins said:
OTA doesn't work with rooted devices.
Do a full un-root and try again.
Click to expand...
Click to collapse
I did it , full unroot , I couldn't update even that with full-unroot , I used kingroot for root ,
Also error status 7 , install-recovery. Sh shown on the update after full-unroot my device !!!
can you help me please !!!!!
theeteempire said:
....I used kingroot for root ,
Also error status 7 , install-recovery. Sh shown on the update after full-unroot my device...
Click to expand...
Click to collapse
I would strongly suggest, to open an new thread, because I guess a lot more people will or had run into these issues.
I don't know what Kingsoft (never used it) has modified/replaced, so in your case I would search for a stock "install-recovery.sh" and replace the modified.
Everything else would be too complicated. (You have read my post on the first page).
vel_tins said:
I would strongly suggest, to open an new thread, because I guess a lot more people will or had run into these issues.
I don't know what Kingsoft (never used it) has modified/replaced, so in your case I would search for a stock "install-recovery.sh" and replace the modified.
Everything else would be too complicated. (You have read my post on the first page).
Click to expand...
Click to collapse
So I need the stock install-recovery. Sh ,.
Are you have it ?
vel_tins said:
Exactly this is the point...
I have to correct myself, Cyanogen has exactly the same problem.
I've used the latest CM 12.1 and Omnirom source trees to build TWRP, but with the same result.
TWRP/Cyanogen only detects "soc.0" instead of "7824900.sdhci" and that will break compatibility with OTA packages (Until you patch "updater-script").
Click to expand...
Click to collapse
This is just a guess. Try adding "TARGET_PLATFORM_DEVICE_BASE := /devices/soc.0/" to BoardConfig.mk.
If you know C, you might want to try mucking around in system/core/init/devices.c and see why it's behaving that way.
pawitp said:
This is just a guess. Try adding "TARGET_PLATFORM_DEVICE_BASE := /devices/soc.0/" to BoardConfig.mk.
.....
Click to expand...
Click to collapse
Seems to work, thanks!
PS: A google search for "TARGET_PLATFORM_DEVICE_BASE" threw only six results, so it doesn't seem to be a very popular flag.
vel_tins said:
Seems to work, thanks!
PS: A google search for "TARGET_PLATFORM_DEVICE_BASE" threw only six results, so it doesn't seem to be a very popular flag.
Click to expand...
Click to collapse
From my experience, you can't rely too much on Google for ROM development. I've found the flag by reading the source file I've previously mentioned.
Sent from my Nexus 4 using XDA Free mobile app

TWRP, ROOT and disable Encryption for Yoga Tab 3 Plus (YT-X703F/L)

TWRP is an open source, community project. TWRP development is done by roughly 4 people at this point. We also have a large support community with many people who are willing to answer questions and help people with their devices either through our IRC channel or on forums like xda-developers.
Team Win was originally formed to work on porting WiMAX to CM7 for the HTC EVO 4G. After our work on the EVO 4G we wanted to work on a project that would work on more devices than just the EVO 4G and we settled on working on a recovery. Today TWRP is the leading custom recovery for Android phones.
A custom recovery is used for installing custom software on your device. This custom software can include smaller modifications like rooting your device or even replacing the firmware of the device with a completely custom "ROM" like OmniROM
Click to expand...
Click to collapse
WARNING!!! Be careful what you do here. One mistake and the device is soft-bricked. I take no responsibility for bricked devices, lost warranty or even OTAs not working!! Booting and/or flashing files from this post is on your own risk.
Requirements
Unlocked bootloader
Yoga Tablet 3 Plus with and without LTE (YT-X703L and YT-X703F) are supported
Known Issues
WARNING! Our device uses dm-verity (verified boot). The system partition should remain read-only. Otherwise a bootloop will occur. You can flash my modified kernel or SuperSU to resolve this but OTA's are no longer possible! You have to restore a factory image or clean system backup to receive OTAs
Potentially DRM keys are lost! Pure unlocking and rooting does not cause the issue. However, there have been reports of lost DRM keys by some unknown action. It is advised to act with caution. Losing your DRM keys can lead to issues with some apps which use DRM which could then have limited or no functionality. E.g. Netflix will only stream in SD (480p). You can check with DRM info if you still have L1 security level which means DRM keys are intact.
Download
Official TWRP for YT-X703F (Wifi): twrp.me
Official TWRP for YT-X703L (LTE): twrp.me
Instructions
Install fastboot and adb on your PC, e.g. from here
Enable developer options and in there select to unlock your bootloader by enabling OEM unlock and enable USB debugging
Connect your PC to your tablet and run
Code:
adb reboot bootloader
using adb on command line. The tablet will reboot into bootloader mode where you will only see the Lenovo logo. Now you use
Code:
fastboot oem unlock-go
to unlock. This will factory reset your device
Setup the tablet again and reboot again to the bootloader
Then run
Code:
fastboot boot twrp-3.2.1-0-yt_x703f.img
to temporarily boot into TWRP. You can also flash if you are sure
Select to keep system read only when TWRP starts to avoid modification which will make OTAs impossible
Optionally flash SuperSU or Magisk in TWRP which should install system less. Keep OEM unlock enabled if you flash or modify anything
Additional Downloads
Backup of original boot, recovery and system image for YT-X703F S000936: MEGA
Modified Boot image with forceencrypt disabled and it switches off CABC fully. You need to factory reset after flashing to format data without encryption boot_yt_x703f_s000963_noforceencrypt_cabc.img (YT-X703F S000963) / boot_yt_x703l_s000963_noforceencrypt_cabc.img (YT-X703L S000963) . Use
Code:
fastboot flash boot boot_yt_x703f_s000963_noforceencrypt_cabc.img
to flash the kernel in fastboot. SuperSU or Magisk should be flashed afterwards if root is desired.
Full factory images with flash tool and instructions YT_X703F_S000689, YT_X703L_S000704, YT_X703F_S000725, YT_X703L_S000725, YT_X703F_S000734, YT_X703L_S000734, YT_X703L_S000744, YT-X703F_S000744, YT-X703L_S000963, YT-X703F_S000963 and OTA updates: MEGA (These images contain the individual boot, recovery and system images that you need to restore from any modification mentioned above)
System Updates (OTA)
In order to successfully apply Lenovo system updates after root you have to restore the original boot, recovery (if you flashed TWRP) and system partitions from your current installed version (e.g. S000744) for your variant of the tablet. This will NOT delete your apps and data but will unroot. Note that OTAs are block based and always check the contents of most of the partitions. This means that all of these partitions (except your data) have to be original and have to be on the exact same version (e.g. S000734) for the update to succeed.
See here for instructions how to restore the partitions with fastboot.
Credits
@pogo1975 - for providing the factory images and fixing the AV sync issue
@launcher20 and @deecept - for testing the LTE version
TeamWin
Changelog
v4:
Now official TWRP with version 3.0.3-0
v3:
enable full disk encryption for access to the encrypted data partition
update TWRP kernel to latest S000725 version
v2:
add support for LTE variant (YT-X703L)
add further mount points to be able to backup more data
Thanks buddy! You are an absolute champion! Tell me what you need me to do and I'll do it before rooting and up load what you need.
Doing good work here.
Who wants to bet on a race between matshias and Lenovo support for who can fix the issues with this device first?
That's great and fast, I'm thinking tab 3 plus is getting hot now.
Great to see there is something moving for the yoga now. You think it will support the lte Version anytime? Or maybee even lineageos?
so you know, i've managed to install xposed thanks to this thread https://forum.xda-developers.com/xposed/unofficial-systemless-xposed-t3388268 and is working well.
wayney said:
Thanks buddy! You are an absolute champion! Tell me what you need me to do and I'll do it before rooting and up load what you need.
Click to expand...
Click to collapse
Well if you haven't modified anything yet then it'd be great if you can boot into TWRP with system read only and then connect via ADB to the tablet with a big SD card inserted which has enough free space (4 GB).
The run the following command
Code:
dd if=/dev/block/bootdevice/by-name/system of=/sdcard1/system.img
This will take a while. Then copy the file system.img from your SD card to a PC and zip it (or 7z, rar). Then upload it
Gogoho said:
Great to see there is something moving for the yoga now. You think it will support the lte Version anytime? Or maybee even lineageos?
Click to expand...
Click to collapse
The LTE variant is probably very similar and it wouldn't be much work. But I don't own the device, so I would need some help. So someone with the LTE variant who is not afraid to experiment with fastboot and adb and who can provide me with the details needed I am happy to compile a TWRP for it.
LineageOS is much much more work than TWRP. For an experienced cyanogenmod/LineageOS dev it is not much of a thing and would take only a few days, especially since it is a Qualcomm device and there are already ports for devices with SD 652. But for me this is new as well so it'll take much longer. As soon as I have time I'll look into it.
matshias said:
Well if you haven't modified anything yet then it'd be great if you can boot into TWRP with system read only and then connect via ADB to the tablet with a big SD card inserted which has enough free space (4 GB).
The run the following command
Code:
dd if=/dev/block/bootdevice/by-name/system of=/sdcard1/system.img
This will take a while. Then copy the file system.img from your SD card to a PC and zip it (or 7z, rar). Then upload it
Click to expand...
Click to collapse
You forgot to tell me to go to adb shell :silly:
DD is currently doing a dump, non interactive so I hope it is still alive, it has been close to 1 hour so far. I will upload the clean image once it is done and await further instructions from you. :good:
I'm in Perth, Western Australia (UTC +8:00), so we might be playing timezone tag.
wayney said:
You forgot to tell me to go to adb shell :silly:
DD is currently doing a dump, non interactive so I hope it is still alive, it has been close to 1 hour so far. I will upload the clean image once it is done and await further instructions from you. :good:
I'm in Perth, Western Australia (UTC +8:00), so we might be playing timezone tag.
Click to expand...
Click to collapse
I think I forgot one more thing. The external SD card needs to be mounted in the TWRP menu. I believe it's not mounted automatically. So the DD command does nothing. It shouldn't take that long. Sorry about that!
It's UTC +1:00 here in Germany
matshias said:
Well if you haven't modified anything yet then it'd be great if you can boot into TWRP with system read only and then connect via ADB to the tablet with a big SD card inserted which has enough free space (4 GB).
The run the following command
Code:
dd if=/dev/block/bootdevice/by-name/system of=/sdcard1/system.img
This will take a while. Then copy the file system.img from your SD card to a PC and zip it (or 7z, rar). Then upload it
Click to expand...
Click to collapse
matshias said:
I think I forgot one more thing. The external SD card needs to be mounted in the TWRP menu. I believe it's not mounted automatically. So the DD command does nothing. It shouldn't take that long. Sorry about that!
It's UTC +1:00 here in Germany
Click to expand...
Click to collapse
I was wondering why nothing was happening after 3 hours.
I have rared it and it is uploading at the moment, it is going to take 5 hours.
wayney said:
I was wondering why nothing was happening after 3 hours.
I have rared it and it is uploading at the moment, it is going to take 5 hours.
Click to expand...
Click to collapse
Wow ok. Well thanks a lot for your efforts. This will not just help me but anyone with modified system partition to get OTAs.
Unmodified System Image
Here is the vanilla image via DD of the system partition.
Software Version : YT-X703F_160817
Android Version : 6.0.1
Security Patch Level : 1 September 2016
Kernel Version : 3.10.84-perf
Build Number : YT-X703F_S000689_161105_ROW
Tablet purchased retail from Australia.
https://mega.nz/#!bos0GIjI!vcO9dpSJX...Grjb7k3z6mjnqA
wayney said:
Here is the vanilla image via DD of the system partition.
Software Version : YT-X703F_160817
Android Version : 6.0.1
Security Patch Level : 1 September 2016
Kernel Version : 3.10.84-perf
Build Number : YT-X703F_S000689_161105_ROW
Tablet purchased retail from Australia.
https://mega.nz/#!bos0GIjI
Click to expand...
Click to collapse
Perfect!!
Can you send me the key for the download via PM or post it?
matshias said:
Perfect!!
Can you send me the key for the download via PM or post it?
Click to expand...
Click to collapse
Let's try that again.
https://mega.nz/#!bos0GIjI!vcO9dpSJXp6cKtdH07Kt0RSaqpqQ7Grjb7k3z6mjnqA
matshias said:
Wow ok. Well thanks a lot for your efforts. This will not just help me but anyone with modified system partition to get OTAs.
Click to expand...
Click to collapse
Thank you guys for spending times on it, it would be wonderful if Lenovo people do thing like this way, too.
In the depths of the Russian Internet i have found this
YT-X703F_USR_S000689_1611051146_Q00237_ROW.zip
https://drive.google.com/drive/folders/0B_jGuhC9WsNfYUZzZmhRY2NhQlU?usp=sharing
it is supose to be complete image to Wifi-Version.
I HAVE NOT FLASHED THIS YET. Do it on your risk.
pogo1975 said:
In the depths of the Russian Internet i have found this
YT-X703F_USR_S000689_1611051146_Q00237_ROW.zip
https://drive.google.com/drive/folders/0B_jGuhC9WsNfYUZzZmhRY2NhQlU?usp=sharing
it is supose to be complete image to Wifi-Version.
I HAVE NOT FLASHED THIS YET. Do it on your risk.
Click to expand...
Click to collapse
Hahaha got to love the dark corner of the Russian internets :laugh:
pogo1975 said:
In the depths of the Russian Internet i have found this
YT-X703F_USR_S000689_1611051146_Q00237_ROW.zip
https://drive.google.com/drive/folders/0B_jGuhC9WsNfYUZzZmhRY2NhQlU?usp=sharing
it is supose to be complete image to Wifi-Version.
I HAVE NOT FLASHED THIS YET. Do it on your risk.
Click to expand...
Click to collapse
If that's real it would have saved me a lot of time finding the loophole in the system to extract the boot and recovery image. But still a great find which will rescue some soft-bricked devices.
matshias said:
If that's real it would have saved me a lot of time finding the loophole in the system to extract the boot and recovery image. But still a great find which will rescue some soft-bricked devices.
Click to expand...
Click to collapse
so long as it's safe and not loaded with malware...

[kexec] droid4-kexecboot and booting raw partitions

We can now boot distros with droid4-kexecboot without being locked to the stock initramfs or rootfs :
droid4-kexecboot images
droid4-kexecboot buildroot source
It works by using utagboot generated mmcblk1p8 utags partition to boot the stock kernel to a 4MB buildroot image that can be flashed to the unused mmcblk1p13 bpsw partition. Then it starts kexecboot to use kexec for booting to the selected distro.
Currently supported are recent mainline kernels with the pending LCD patches added. SafeStrap is not necessary but can be booted to. And v3.0.8 legacy kernels installed into SafeStrap rom slots are supported (but need to be manually updated if slot kernels are updated) .
UPDATED: Booting to the stock Android and SafeStrap is now supported out of the box with for pivot_root.
Changes are needed to v3.0.8 kernel config and initramfs to not use CONFIG_CMDLINE_FORCE=y and safestrap/active_slot file and instead just use kernel cmdline to mount the desired rootfs. Distros using the mainline kernel do not have these limitations, and can use the 608MB mmcblk1p22 preinstall, 1.3GB mmcblk1p23 webtop partitions. And the 8GB mmcblk1p25 can also be reformatted to ext4 and used as rootfs if you don't need it for Android. I have not dared to try to reformat mmcblk1p20 system partition, but that too might be usable unless the Motorola bootloader does some checks on it on boot.
There are some experimental patches for initramfs modifications for postmarketos:
https://github.com/postmarketOS/pmbootstrap/pull/1039
But we need also similar Android changes if somebody has time to work on patching and rebuilding LineageOS
Nice, this works with lineage os on slot 1 now. Im currently building postmarketos and a mainline kernel to test
The bootloader refuses to boot with mmcblk1p20 erased. But a empty ext3 partiton is apperently enough to make it happy
IM_back! said:
The bootloader refuses to boot with mmcblk1p20 erased. But a empty ext3 partiton is apperently enough to make it happy
Click to expand...
Click to collapse
Oh interesting I don't think I've seen that. Do you mean the Motorola bootloader refuses to start or kexecboot? Sounds like we should document this and how to fix it if it happens if you can write up something on it for droid4-kexecboot README file.
tmlind said:
Oh interesting I don't think I've seen that. Do you mean the Motorola bootloader refuses to start or kexecboot? Sounds like we should document this and how to fix it if it happens if you can write up something on it for droid4-kexecboot README file.
Click to expand...
Click to collapse
The Motorola booloader goes directly to fastboot if i:
Code:
dd if=/dev/zero of=/dev/block/mmcblk1p20
but
Code:
mkfs.ext3 /dev/block/mmcblk1p20
keeps the Motorola bootloader happy. im not shure if it needs to be ext3 i just whent with that because thats what the stock rom uses. It is extreamly annoying that we can not flash modified system.img's via fastboot. I will experiment a bit more with it and submit a patch to the README file.
I got The mainline kernel to boot, but without a rootfs it dosent do anything usefull of course.
that aside i can't seam to get postmarketos to work. I installed pmos rootfs to the webtop partiton and supplyed kernel command line with PMOS_NO_SAFESTRAP and correct root= but it just boots to a black screen , no uart output either
Do you have something that works that i could take a look at?
IM_back! said:
The Motorola booloader goes directly to fastboot if i:
Code:
dd if=/dev/zero of=/dev/block/mmcblk1p20
but
Code:
mkfs.ext3 /dev/block/mmcblk1p20
keeps the Motorola bootloader happy. im not shure if it needs to be ext3 i just whent with that because thats what the stock rom uses. It is extreamly annoying that we can not flash modified system.img's via fastboot. I will experiment a bit more with it and submit a patch to the README file.
Click to expand...
Click to collapse
Interesting so it seems that the cdt.bin mmcblk1p6 partition tells mbmloader to check some partitions for content and some partitions just for the fs. I wonder if also for example cdrom mmcblk1p16 partition can be modified too that way.
IM_back! said:
I got The mainline kernel to boot, but without a rootfs it dosent do anything usefull of course.
that aside i can't seam to get postmarketos to work. I installed pmos rootfs to the webtop partiton and supplyed kernel command line with PMOS_NO_SAFESTRAP and correct root= but it just boots to a black screen , no uart output either
Do you have something that works that i could take a look at?
Click to expand...
Click to collapse
As a test I only verified that NotKit's kernel mentioned in his postmarketos pull request boots with uart with kexecboot after I noticed he has a patch for gcc6 support and APKBUILD prepare -Werror search and replacement
I enabled CONFIG_EMU_UART_DEBUG=y, disabled CONFIG_CMDLINE_FORCE and configured kexecboot boot.cfg to use CMDLINE=console=ttyO2,115200 [email protected] vram=10300K omapfb.vram=0:8256K,1:4K,2:2040K ro rootwait root=/dev/mmcblk1p13 debug earlyprintk' to boot back to droid4-kexecboot.
tmlind said:
As a test I only verified that NotKit's kernel mentioned in his postmarketos pull request boots with uart with kexecboot after I noticed he has a patch for gcc6 support and APKBUILD prepare -Werror search and replacement
Click to expand...
Click to collapse
FYI, the postmarketos pull request mentioned above has been now merged. And I pushed out updated droid4-kexecboot images last night that now also support booting to the stock Android and SafeStrap.
I will be trying to get this thing to boot for my phone motorola electrify 2. Don't have much of knowledge but atleast trying is not going cost me alot .
mmcblk1p16 partition is usable as alternative ISO storage
tmlind said:
Interesting so it seems that the cdt.bin mmcblk1p6 partition tells mbmloader to check some partitions for content and some partitions just for the fs. I wonder if also for example cdrom mmcblk1p16 partition can be modified too that way.
Click to expand...
Click to collapse
Actually, after some trial and error I managed to turn the cdrom partition (mmcblk1p16) into something more useful. Now my maserati works as a portable "Linux booting device"
When plugged to a computer it behaves by default as a CD-ROM drive, and it's capable of booting a Linux ISO on the PC. Bear in mind that the partition size is slightly above 200 MB, so we have limited space. Apparently if mmcblk1p16 is formatted as ext3, ext4 or contains a filesystem other than ISO, the phone will NOT boot (I had to reinstall the whole Stock firmware a few times).
I could make a mini tutorial with detailed instructions.
So perhaps this partition could be useful for storing a customised read-only distro for the maserati, similar to a Live environment. Or at least capable of booting a minimum environment with essential files.
I'd like to test your kexec files as soon as I can, but still need to understand the whole process. About to receive a second maserati for tests
Cheers!
dinosaur99 said:
Actually, after some trial and error I managed to turn the cdrom partition (mmcblk1p16) into something more useful. Now my maserati works as a portable "Linux booting device"
Click to expand...
Click to collapse
Hey that's great! FYI, one more thing to consider is that I noticed allow-mbmloader-flashing-mbm.bin is more permissive compared to mbm.bin. They seem to parse some permissions table from cdt.bin. I guess it would not be too hard to figure out that format if somebody cares. And I now also wonder if using cdt.bin_patch instead of cdt.bin is even more permissive?
Anyways, do not mess with the mbmloader.bin or allow-mbmloader-flashing-mbm.bin partitions though that can brick the device..
tmlind said:
FYI, the postmarketos pull request mentioned above has been now merged. And I pushed out updated droid4-kexecboot images last night that now also support booting to the stock Android and SafeStrap.
Click to expand...
Click to collapse
Thank you for your excellent work!
Can't boot to safestrap
This is my first approach to boot something other than Android. Not very usable though, but I got this far.
I first installed droid4-kexecboot following instructions on README, and created the boot/boot.cfg on a fresh EXT4 sdcard by copying the sample rom-slot1 and rom-slot2 entries. After reboot, kexecboot shows a very nice graphical menu, and loads successfully all configurations. Unfortunately the slot entries don't work from kexecboot (phone restarts). However I can load Safestrap and boot stock and both ROM slots.
Then I built latest postmarketOS for Droid 4 using pmbootstrap, and selected Weston (one of the lightweight flavours). The result is three files: kernel, initramfs and a disk image containing two partitions. In order to install pmOS into rom-slot2, I wiped all slot2 partitions and installed CM11 as explained here https://wiki.postmarketos.org/wiki/Motorola_Droid_4_(motorola-maserati) . The next steps were done locally on my laptop instead of using ADB (i.e. replace file userdata.img in rom-slot2 directory with the pmOS disk image, and also replace /etc/kexec/ramdisk.img and /etc/kexec/kernel located inside system.img with the new initramfs/kernel). Then rebooted, jumped from kexecboot to Safestrap, and it launched postmarketOS.
USB networking connects right away and SSH works.
The wiki states that Framebuffer graphics works, but I get no screen output. LCD backlight is on. Xwayland and weston are running by default.
All LEDs work.
Touchscreen, vol buttons and keyboard seem to work.
Kernel is 3.0.8.
Finally I managed to boot pmOS with kexecboot. Directory "boot" on mmcblk0p1 contains following files:
Code:
atags # borrowed from safestrap
boot.cfg
devtree # borrowed from safestrap
initramfs-motorola-maserati
vmlinuz-motorola-maserati
Here's a few facts that I don't really understand
kexecboot boots pmOS on rom-slot only if safestrap is configured to boot on that slot, otherwise it boots into something else which responds to ping, but no SSH. Why is this happening if kexecboot overrides safestrap?
Excuse my ignorance, but what is in practice the need for a devtree file, and where am I supposed to obtain it?
The kernel cmdline is apparently overriden by atags file required to boot linux 3.0.8. It seems like boot configuration is hardcoded somehow. But why doesn't it boot regular android slots?
Is it actually possible to pass something like root=/dev/mmcblk0p1 or maybe even get screen working by using a recent kernel?
Sorry if I mixed up too many different topics... just trying to sort the whole thing out.
Thanks!
Is it possible to boot LineageOS with a Linux kernel of 3.20 or higher?
dinosaur99 said:
Here's a few facts that I don't really understand
kexecboot boots pmOS on rom-slot only if safestrap is configured to boot on that slot, otherwise it boots into something else which responds to ping, but no SSH. Why is this happening if kexecboot overrides safestrap?
Excuse my ignorance, but what is in practice the need for a devtree file, and where am I supposed to obtain it?
The kernel cmdline is apparently overriden by atags file required to boot linux 3.0.8. It seems like boot configuration is hardcoded somehow. But why doesn't it boot regular android slots?
Is it actually possible to pass something like root=/dev/mmcblk0p1 or maybe even get screen working by using a recent kernel?
Sorry if I mixed up too many different topics... just trying to sort the whole thing out.
Click to expand...
Click to collapse
Sorry for being slow to respond..
There is an issue with most droid4 images using the 3.0.8 kernel files and init scripts which is the scripts check the SafeStrap config from the mmc for things to mount etc.
This is no longer needed at and the scripts should be just modified to do that only if booted with safestrap. We should now just use standard Linux way meaning
parse the partitions to mount from kernel command line and so on NotKit posted some patches to sort out that as linked in the first post in this thread for the
PostmarketOK pull request. But I don't think those are applied and also the Android Images need to be updated too for LineageOS and then you can just boot
Android from whatever partition you like such as mmcblk0p1 or mmcblk1p25 in the standard Android way.
So omebody just please do standard LineageOS images that don't rely on SafeStrap!
The devtree file is only needed for old 3.0.8 kernels and is non-compatible with the current mainline kernel dtb file omap4-droid4-xt894.dtb. Motorola used custom
device tree properties and it's in big-endian format. The devtree file should be the same as what you have on the eMMC devtree partition mmcblk1p11.
Current mainline kernel still has the LCD patches pending, for v4.19-rc series I posted the pending patches I have to:
https://git.kernel.org/pub/scm/linux/kernel/git/tmlind/linux-omap.git/log/?h=droid4-pending-v4.19
Those are still being worked on though because of omapdrm changing over to use generic displays.
andeaker said:
Is it possible to boot LineageOS with a Linux kernel of 3.20 or higher?
Click to expand...
Click to collapse
See the previous post about v4.19-rc5 kernel status. No idea how much work it would be to get LineageOS images working with the
mainline kernel.. Probably at least the graphics would be an issue. Using TI's Android tree with droid4 patches backported to it might
be a good starting point if somebody wants to experiment with that, TI might have SGX540 support there for other SoCs.
how would i go about getting this working n the droid bionic? im wanting to run maemo-leste, but the latest update switched from just safestrap and ddroid, to this. and apparently trying to stupidly flash this as-is didnt work out
tvall said:
how would i go about getting this working n the droid bionic? im wanting to run maemo-leste, but the latest update switched from just safestrap and ddroid, to this. and apparently trying to stupidly flash this as-is didnt work out
Click to expand...
Click to collapse
Hmm you probably need to stick with SafeStrap for bionic, I don't think bionic uses a utags partition that's needed for the kernel cmdline.
tmlind said:
So omebody just please do standard LineageOS images that don't rely on SafeStrap!
Click to expand...
Click to collapse
I finally got around finishing writing some docs for installing LineageOS to raw partitions, please test
Make back-ups as needed first though.
For instructions, see files PARTITIONS and INSTALL at:
https://github.com/tmlind/droid4-kexecboot
hope this is on-topic - is it possible to use this to boot an OS that's installed on the SD card? I don't have D4 yet, but am waiting to receive one in the next few weeks.
sicelo.m said:
hope this is on-topic - is it possible to use this to boot an OS that's installed on the SD card? I don't have D4 yet, but am waiting to receive one in the next few weeks.
Click to expand...
Click to collapse
Yeah you can boot whatever Linux distro(s) you prefer from the SD card with the current mainline kernel and few pending patches.
That's all work in progress though, certainly usable for tinkering though
I doubt that booting Android on the SD card currently works though.

Categories

Resources