yashsingh1/xdaforums huggingface dataset:
[LG Optimus 3D] troopii:
ok the building has now completed :D i forgot to recreate the swapfile last time i extended the vm disksize

but i thougt i would create a flashable.zip file....

what is the easiest way to create a flashable.zip?

sorry for that question ;D
[LG Optimus 3D] JunDavis:
Kernel right? I'm not sure of the links to the guides but they have some. Just need to boot.img
[LG Optimus 3D] troopii:
No boot.img is created. I mean to create a flashable.zip with boot.img and system.img. but dreccon told me how it works.

Have now a new problem. When i flash it, twrp cant mount system after flash and i have to flash again stock rom. Im on twrp 2.2.2.1. I think i have to build a newer version.

When using cm recovery wich is created by default i get a mmc error.

Im sure its easy to fix when know what to do :)
[LG Optimus 3D] JunDavis:
In board config you should enable touch recovery. That may require a new build though. As for me repo isn't being nice and sync isn't working. Hopefully I can get it to though :P
[LG Optimus 3D] troopii:
for your repo problem, commit first everything.

then use:

repo forall -vc "git reset --hard"

after that your repo should sync again

edit

"brunch cm_p920-userdebug" creates a flasable.zip

our fstab.cosmo is outdated too. fixing this and we can flash, the question is, does it boot ��

edit

got a flashable.zip lets see whats happen ;D

edit

nothing happen, fstab.cosmo need a fix

edit 10.3 6:30

seems i fixed fstab.cosmo

have now this error when flashing

ApplyParsedPerms: removexattr of /system/addon.d/50-cm.sh to 0 failed: Operation not supported on transport endpoint
script aborted: set_metadata_recursive: some changes failed
set_metadata_recursive: some changes failed
E:Error executing updater binary in zip '/sdcard/cm-11-20140309-UNOFFICIAL-p920.zip'
Error flashing zip '/sdcard/cm-11-20140309-UNOFFICIAL-p920.zip'

the error happens because outdated recovery,

i give up building a working recovery wich mounts internal and external sd
[LG Optimus 3D] JunDavis:
Scratch that, actually I didn't read your last remark. Yes that is most likely the problem :P
[LG Optimus 3D] troopii:
managed to get twrp 2.7 builded, used the wrong repo...

so lets see if it flash now ;D

twrp says no se linux support in kernel ;(

same error again when flashing metadata ....
[LG Optimus 3D] Evisceration:
selinux for the kernel:

https://github.com/NamelessRom/andr...mmit/39d5ef4261d67edd5e237cc7fd6fe401e6ac0618

metadata (not supported on older recoveries)

build side:

https://github.com/NamelessRom/android_build/commit/437843b8bb91207db8aa071626b035da139ebc25

device tree addition: (line 168)

https://github.com/NamelessRom/android_device_lge_p970/blob/android-4.4/BoardConfig.mk#L168
[LG Optimus 3D] 5fusion:
feels good to see some dev activity for this dying device :). All the best guys:good:
[LG Optimus 3D] JunDavis:
Do you know why it isn't supported for older devices? Seems odd
[LG Optimus 3D] Evisceration:
never syntax which the recovery isnt understanding.

it uses "set_metadata" and "set_metadata_recursive" and the recoveryies do not understand it.

its for applying the selinux stuffs, so with the build and device changes it should flash fine.

you could also edit the updater script manually and replace all the metadata ones with the older syntax but its a lot of work :D

and selinux is needed for the kernel as android is enforcing it.

so with these changes it should work :)

then, as i doubt you have a sepolicy, you can disable selinux on boottime as well, in case it causes issues like broken audio etc.
[LG Optimus 3D] troopii:
ok its now flashing :D

but its stucked on booti_mmc..... at this point the kernel should loaded

i think it has something todo with my fstab

changed the fstab now like the p970 but with the p920 blks
[LG Optimus 3D] Evisceration:
just as reminder, do not hardcode sdcard paths like /storage/sdcard0 in fstab, use "auto" instead :D
[LG Optimus 3D] JunDavis:
Went to sync again today and repo becomes unresponsive while starting on the device tree. Not sure what I'll be doing :confused:
[LG Optimus 3D] troopii:
i use repo only for stuff i dont change. the device tree and kernel push/pull i with git. if you want a gui, install gitgui.

new problem now

hes going over booti_mmc but after that the screen shows green and redlines. when i boot from recovery it shows the last screen from the recovery in these colors.

at this point adb is not up, so i have no idea whats wrong.

is it normal that the boot.img for cm11 does not contain the ramdisk?

in bernies pacman rom the boot has also no ramdisk.
[LG Optimus 3D] lzzar:
The green and redlines is a bug that also is present in cm10 and cm10.1

Also showing last screen on boot
[LG Optimus 3D] JunDavis:
Wouldn't it's implementation have to removed from the kernel for it to be like that? If so, why would it be removed?
[LG Optimus 3D] troopii:
hm ok so its some kind normal and i shouldnt worry about :D

then i think it has something to do how the partitions get mounted. i only changed the fstab but not the init.cosmo.rc

looking in our storage_list.xml we have two non emulated storages.

this contains only stuff for a emulated and primary storage.

also the p970 device tree is not very helpfull at this point. i only understand trainstation ;D
[LG Optimus 3D] JunDavis:
So physical primary and secondary?
[LG Optimus 3D] 5ajad:
good luck guys...i know you can do it:)
[LG Optimus 3D] troopii:
Yep both are physical.

Finaly i got adb running during boot. But i tells me im unauthorized,

How can i authorized my pc without fully boot android?
[LG Optimus 3D] shaqfu786:
You could try one of these answers, might workhttp://stackoverflow.com/questions/18011685/why-i-cant-authorized-nexus4-device-in-the-adb
[LG Optimus 3D] JunDavis:
Stolen from the link given above.
[LG Optimus 3D] Evisceration:
set adb to insecure :)

to your build prop add "ro.adb.secure=0" and build with it, this allows you to get adb access even if you havent authorized the device.
[LG Optimus 3D] JunDavis:
Deeeleetedddd
[LG Optimus 3D] lzzar:
What is deleted? ?

Sent from my 3D phone.
[LG Optimus 3D] JunDavis:
Post I made
[LG Optimus 3D] shaqfu786:
If you guys are still busy on this project, here's a little info

http://source.android.com/devices/tech/security/se-linux.html

http://selinuxproject.org/page/NB_SEforAndroid_1

And this

http://xdaforums.com/showthread.php?t=1943625
[LG Optimus 3D] JunDavis:
SE Linux additions were already made thanks to Troopii but thanks for your interest. :D
[LG Optimus 3D] troopii:
I lost my motivation.

Because i cant use my pc while its building.

Also i have to give love to other stuff.

The next month im not playing on it.

But theoreticaly its bootable.

Most thx goes to Evisceration
[LG Optimus 3D] berni987654321:
So guys,

maybe have some good news for you. Fife months ago I lost my p920 on the way back home after a pretty long night :rolleyes: , today I got a call from my lokal police department that they've found it, but I don't know if it's still functional. But to tomorrow we'll know :D

But back to the topic, I'm not completely done reading the whole thread but I can tell you till now:

-we have to work on the device tree (e.g. hwc, maybe audio...)

-update the kernel

-maybe edit some Google libs(I had some errors when compiling audio libs on android 4.3)

-the p970 won't help us much (different cpu...) But maybe some Motorola devices or a Samsung phone, can't remember which it was

-most likely I've forgotten something

P.S don't use my kernel tree, I messed it up some months ago and it will need some time to fix it up. For now use the one that is forked to the lg kernels repo you'll find it by searching a bit on my git
[LG Optimus 3D] amazing 3D:
Iam so glad to hear that and I hope that your phone will be functional, and we will see [ EDITED ] you here again master

Sent from my LG-P920
[LG Optimus 3D] troopii:
Great news :)

Hw composer is fixed and audio does not throw an error while building.

I noticed that your kernel is broken and forked that from iodak.

I havent pushed my latest changes to the kernel. Will do it in the after noon.

Greets from garching to arting ;D
[LG Optimus 3D] niko22225:
Welcome back master
[LG Optimus 3D] Evisceration:
its not meant that you can use the p970 tree 1:1, its just to show the concepts used, to revive it from its legacy state, its running without major problems on kitkat :)

kernel just needs selinux functionality

editing proprietary libs can give you a hard time, unless you can reverse engineer them good enough. for that there are the legacy flags, like

-DICS_AUDIO_BLOB

or

-DICS_CAMERA_BLOB

(as you can see in the p970 tree ;P)

dont know if you catched it up or did it, but just as reminder, set selinux to permissive until you have done the policies.

this will save you from a lot of troubles and restore functionality of most features.

(eg on some phones audio breaks, if selinux is enforcing. set it to permissive and its working like a charm)

to set it to permissive, add that to your board kernel cmdline or add that line, if it isnt there. (in BoardConfig)

BOARD_KERNEL_CMDLINE := androidboot.selinux=permissive

and kernel side looks like that, i guess that you already added selinux support.

to disable it on bootup my selinux section in my defconfig looks like this.

you may or may not add the bootparam ones, i added them as failsave :P

CONFIG_SECURITY_SELINUX=y
CONFIG_SECURITY_SELINUX_DEVELOP=y
CONFIG_SECURITY_SELINUX_AVC_STATS=y
CONFIG_SECURITY_SELINUX_BOOTPARAM=y
CONFIG_SECURITY_SELINUX_BOOTPARAM_VALUE=0
CONFIG_SECURITY_SELINUX_CHECKREQPROT_VALUE=1
[LG Optimus 3D] JunDavis:
Yes it was a Motorola device. I had been looking at it's device tree for a short while. The Atrix 2 I think it was. Anyways, I just recently purchased a Nexus 5 for myself and will be mostly focusing on that. I still own my P920 but a family member is currently using it for about a month. Just an update.
[LG Optimus 3D] berni987654321:
looks like it's completly broken, but I'm going to try to clean it
[LG Optimus 3D] DiveNNN:
That looks really bad .Hope you fix it :fingers-crossed:
[LG Optimus 3D] Vaimaster:
any progress so far? :D
[LG Optimus 3D] itsmemario:
I also still own the O3D and Im very happy with it! :)

A working Cyanogenmod 11 might push me back into flashing this baby again. :)
[LG Optimus 3D] shaqfu786:
Is anyone still trying to get 4.4 booting? With Google releasing kk for the Google glass, this could be a stepping stone for us to get kk, maybe even a 3.4 kernel.

Bernie did you get your device fixed?

I'm trying to get my cuz it give me his to donate to the community, it fell, still works but screen is cracked, and he bought another one second hand. At the moment he is a bit reluctant. Will let y'all know if I persuade him.
[LG Optimus 3D] shaqfu786:
Some good info

http://xdaforums.com/showthread.php?t=2071021
[LG Optimus 3D] berni987654321:
OK my device is broken maybe I'll buy a used one on eBay
[LG Optimus 3D] itsmemario:
You have no idea how good it feels to have you back ! :'D

I recently flashed p920_PAC_JB_4.2.2-v22.1.0_20130414-042500 and I am amazed !!!!

Im still loooking for your version 23.0 of this PACMAN ROM, but I cant find it anywhere. But hey, maybe I dont even need it. This 22.1.0 is just awesome ! :D Ok, need to calm down now. ;)

Back on topic as well.

Recieving a working KitKat for our p920's would be the next big step forward. Reading about all this "it runs hellagood on "old" devices" makes me go mad. >_<
[LG Optimus 3D] berni987654321:
I'm back!

Getting the sources synced will take a while but tomorrow I'll start to work on it
[LG Optimus 3D] amazing 3D:
Welcome Back!

Master :)
[LG Optimus 3D] drastic00:
Nice. I'll stay tuned. Good Luck guys!
[LG Optimus 3D] berni987654321:
OK I'll start with cm10.2 and built already a cwm from source using Ricardo's cm10.2 omap4 kernel source, but it doesn't work correctly yet.

Which kernel/branch did u use till now to build?
[LG Optimus 3D] shaqfu786:
I think they used original ics kernel source. The only thing they updated was the device tree by troopi.
[LG Optimus 3D] Evisceration:
*) download a official copy of CWM

*) extract its zImage

*) compile cwm on your own

*) unpack your own compiled copy

*) replace the zImage with the one you extracted from the official CWM

*) repack it, flash it

*) done :)
[LG Optimus 3D] berni987654321:
Lol I did that to see if the updated kernel is working, a newer version of cwm wasn't my aim
[LG Optimus 3D] Evisceration:
well, the p970 ports i did, the kernel didnt work for cwm but works for the rom itself.

thats not making it 100% sure that it will work for the rom.

you can take the ics kernel just like it is and need to enable SELinux, thats it, nothing more needs to be done to make it kitkat compatible.
[LG Optimus 3D] berni987654321:
I think were not talking about the same kernel, I use the lge omap4 kernel used by Ricardo till cm10 for the p920. He then did some changes on it for the ?p760, not sure? Cm10.2 port. I think it is the most reliable one for the p920 to start, but I'm not sure if there'll be problems cause off the changes he did on the cm10.2 branch to make it better work on the ?p760?.

The reason I want to use the cm/aosp kernel is that there are many little bugs fixed which are in the official lg ICS kernel like many not very well implemented ti patches.

Till froyo there is always used the same kernel in the recoverys like in the aosp ROMs. I'm know that in gingerbread there was a way to use the lg kernel but I don't know about any one who actually did that.

Damn this post was a bit longer than I wanted it to be... :D
[LG Optimus 3D] Evisceration:
nono, speaking about the kernel generally.

for kitkat you only need to enable selinux, thats it :)

(dont forget to set selinux to permissive though)

you can carry the same old kernel over, so dont worry much about that, thats what i wanted to say :)

the only problem is that frameworks av etc changed a lot and its likely going to break in there, causing services to die on bootup and welcome the well known bootloop :D
[LG Optimus 3D] berni987654321:
OK thank you very much for that information. What do you know about the hwc? I know the basics about it but where could I find something about updating the hardwarecomposer.h?/what would happen if I would just remove/exclude it for now?
[LG Optimus 3D] Evisceration:
i carried over the same hardware composer, i didnt change anything.

but as you say, best is to exclude it for now.

you can do that in the device tree. it should boot without it as well :)
[LG Optimus 3D] troopii:
ok i see the cyanogenmod logo and adb is up :D

adb tells me:

05-08 20:32:07.750: E/SchedPolicy(129): add_tid_to_cgroup failed; policy=1

complete log http://pastebin.com/GGF7a3eZ
[LG Optimus 3D] Evisceration:
awesome, well done! :D

can you post the whole log somewhere? :)
[LG Optimus 3D] itsmemario:
Reading this feels like a steady progress. ^^

I wish I had the time to get deeper into device trees and kernels. :cowboy:

1990, when everything was so easy. :victory:
[LG Optimus 3D] troopii:
I think it has something todo with the ram disk, i first used that from cm but that produce that red green lines. After that i used the ramdisk from stock ics v30b and see the cm logo. So its something how stuff gets init.
[LG Optimus 3D] Evisceration:
yep, i have never seen this before.

but it fails to load the ssl stuffs and cant verify the certificates of the apps and burns haha :D

if you are on ubuntu, sudo apt-get install meld

meld is a awesome little tool to display differences between files and folders.

you could take the two device trees and compare them with meld and maybe you then see whats causing this.
[LG Optimus 3D] berni987654321:
My cm10.2 build is completed but it doesn't flash, don't know if it is related to the metadata stuff, if I flash the IMG files directly it doesn't pass the random color screen ==> can't fetch logcat. I'll take a look at the ramdisk.
[LG Optimus 3D] troopii:
for metadata see this post http://xdaforums.com/showpost.php?p=51030735&postcount=53

with that cm ramdisk i get always in logcat where the devices name is: no_exec_/bin/sh folder_no_exec, thats why i started changing the ics ramdisk.

i attached my boot.img and twrp2.6.3 maybe u can use it

--edit

i passed the battery issue by commeting it out =D

now i see android is upgrading starting apps... =D

now logcat is flooded by:

05-18 09:18:32.000: E/AudioService(476): Media server died.
05-18 09:18:32.000: I/ServiceManager(476): Waiting for service media.audio_policy...
05-18 09:18:33.000: I/ServiceManager(476): Waiting for service media.audio_policy...
05-18 09:18:34.000: I/ServiceManager(476): Waiting for service media.audio_policy...
05-18 09:18:35.000: I/ServiceManager(476): Waiting for service media.audio_policy...
05-18 09:18:36.000: I/ServiceManager(476): Waiting for service media.audio_policy...
05-18 09:18:37.000: W/AudioSystem(476): AudioPolicyService not published, waiting...
[LG Optimus 3D] berni987654321:
are u using the -ICS_AUDIO_BLOB flag? maybe it is related to that
[LG Optimus 3D] shaqfu786:
I'm rooting for you guys, I know you will get it right. I just got a 64 bit system recently and busy setting it up. I don't know much programming but I'm willing to learn and this is base.Once cm11 boots I would like to try my hand at carbon.its awesome.

Thanks for your dedication guys.

Much appreciated.:thumbup:
[LG Optimus 3D] troopii:
sorry didnt updated my changes but now they are pushed

i use

BOARD_HAVE_PRE_KITKAT_AUDIO_BLOB := true

COMMON_GLOBAL_CFLAGS += -DBOARD_HAVE_PRE_KITKAT_AUDIO_BLOB -DICS_CAMERA_BLOB

but now im trying it with disabling audio ;D

BOARD_USES_GENERIC_AUDIO := true

i just wont to have it booted:D
[LG Optimus 3D] berni987654321:
Yeah audio could get a problem if you remember the time when ricardo didn't release ICS because of the audio not working. Don't know what changed audio related between jellybean and kitkat
[LG Optimus 3D] Evisceration:
any more logs about audio?

do you get some segfaults?

had this problem too and hacked me through fw/av ;p

that was because some code didnt get ifdeff'ed
[LG Optimus 3D] troopii:
no sorry there is no more log about, its only crashing

but i diff my code with yours
[LG Optimus 3D] Evisceration:
oh ok.

by the way, did you also set "-DICS_AUDIO_BLOB" ?

and thats the av commit i did to get all up and running.

https://github.com/NamelessRom/android_frameworks_av/commit/e3325146b30784e95e0206016c20d8ca99c0776d

setting the flag could be worth a try. if build breaks, try to apply that commit too :)
[LG Optimus 3D] troopii:
i set now also the -DICS_AUDIO_BLOB and rebuilding

i will know more in 4h, big thx again

-- edit

had to apply the legacy hack too,

and also had to add it for the goldfish/audio_hw.c

i thougt this is only needed when building the emu

Import includes file: /home/troop/cm11/out/target/product/p920/obj/SHARED_LIBRARIES/audio_policy.default_intermediates/import_includes
device/generic/goldfish/audio/audio_hw.c: In function 'out_dump':
device/generic/goldfish/audio/audio_hw.c:106:5: warning: implicit declaration of function 'fdprintf' [-Wimplicit-function-declaration]
device/generic/goldfish/audio/audio_hw.c: In function 'adev_open_output_stream':
device/generic/goldfish/audio/audio_hw.c:416:16: error: 'struct audio_stream_out' has no member named 'get_next_write_timestamp'
device/generic/goldfish/audio/audio_hw.c: In function 'adev_open':
device/generic/goldfish/audio/audio_hw.c:656:17: error: 'struct audio_hw_device' has no member named 'get_master_volume'
device/generic/goldfish/audio/audio_hw.c:657:17: error: 'struct audio_hw_device' has no member named 'set_master_mute'
device/generic/goldfish/audio/audio_hw.c:658:17: error: 'struct audio_hw_device' has no member named 'get_master_mute'
device/generic/goldfish/audio/audio_hw.c:664:40: warning: assignment from incompatible pointer type [enabled by default]
device/generic/goldfish/audio/audio_hw.c:665:37: warning: assignment from incompatible pointer type [enabled by default]
device/generic/goldfish/audio/audio_hw.c:667:36: warning: assignment from incompatible pointer type [enabled by default]

something to laugh ;D

/home/troop/cm11/kernel/lge/omap4-common/drivers/usb/gadget/android.c:1866:13: warning: 'android_destroy_device' defined but not used [-Wunused-function]

-edit

latest log

http://pastebin.com/w94VNEKt

it has nothing changed, but the log contains nothing about why ;/

again 05-19 18:54:04.351: I/ServiceManager(498): Waiting for service media.audio_policy...

-edit

second boot says

05-19 19:27:19.453: W/AudioSystem(480): AudioFlinger not published, waiting...

05-19 19:27:19.953: I/ServiceManager(480): Waiting for service media.audio_flinger...

--edit

found something interessting, but we cant use alsa driver?

http://www.phonesdevelopers.com/1800086/

found this on the ti dev site
[LG Optimus 3D] lzzar:
Haha well im glad that it isn't used!

//Sent from somewhere in your house
[LG Optimus 3D] berni987654321:
Im pretty sure that this will work, our device uses alsa audio if I'm not completely wrong.

--edit OK we've used alsa audio on gingerbread (look at cm7 device tree boardconfig) ricardo removed that flag on jellybean ==> audio won't work on jellybean or higher or it breaks the build/can't be build on android 4.*/ I'm completely wrong and everything will be fine and we'll be playing with little pink unicorns ;D
[LG Optimus 3D] Evisceration:
well, im still using ALSA on the p970 and it works pretty fine ;P

the problem has to lie somewhere else.
[LG Optimus 3D] berni987654321:
Yeah, but there is something with the p920 audio driver/card which is pretty special and no other device is using. That's the reason why audio wasn't working on cm9 till lg released the source code. I don't know what alsa especially is or what it does, and I don't have time to inform me about it :( , but our grand guru removed the flag on the upgrade from cm7.2 to cm10 and I think he knows why :p
[LG Optimus 3D] shaqfu786:
First off, I would like to say that I am not a programmer or know what it takes to get cm to work on our device,but would like to help. So I would like to know if any of these patches will work or could be used as reference,

http://people.canonical.com/~ppisati/ti-omap4-tilt-34-on-35/tilt-3.4/already/.

Forgive my stupidity if none of this adds value to our device.:D

Maybe this could help too,

http://xdaforums.com/showthread.php?t=2535705.
[LG Optimus 3D] itsmemario:
Just out of curiosity.

ALSA = Advanced Linux Sound System ?

A Linux kernel component which replaced the original Open Sound System (OSSv3) ?

And only our p920 is using it ?

https://wiki.archlinux.org/index.php/Advanced_Linux_Sound_Architecture

If so...our phone just became even more "special". :p