yashsingh1/xdaforums huggingface dataset:
[Nexus 10 Original Android Development] b1g.p0ppa:
I did just what you said, took these two files from the 1227 ROM and put them on the 105 linaro ROM, and the video still errors out. Attaching dmesg and logcat. Thanks for working on this, but please know this is not a show stopper for me. I will just dirty flash the 1227 ROM if I need to use Plex. I was on vacation last week and wanted to watch videos remotely. I don't use Plex on a daily basis and everything else works great.
[Nexus 10 Original Android Development] Khaon:
Ok reading the logcat I could identify the culprit of the crash. One of those libraries is the culprit of the crash.

[/hide]

Apparently at some point one of those function tries to access an element that is not inside the bound of the array.

Optimizations may raise transform the code wrongly and such results happen.

Taking a quick look at it, I think the library responsible for the fail is libstagefright. I think it happens when the audio stream is opened and libmediaplayerservice calls findint32 from libstagefright. So I assume it is must be one of those two. libutils and libc are core libraries and the functions that are called from them doesn't raise errors on other part of the code. Well might be libutils but the least likely libc.so

If you feel bored can do the test while doing smthing else we could find out hehe.
[Nexus 10 Original Android Development] b1g.p0ppa:
I am happy to test! I am having a little trouble understanding what you would like me to test, though. Would you like me to only bring /system/lib/libstagefright.so from the 1227 ROM to the 105 linaro ROM, or should I also bring the other two aforementioned files? While I am awaiting your response, I will bring only /system/lib/libstagefright.so from 1227 to 105 and do the test.
[Nexus 10 Original Android Development] Khaon:
Yeah the best would be test one by one to see if we can find the one making this crash.

You have to restart the device (soft or hard reboot) once deleted and pasted new file.
[Nexus 10 Original Android Development] b1g.p0ppa:
Ok I will. I have just flashed the 1227 ROM and will tar up /system so I can easily bring any file to the 105 ROM. Will flash 105 and test with only /system/lib/libstagefright.so and report back.
[Nexus 10 Original Android Development] b1g.p0ppa:
/system/lib/libstagefright.so from 1227 fails on 106. Logs attached. Will test next with /system/lib/libstagefright.so and /system/app/webview/webview.apk from 1227 added to 106.
[Nexus 10 Original Android Development] b1g.p0ppa:
Bummer. Fails with /system/lib/libstagefright.so and /system/app/webview/webview.apk in place. Logs attached. Next test with both in place plus system/lib/libwebviewchromium.so.
[Nexus 10 Original Android Development] b1g.p0ppa:
Video still fails to play with all 3 files in place. Logs attached. Late here, can pick this up tomorrow.
[Nexus 10 Original Android Development] Khaon:
You don't need to test multiple libraries at the same, however, it does not harm or will bring more issues.

Did you try all of the lib that the trace goes on?

i.e.

libutils.so

libstagefright.so

libmediaplayerservice.so

libstagefright_foundation.so

libc.so

webview is related with webchromium, I dont think it is the issue but I did say something wrong webchrom is libwechromium, libwebviewchromium_plat_support.so and libwebviewchromium_loader.so. Therefore, you will also need to copy those two. Ew

Or by tomorrow I will be able, with extra errors flags, to identify where the error comes from.

Well at least I think :p
[Nexus 10 Original Android Development] b1g.p0ppa:
I tested with system/app/webview/webview.apk and the 5 libs you listed and the video does play correctly. Again, this is the 105 cm-12-20150105-UNOFFICIAL-manta-linaro.zip ROM, theUPDATE-AnyKernel2-khaon-kernel-manta-01-05-2015.zip kernel and those 6 files from the cm-12-20141227-UNOFFICIAL-manta.zip ROM.
[Nexus 10 Original Android Development] Khaon:
Hm too bad you could not identify which library cause that. Which ones you sure are not responsible?
[Nexus 10 Original Android Development] b1g.p0ppa:
I will test one at a time and see what I can find out.
[Nexus 10 Original Android Development] Khaon:
Well at least it is not one of the two first you tried right? Chromium lib is not the culprit
[Nexus 10 Original Android Development] b1g.p0ppa:
Correct. Question: should I use system/app/webview/webview.apk from the 1227 or the 105 ROM?

---------- Post added at 12:34 PM ---------- Previous post was at 12:07 PM ----------

Found the culprit! system/lib/libmediaplayerservice.so. When I take just that file from the 1227 ROM and put it on the 105 ROM the video plays correctly.
[Nexus 10 Original Android Development] Khaon:
Good. At least for next release this bug is gone and I guess it was harming not only your application.
[Nexus 10 Original Android Development] b1g.p0ppa:
Tested with the 103 ROM and pushing only this file to it solved the problem as well.
[Nexus 10 Original Android Development] Khaon:
Art is also another forced library. All gcc 4.9 yield with sefdault. However like you said I noticed difference with art compiled with or not optimization. I mean at least when building cache at first start up. Don't know if the actual runtime brings good performance. But it is still good things to try. Especially when i compare the speed of the caching

Well now that I know the library it was written in the backtrace the origin of the function where it bugged.

Web view apk is related with Web chromium linbs
[Nexus 10 Original Android Development] b1g.p0ppa:
It's not very scientific, but Clash of Clans :p loaded much slower on the non-optimized ROM even after the initial caching.
[Nexus 10 Original Android Development] fifthelement:
Hi Khaon ,

I have Linaro ROM and kernel 3 January 2015 installed. I am experiencing very high battery drain problem. one hour of normal web browsing in google chrome drains about 40% of battery and in battery stats it is logged under Miscellaneous. currently my tablet is on 12% charge and Miscellaneous is 37% and Screen is 25% which is not normal. dont you have such an issue ?
[Nexus 10 Original Android Development] fifthelement:
Does anyone else have this miscellaneous battery drain?
[Nexus 10 Original Android Development] b1g.p0ppa:
I don't have that battery drain problem. Have you installed any apps to try to analyze it? I like gsam battery monitor.
[Nexus 10 Original Android Development] fifthelement:
Are you sure you dont have it at all ?

here is what it looks like in battery stats after using the tablet for a while :

I dont think battery monitor apps can help. If you search for cm12 miscellaneous battery drain, you will see many users have this problem on different devices.

It should be a bug with ROM or kernel. I dont have any specific app installed, just regular stuff.
[Nexus 10 Original Android Development] ericp2:
cm12 nightlies for manta

Hi Khaon,

I see that CM12 nightlies are now available. I would like to try those out, can you confirm that flashing it along with your kernel will work? i.e. that file system types will not be overwritten? I am currently running f2fs on data only, but the updater script contains:

...

if is_mounted("/data") then

package_extract_file("system/bin/otasigcheck.sh", "/tmp/otasigcheck.sh");

package_extract_file("META-INF/org/cyanogenmod/releasekey", "/tmp/releasekey");

set_metadata("/tmp/otasigcheck.sh", "uid", 0, "gid", 0, "mode", 0755);

run_program("/tmp/otasigcheck.sh") != "31744" || abort("Can't install this package on top of incompatible data. Please try another package or run a factory reset");

else

mount("ext4", "EMMC", "/dev/block/platform/dw_mmc.0/by-name/userdata", "/data", "");

package_extract_file("system/bin/otasigcheck.sh", "/tmp/otasigcheck.sh");

package_extract_file("META-INF/org/cyanogenmod/releasekey", "/tmp/releasekey");

set_metadata("/tmp/otasigcheck.sh", "uid", 0, "gid", 0, "mode", 0755);

run_program("/tmp/otasigcheck.sh") != "31744" || abort("Can't install this package on top of incompatible data. Please try another package or run a factory reset");

unmount("/data");

endif;

...

so it seems it would fail without editing the script first don't you think?
[Nexus 10 Original Android Development] Khaon:
Twrp mounts the internal storage upon booting. Since it is located in the data partition userdata is already mounted.

You can flash straight forward and then my kernel. I already did it I had a super unstable build and was not home.

Sent from my Xiaomi MI2s
[Nexus 10 Original Android Development] b1g.p0ppa:
Nope, I am not seeing this Misc category. Incidentally, how do you take a screenshot on this ROM?
[Nexus 10 Original Android Development] fifthelement:
I dont know if cm12 has built in screenshot feature, but you can always use third party apps from play store.
[Nexus 10 Original Android Development] b1g.p0ppa:
Duh why didn't I think to install a screen capture app? Now I have and attached is my graph. (Tapatalk keeps crashing trying to insert an image so sorry for the attachment)
[Nexus 10 Original Android Development] fifthelement:
I guess u have forgotten to attach your image :)
[Nexus 10 Original Android Development] b1g.p0ppa:
Lol yep, updated my post.
[Nexus 10 Original Android Development] fifthelement:
Thanks, Can you tell me the exact version of your ROM and Kernel ?
[Nexus 10 Original Android Development] b1g.p0ppa:
Yep, I'm running cm-12-20150105-UNOFFICIAL-manta-linaro.zip and UPDATE-AnyKernel2-khaon-kernel-manata-01-052015.zip. Both downloaded from Khaon's Google drive link. I'm using intellimm cpu governor except when I run Clash of Clans, then I have Tasker switch it over to intelliactive (loads a lot more faster). FIOPS for scheduler. No OC/UV.
[Nexus 10 Original Android Development] SeemannBootlegs:
Can you share Khaon's Google Drive link?
[Nexus 10 Original Android Development] b1g.p0ppa:
It's in post 478 of this thread.
[Nexus 10 Original Android Development] SeemannBootlegs:
**** i feel like a newbie... I usually read every message but with the new Tapatalk app it's very confusing to keep the conversation...
[Nexus 10 Original Android Development] Khaon:
Well I tought I had edited OP for the new download link, it was not, it is corrected now!
[Nexus 10 Original Android Development] benjmiester:
Wait, the srcipt for converting roms to F2FS isn't there anymore. Do we not need to do that anymore? (I'm still on a December 2014 build, haven't been on in a while.
[Nexus 10 Original Android Development] Khaon:
Cyanogen 12 ? If yes you don't need to do anything but flash the ROM and then my ketnel
[Nexus 10 Original Android Development] benjmiester:
Worked like a charm! Thanks. I do however get a problem with it not wanting to boot up anymore after rooting by flashing supersu 2.40. Should I use another version or different method? Or is it rooted already and I just need to install Supersu from playstore?
[Nexus 10 Original Android Development] fifthelement:
I had this problem too. So I gave up using supersu. But you may try to install the beta version of supersu and see if it works or not. It was 2.44 the last time I checked.
[Nexus 10 Original Android Development] Khaon:
CM12 comes with its own built-in SU you don't have to flash SU to have root access only if you want it ofc.
[Nexus 10 Original Android Development] benjmiester:
Ok. I did see root access in dev options. I can't get it work with selinux changer though (to change to permissive to be able to use Viper4Android). I'm guess that's not a root issue, but a kernel issue though right? I had V4A working ok on the December 2014 build. But seems something's different now. Not a huge issue though. I just like to filter out some of the bass that the speakers can't handle so they don't crackle at high volume.
[Nexus 10 Original Android Development] Khaon:
Your seli'ix state should be equal to permissive

Go check in about phone?

I have included for manta the audio libraries for viper

I am using it daily

Sent from my Xiaomi MI2s
[Nexus 10 Original Android Development] fifthelement:
I wiped system, cache and dalvik cache and reinstalled the ROM & Kenrel but I am still having miscellaneous battery drain problem. can it be because my tablet battery has become old and actually is not 9000mah anymore ?
[Nexus 10 Original Android Development] Khaon:
A software such bbs, you can thread on xda will help tracking down battery draining

Sent from my Xiaomi MI2s
[Nexus 10 Original Android Development] benjmiester:
It works. I just had to extract the flashable lolliviper.zip in file browser and install the .apk now it works. :victory: It wouldn't flash for some reason so I thought it was not permissive or no root or something. But that's all, and now it works. Thanks for all the help!
[Nexus 10 Original Android Development] fifthelement:
This battery drain is different. bbs or similar apps can not detect it. it is not a wakelock issue. miscellaneous battery drain is the difference between the power that Android expects to be used and the power that actually is used. It is like some hardware chip is taking too much power to operate.

if you click on this link :

https://www.google.com/webhp?source...2&ie=UTF-8#q=cm12+miscellaneous+battery+drain

you will see many users have this problem on cm12 on different devices. some rom devs claim they have fixed it.

I asked but seems I am the only one who has this problem on your ROM so I guess there is something wrong with my tablet.
[Nexus 10 Original Android Development] michaelearth:
I installed this rom/kernel on my N10 about a week ago and within the past several days I have noticed a bug where whenever I hit the recents button the system UI crashes. I tried switching launchers, turning off any overclocks, wiping cache and fixing permissions but have zero luck. Any ideas what the culprit may be or should I just do a fresh install of the rom?

Thanks!
[Nexus 10 Original Android Development] fifthelement:
Did you do a full wipe (system, data, cache, dalvik cache) before installing the ROM ? It seems like a dirty flash problem. I recommend you to do a fresh install with a full wipe.
[Nexus 10 Original Android Development] Khaon:
Hello little update to the kernel:

introduced 864 Mhz cache frequencies for 1.6+++ freq.

merged with google's androidd 3.4 branch: squashed the following commits:

Merge remote-tracking branch 'common/android-3.4' into lollipop

ARM: pull in <asm/simd.h> from asm-generic

ARM: be strict about FP exceptions in kernel mode

ARM: move VFP init to an earlier boot stage

crypto: create generic version of ablk_helper

ARM: add support for kernel mode NEON

crypto: sha - Handle unaligned input data in generic sha256 and sha512.

crypto: sha512_generic - set cra_driver_name

crypto: sha512 - Expose generic sha512 routine to be callable from other modules

crypto: create generic version of ablk_helper

defconfig updated:enabled arm crypto

KEYS: Provide signature verification with an asymmetric key

KEYS: Asymmetric public-key algorithm crypto key subtype

KEYS: Implement asymmetric key type

crypto: add crypto_[un]register_shashes for [un]registering multiple shash entries at once

ARM: 8120/1: crypto: sha512: add ARM NEON implementation

ARM: 8119/1: crypto: sha1: add ARM NEON implementation

ARM: 8118/1: crypto: sha1/make use of common SHA-1 structures

crypto: arm-aes - fix encryption of unaligned data

CRYPTO: Fix more AES build errors

ARM: add .gitignore entry for aesbs-core.S

ARM: add support for bit sliced AES using NEON instructions

ARM: move AES typedefs and function prototypes to separate header

ARM: 7837/3: fix Thumb-2 bug in AES assembler code

ARM: 7723/1: crypto: sha1-armv4-large.S: fix SP handling

ARM: 7626/1: arm/crypto: Make asm SHA-1 and AES code Thumb-2 compatible

arm/crypto: Add optimized AES and SHA1 routines

sync with f2fs upstream branch

squashed few commits from CAF:

mm: vmscan: lock page on swap error in pageout

Staging: android: binder: More offset validation

Input: Send events one packet at a time

binder: NULL pointer reference

staging: binder: add vm_fault handler

staging: binder: Change binder mutex to rtmutex.

report if instablity!
[Nexus 10 Original Android Development] Malnilion:
1/20 seems to be working pretty well so far on official cm nightly.
[Nexus 10 Original Android Development] Bastlwastl2010:
Same here
[Nexus 10 Original Android Development] Lamba92:
Twitch.tv app and similar seems broken :( Probably somethimg related to HW+ acceleration! You can reproduce the issue just by trying to watch a stream from Twitch with any app available on the store!

With the official CM12 does not happen, same on any 4.4.4
[Nexus 10 Original Android Development] Khaon:
hello that was an issue that been fixed normally, plex was bugging.

Last update on drive should be working IF NOT can you provide me the following

adb logcat -v time -d > logcat.log
[Nexus 10 Original Android Development] Lamba92:
I'll try

EDIT: I've dirty flashed the new kernel... Still nothing! Here the logcat!
[Nexus 10 Original Android Development] brees75:
Any chance we could get a GPU overclock option for 620 MHz? Maybe even an option to disable Fsync? :D
[Nexus 10 Original Android Development] Khaon:
Thanks at least for the log, but your problem comes from the rom itself not the kernel
[Nexus 10 Original Android Development] Khaon:
I can oc gpu up to 720 like ktoonsez did.

Why do you want fsync disable? :P
[Nexus 10 Original Android Development] leninke:
How do you do that? :)
[Nexus 10 Original Android Development] Khaon:
Why do you want that :D? there is a sys fs entry, look on google you ll find easily
[Nexus 10 Original Android Development] leninke:
I meant, how you do you oc the GPU?
[Nexus 10 Original Android Development] Khaon:
Ahhahha my bad just get up still sleepy :D/D

Take a look there for fsync .

You can oc gpu yet I didnt implement that. You guys are playing what on tablet that requires a oc gpu?(I will add it just curious :D)
[Nexus 10 Original Android Development] leninke:
:) no problem. I have been using ktoonsez's kernel with GPU oc CPU uc. So stays the tablet fast and cool. Btw I never play games on my tablet.
[Nexus 10 Original Android Development] Lamba92:
Can i flash the kernel on officiale nightlies?
[Nexus 10 Original Android Development] Khaon:
Ofc!

Did you try the latest build? In fact I know the culprit and I think I removed the fix when compiling lol.

Next build will be repaired for good, but you can stick with nightlies ofc :)
[Nexus 10 Original Android Development] tavocabe:
GTA San Andreas. It performs better on my N10 than on my N5 lol
[Nexus 10 Original Android Development] Khaon:
I have uploaded latest twrp available with f2fs support.
[Nexus 10 Original Android Development] Khaon:
I have also added resize2fs binary to resize your partitions and get the full space from system partition

From recovery issue the following commands.

efsck -fy /dev/block/platform/dw_mmc.0/by-name/system
resize2fs /dev/block/platform/dw_mmc.0/by-name/system
efsck -fy /dev/block/platform/dw_mmc.0/by-name/system

will be included in next releases.
[Nexus 10 Original Android Development] Malnilion:
I would caution folks against altering your partition layouts unless you're sure you need to do so. Imho, there's not really a good reason to make the /system partition larger and it's already about as small as it can get without causing more problems.
[Nexus 10 Original Android Development] Khaon:
It doesnt touch to your partition table like parted can. It just recover the gap between the size of system image and your actual total system space.

Sent from my nexus 10
[Nexus 10 Original Android Development] brees75:
It improves performance, always used it on all my devices.

Add this to an init.d script:

echo off > /sys/devices/platform/mali.0/dvfs
echo 620 > /sys/devices/platform/mali.0/dvfs_under_lock
echo 620 > /sys/devices/platform/mali.0/dvfs_upper_lock

Will only work if kernel supports it, this overclocks to 620 MHz.
[Nexus 10 Original Android Development] leninke:
Thanks mate :)
[Nexus 10 Original Android Development] dannyzen:
Would it be possible to post build steps for CM12 along with your modifications?
[Nexus 10 Original Android Development] Khaon:
eww sorry??

There is not oc regarding the gpu, I really will include that as sooon I can, kinda busy lately.
[Nexus 10 Original Android Development] drewski_1:
Is the Kernel only compatible with CM12 / CAF based ROM's?
[Nexus 10 Original Android Development] leninke:
No, I use it with Purity, without problems.
[Nexus 10 Original Android Development] drewski_1:
Will give this a try on Rasta-pop tonight :good:

Purity has a 5.0 release? Not seeing it.

Sent from my LG-VS985
[Nexus 10 Original Android Development] drewski_1:
Installed fine with /cache & /data f2fs

Can't get USB OTG to work with Stickmount, though Stickmount is getting Root fine?

Sent from my Nexus 9
[Nexus 10 Original Android Development] leninke:
You have to look on G+. https://plus.google.com/u/0/communities/105581179951601265485
[Nexus 10 Original Android Development] drewski_1:
thanks! :victory:
[Nexus 10 Original Android Development] drewski_1:
One thing I didn't see mentioned (maybe my poor search skills) is that you can restore your /data partition from Nandroid to your new F2FS /data, even if was originally Ext4

This makes the change-over to F2FS pretty quick and painless as you don't have to re-install all your apps & settings.

TWRP backup /data and manually backup /data/media (the part not included in the Nandroid)

reformat /cache & /data to F2FS

flash Kernel

restore /data & /data/media

reboot

profit
[Nexus 10 Original Android Development] OmniSlyfer:
Is there a way to disable dynamic fsync by myself without using an app? Maybe editing files under sys/kernel/... I tried to search on internet but there is no fsync file under sys/kernel :|
[Nexus 10 Original Android Development] Khaon:
Sorry for late reply I was kinda of busy lately.

There is no dynamic fscync in my kernels. However f2fs with its option discard enables a real time trim.

I have no idea if you have to edit the fstab or can through a f2fs entry disable that. zwill need to look over on the Internet.

Just curious why do you want it off
[Nexus 10 Original Android Development] OmniSlyfer:
Well, you've posted 2 pages ago a link to an article that explain what dynamic fsync is, and what are the advantages of disable it... I quote the last sentence of this article "So in summary - as long as the system is stable, disabling fsync only increases performance. By the way, app crashes (FC, ANR, ...) do not hurt here, only complete system crashes are bad.".

So that's why I want to disable it. Performance improvements. Our N10 is getting older and android lollipop is not light as kitkat, so I want to try to get the best performance possible. I know that the improvements will be minimal, but at least it's something.

However I'm not using f2fs, so I should not worry about that, right?
[Nexus 10 Original Android Development] Khaon:
Hello. Indeed you should not. But if you want to optimize a lot you can increase vm settings of dirty ratio and dirty ratio write back.

You can put them around 80% of the ram! With that you will have best performance. Hm if you need more explanation tell me. You can find easily o'the the Internet what those options do.

Sent from my xiaomi MI 2
[Nexus 10 Original Android Development] coalee:
Hi

I have been try many times but at the end I only be able to convert data and cache partition to f2fs. The system partition will never work for me. the convert process went OK with system partition (same as other partitions) but when I flash ROM then TWRP got closed and start into TWRP menu again (in 1-2 second, it not re-boot but just close and back to main menu). I test it with CM12 , Rastapop, OmniROM. They all have the same problem. However, if I format system partition to ext4 then I can install ROM without problem. Any comment would be appreciated.

Cheers