yashsingh1/xdaforums huggingface dataset:
[Nexus 7 Original Development] Ziyan:
Did you try disabling everything non-critical (ie. camera and sensor drivers, touchscreen) yet? Can your force reboot before the twrp screen disappears, but after the hang happens to get a last_kmsg (ie. with some key combinations)? Do you have UART equipment to make debugging a lot easier (by redirecting console to it)?

Other than that, I'd suggest a careful bringup from scratch - the first commit would be the import of the unmodified board files from 3.1, then a dozen commits updating them for 3.4, like done on grouper.

-----------------------

About grouper: we have good news. The charging issue seems to be fixed with this commit, so after some additional testing, if we observe no problems, we will release a new build which has (every?) remaining issue sorted out :) time to finish this kernel, now that at least I'm done with my finals, and the summer break begins, I have time to actually work on this again ;)

I also figured out UART - it seems like nobody got an output on grouper yet. I'll try to write a guide about it once my equipment is polished (I had to do some hardware hacks, because regular 3.3v interfaces won't communicate with grouper at all).
[Nexus 7 Original Development] PJBrs:
This is actually what I tried, see dmesg in previous post. See here for the commit, which uses a value in milliseconds and then panics. I tried the biggest value that resulted in a reboot, and then noticed a few commands related to sdhci in the queue. So I searched your gitlog for sdhci and then adopted this patch, which fixed the problem (set the vmmc regulator voltage to a certain value). The approach I took myself is a little bit different, but the same in terms of effects, with less error messages, see here - I changed the regulator value in board-kai-power.c (A2109 uses max77663, just like grouper).

And one fix later I successfully booted both cwm and twrp, but android itself (lollipop, in my case) resulted in a panic at boot after the oom killer wasn't able to kill anymore processes....?!?!?!?!? Dmesg attached, hope you came across this and fixed it already. (Not that this has anything to do with grouper, but they're both tegra3, and somebody else might benefit.)

No, actually, I understand very little of what UART is, let alone pass the console to the serial port. But my panic function comes in quite handy as well, so for now I think I'm fine.

Thanks for the advice. That's actually about what I did, after reading this thread in its entirety. But, compared to you, I had the additional advantage that my board files are modified stock nvidia board files, so I basically tried to pull all relevant changes that nvidia made to them, right from the commit that was base for the A2109 kernel, to l4t-16.5, to 3.4.

Anyway, thanks a lot! And if you have it, dmesg would still be useful :)
[Nexus 7 Original Development] PJBrs:
[MENTION=2633638]Ziyan[/MENTION],

What did you do about these files?

￼

/sys/firmware/fuse/odm_production_mode
/sys/module/fuse/parameters/tegra_chip_id
/sys/module/fuse/parameters/tegra_chip_rev

Under 3.4, there's no /sys/firmware/fuse/ anymore, and the other two fuse directories are renamed tegra_fuse. I've tried today to change names in sysfs, and it's a lot harder than I expected...

*EDIT*

To answer my own question - there's multiple ways around it. In the kernel, there must be a way to add some links in sysfs. Then there's the option to change the file paths in the Nvidia blobs where applicable, and change them into paths that I can add in my android build. The easiest way out, though, is to revert all changes to fuse before it was changed in a platform driver, and then rename arch/arm/mach-tegra/tegra_fuse.c to arch/arm/mach-tegra/fuse.c, and change arch/arm/mach-tegra/Makefile accordingly. Definitely sloppy, but I did finally manage to do a complete lollipop boot with 3.4 on Lenovo A2019!!

*EDIT 2*

Just to let you know the results, after some quick testing:

Often kernel panic on adb

Vibrator doesn't seem to work

Many graphics glitches in gui (but very high Antutu 3d score)

THE REST APPEARS TO WORK!!!!

Alright - I'll stop spamming this thread now. Like I said, you guys have been an inspiration, thanks again! I hope that other tegra3 devs will join us.
[Nexus 7 Original Development] DevUt:
Should we make a separate thread and invite all the tegra3 devs ?
[Nexus 7 Original Development] Ziyan:
Did you try replacing libnvrm.so with the one in the downloads section from this thread? That should eliminate the graphics glitches you're seeing, and you could revert all fuse trickery :) I also made some hex-edits, but mainly just for proper MM support, I'm sure you already found them ;)
[Nexus 7 Original Development] Ziyan:
Alright, new build up for grouper with all the bugs we could find fixed. That includes the audio, rotation and charging problems experienced on the previous build. Going back to older kernels, charging should work fine with this build - same if you accidentally discharge the device to 0%, you can charge it just fine using a strong enough charger (charging from a computer in that case might not work, as it provides less current than the device needs to boot up without any battery power).

Report back about *any* issue found - and be sure to wipe before trying out this build!

EDIT: It's important that /system needs to be unmounted before installing the ROM - some recoveries tend to leave it mounted after performing operations on it. Refer to this post for GApps and root.
[Nexus 7 Original Development] mn.code:
[MENTION=2633638]Ziyan[/MENTION]

Looks like OTG is not working. lsusb sees some device, but the external device is not being powered on.

Other than that, everything is working great. You can see the performance boost. Great job guys!

EDIT: also, network location is not working.
[Nexus 7 Original Development] Ziyan:
Sounds like a charging driver issue (we need to tell it to start outputting power).

Ah, classic AOSP bug - we need to add https://github.com/OMAP4-AOSP/android_device_samsung_tuna/commit/3c8a050af2704838d2dcb47470dd92250a2d6d1a to the build :)
[Nexus 7 Original Development] mn.code:
Remember this one (commit) from the first time Lollipop came to Maguro :)
[Nexus 7 Original Development] chall32:
Everything working great here. Excellent job guys :good:
[Nexus 7 Original Development] sheffzor:
tilapia is up too, otg power issue still remains, we will need to do more tests...
[Nexus 7 Original Development] um.z:
I've got one of those covers with a magnet, and it looks like the magnetic screen on/off is not working in your latest release. Don't know whether that's a rom or a kernel issue. Otherwise all working fine. Brilliant job!

EDIT: Annoyingly, though, I keep getting 'Play Services has stopped' dialogues. Using the latest ARM opengapps Pico. Anyone got an idea?
[Nexus 7 Original Development] mn.code:
Go to Settings-> Applications-> Google Play Services, click on Permissions and grant every permission you see in there.
[Nexus 7 Original Development] um.z:
Thanks, that seems to have solved it. Having solved that, the only app related issue still remaining seems to be Firefox forcing the tablet to reboot every time I try to open it.
[Nexus 7 Original Development] um.z:
Update: It looks as if my grouper has switched itself on. I powered it off last night, but heard a notification sound this morning as I received an email.
[Nexus 7 Original Development] gorneman:
Hi,

first of all, thanks to [MENTION=4619263]sheffzor[/MENTION] and [MENTION=2633638]Ziyan[/MENTION] for being our preferred Dr.Frankestein (They bring new life to an almost dead device).

I try to install the rom following the steps:

1 Wipe data (all partitions are ext4)

2 flash rom

3 flash open gapps

4 flash supesu

but at reboot I can only see a black screen.

In proc there is not a last_kmsg to extract.

Are they right? Thanks again

Same problem as [MENTION=3828752]biondi53[/MENTION]
[Nexus 7 Original Development] PJBrs:
[MENTION=2633638]Ziyan[/MENTION], thanks for the suggestion. The fuse trickery, unfortunately, is not limited to libnvrm.so, in the case of our old blobs. The biggest issue I still have is that I have massive screen flickering and tearing with the A2109 blobs. I also tried the newest grouper blobs, which appears to work, apart from the camera (even though I did a binary hack for the camera that worked on 3.1 with the new blobs), and I still seem to have a lot of lag in the ui. But no flickering and tearing.

Where did you get that libnvrm.so? I'm very surprised that I can use it as a drop-in replacement without seeming to break anything...
[Nexus 7 Original Development] mn.code:
[MENTION=2633638]Ziyan[/MENTION] [MENTION=4619263]sheffzor[/MENTION] even after reverting from 3.4 to 3.1 USB is not powering out on OTG, removing the battery and cleaning power registers solves the issue.
[Nexus 7 Original Development] Ziyan:
You've got to be fu***ing kidding me. Again!? I hate SMB347 (our charging IC) and it's drivers!

Anyways, please help us out by posting the following, so we don't have to go through the hassle to reset our SMB347 :) you might need root right to do so.

Post the output of the following (should be several lines long, detailing the register settings of SMB347; hope I got the path right, as it's entirely different on 3.4):

cat /sys/devices/platform/tegra-i2c.4/i2c-4/4-006a/reg_status

Four times:

1.) After powering on the device without anything connected to the microusb port

2.) attaching an OTG device after 1.) (while it's powered on)

3.) after disconnecting the OTG device

4.) after connecting a charger (usb or wall; but write down which)
[Nexus 7 Original Development] PJBrs:
[MENTION=2633638]Ziyan[/MENTION], the strangest thing is - if I use old blobs, I get flickering like crazy. But if I then open a shell, find the pid of surfaceflinger, and do:

strace -p {pid of surfaceflinger}

then everything is fine?!?! Any ideas or suggestions?

By the way, I can open a separate tegra3 kernel 3.4 thread if you mind these messages here, just let me know...
[Nexus 7 Original Development] Ziyan:
It's kinda hard to suggest anything without seeing the artifacts and/or flickering you got, but here are two things that might be relevant, as it sounds like your problem is related to under-scheduling something:

1. [GROUPER] video: tegra: dc: request higher bandwidth

2. ensure that CONFIG_SCHED_MC is enabled

3. temporarily disable cpuquiet + set the cpu gov to performance to see if it goes away

I don't mind your messages here :)
[Nexus 7 Original Development] mn.code:
Sure, I can help, do you want me to do it on working 3.1 or the locked one (before reseting registers)?
[Nexus 7 Original Development] Ziyan:
On working 3.1, of course :)
[Nexus 7 Original Development] mn.code:
Here you go. It's from stock Lollipop 5.1.1 with Bricked kernel from Kali NetHunter.

1. Booted the device without any micro USB, took the log

2. Connected OTG took the log

3. Disconnected OTG took the log

4.1 Connected wall charger took the log

4.2 Connected USB took the log

All done on same boot in this order. Let me know if I can help with anything else.
[Nexus 7 Original Development] IceFe:
I flash this on cm12.1?
[Nexus 7 Original Development] n1kolaa:
Its rom with kernel :)
[Nexus 7 Original Development] KawaiiAurora:
If you want USB OTG, don't flash it.. It still doesn't work after installing the 3.1 kernel. You need to disconnect the battery to get it back.
[Nexus 7 Original Development] Ziyan:
Good news: USB OTG is fixed :) thanks to the logs by [MENTION=4263181]mn.code[/MENTION]. It will stay working after rebooting to 3.1 (for example: TWRP) as well.

At this point, we just need to investigate the other reported bug (big apps crashing the system) before moving this out of the alpha/beta stages ;)
[Nexus 7 Original Development] Reptilez_DK:
Awesome work you guys ! Your dedication is truly appreciated. :good:
[Nexus 7 Original Development] abhifx:
+1

this bringup is already at so advance stage that it is unbelievable.

Thanks [MENTION=2633638]Ziyan[/MENTION]
[Nexus 7 Original Development] Electry:
I see you guys did some truly remarkable work over the months and I can't believe that this has gotten to the stage where it's working (almost) flawlessly on our grouper.

EDIT:

I've noticed some anomalies going on:

- To turn on bluetooth I have to tap on the quick settings toggle twice, after first time it won't turn on, but there is some bt related activity (in logcat). I wish I had the skills to figure out what's going on.

I believe that after first tap bt goes into ble mode and after second it turns on completely.

- Also sometimes when the screen turns on by itself (usually when unplugging from usb) I get minor lags and framedrops until I lock/unlock my device again. (mostly visible when moving through home screen or pulling notification bar). Again, I have no idea what is causing that.

Am I the only one experiencing those issues?

I've built it by myself along with cyanogenmod 13 using grouper-aosp repos with no major modifications.

I am able to provide dmesg/logcat if it would help sb.
[Nexus 7 Original Development] abhifx:
if you can post the compiled kernel i (and maybe others) can test and revert too.
[Nexus 7 Original Development] sheffzor:
Heyz!

Some fresh builds are ready to be tested @ Downloads Section :victory::victory:

This last month we took some days to rest but we still had some time to fix a bunch of things you guys reported, we have done good improvements to some kernel drivers and some new features have been made available in the rom itself, like f2fs and wifi/usb/bt/3g(tilapia only) tethering.

We are entering in a beta stage since we have all the hardware working on grouper and tilapia, now it's time for fine tunning to achieve the very best of this old tab.

We will be waiting for your feedback!
[Nexus 7 Original Development] Dreamer...:
WOW, cool!

but where i can find compiled boot.img for flashing? :o
[Nexus 7 Original Development] sheffzor:
it seems that you are not inside of what is been doing here, simply there will never exist a boot.img to flash, this kind of development implies changing drivers, hals and ramdisk, so we bypass that kind of confusion so people don't need to bother with replacing those hals again if they want to jump between roms/kernels, we just release a full build, everything that is needed is there.
[Nexus 7 Original Development] abhifx:
Downloading.. i am surprised no one has downloaded it yet.

Also my tab is away.. will test this friday. Good work guys. AOSP is good enough, lets see if the work spread to other ROMS and Nougat.

Also.. isnt this news worthy? lets vote for main XDA page news
[Nexus 7 Original Development] KawaiiAurora:
Works quite well on my Nexus 7 but A1 sd benchmark hangs the system :/ Also, Android animations feel a bit sluggish even with animation scale 0.5x. The rest of the system works pretty well

EDIT: More minor issues. USB OTG works but pendrives don't work in ES or Zen File Explorer (ASUS). They're just mounted as a file that you can't open. You can however explore them by opening settings. Also, I can't charge a mini bluetooth headphone adapter that I could charge on 3.1
[Nexus 7 Original Development] Oblivionevil:
Not booting =(
[Nexus 7 Original Development] AndDiSa:
[SARCASM_ON] What a helpful comment for the developers. Now they are able to fix all the issues you have in using it. [SARCASM_OFF]
[Nexus 7 Original Development] abhifx:
This has booted fine. Its a bit laggy but kernel wise everything seems to work. Substratum works great but that kind of like makes it more laggy. Good work guys.... Can't wait for optimization and newer build. This is going to fly :D
[Nexus 7 Original Development] sheffzor:
cm-13.0 build

Those animation problems must have been introduced by the nvidia power hal that we are using now, we are working to adjust everything... tanks for report. :)

Something went wrong during the flash, if you're sure you flashed correct, would be nice to have a /proc/last_kmsg to check whats wrong, does it pass the Google logo? Does it bootloop on "Android" logo?

As I said in answer to [MENTION=6789723]KawaiiAurora[/MENTION], we are fine adjusting things, while we do it...

...here we have some more juice to you guys to test, CM-13.0:

cm-13.0-20160820-UNOFFICIAL-grouper.zip

cm-13.0-20160820-UNOFFICIAL-tilapia.zip

(ps: Don't use LiveDisplay in night mode, it will slow down the UI animations)
[Nexus 7 Original Development] Reptilez_DK:
This is the juice I've been waiting for ! :victory:
[Nexus 7 Original Development] abhifx:
Much better and smoother. This is good... Except of sleep of death... Twice. Had to long press the power button to restart the tablet. Though its going in right direction
[Nexus 7 Original Development] Reptilez_DK:
Any logs ? :)
[Nexus 7 Original Development] KawaiiAurora:
Awesome! I'll test the CM13 build and see how it likes my device. Just a side note, please host the zips elsewhere because direct downloading from XDA takes ages (100KB/s) :/

Thanks for all the hard work!
[Nexus 7 Original Development] abhifx:
oops.. i have flashed another ROM but will post logs tomorrow if i can flash the ROM again.

also the sleep of death is kind of random... maybe it fails to wake up after deep sleep. normal shut and wake up was just fine.

also note that 3.1.x kernel roms are super slow and laggy compared to this CM build. if this deep sleep death is fixed we have a daily driver here.

---------- Post added at 09:57 PM ---------- Previous post was at 09:55 PM ----------

also as an addendum... can anyone build AICP or RR out of this? would like to try a mega rom with this. thanks in advance.
[Nexus 7 Original Development] sheffzor:
We will only support aosp, cm and omni.

About, SOD should be fixed next builds.

Enviado do meu A0001 através de Tapatalk
[Nexus 7 Original Development] KawaiiAurora:
Awesome! I'll test the CM13 build and see how it likes my device. Just a side note, please host the zips elsewhere because direct downloading from XDA takes ages (100KB/s) :/

Thanks for all the hard work!

Double Post- srry :/ Delete please..
[Nexus 7 Original Development] C--Mon:
Sadly non of the builds is working for me here on my grouper device. :(

Neither the aosp build nor the CM or Omni Build.

The device powers up and then stucks on boot logo for hours and nothing happens. Made a clean install over latest TWRP without using gapps.

Realy wish to provide you with more helpfull infos, but since the roms don't boot for me I can't authorize adb for a Log :-/
[Nexus 7 Original Development] sheffzor:
You can provide us a /proc/last_kmsg

Just try to boot, then force reset on power btn, go into recovery and issue a cat /proc/last_kmsg in adb

Post here the results.

We thought that we have solved all the problems on all grouper board variants, maybe yours have something different.

Enviado do meu A0001 através de Tapatalk
[Nexus 7 Original Development] C--Mon:
Thanks for your advice.

Didn't know that I can make a kernel log in recovery.

But you never stop learning :)

Ok, here is the log: http://pastebin.com/FbgWgMmB

Strange Thing.

In the log it says, that my device tries to start Linux version 3.1.10-00127-g100eed4 (thoemy@thoemy) and not 3.4.xxx.

Or ist that normal?

Log is from the CM Version.

If I can help you any further in any way, just let me know!
[Nexus 7 Original Development] sheffzor:
Kernel doesn't even boot, are you on the latest bootloader? 4.23

BTW, in fastboot mode, in the screen, there's a parameter hardware revision, can you check it?

Enviado do meu A0001 através de Tapatalk
[Nexus 7 Original Development] C--Mon:
Shure, here a the parameters from fastboot mode (Skipped the serial nr):

Product Name - grouper

Variant - grouper

HW Version - ER3

Bootloader Version - 4.23

Baseband Version - N/A

Serial Number - xxx

Signing - not defined yet
[Nexus 7 Original Development] sheffzor:
We don't have issues with that he revision.

I would suggest the following:

- Using the latest twrp

- Wipe system

- Wipe data

- Flash ROM

If this doesn't work

Extract the boot.img from the zip and fastboot flash boot boot.img after flash the rom

Enviado do meu A0001 através de Tapatalk
[Nexus 7 Original Development] Oblivionevil:
CM 13 doesnt boot only the CM startscreen

last_kmsg is from the last working rom kernel 3.1 (Download lastkmsg) dont write a new last_kmsg file

Product Name - grouper

Variant - grouper

HW Version - ER3

Bootloader Version - 4.23

Baseband Version - N/A

Serial Number - xxx

Signing - not defined yet

lock state unlockef

Nexus 2012 32gb
[Nexus 7 Original Development] sheffzor:
So you both arent't on Google logo but in CM bootlogo in bootloop, is that?
[Nexus 7 Original Development] Oblivionevil:
Yes
[Nexus 7 Original Development] n1kolaa:
you need gapps
[Nexus 7 Original Development] KawaiiAurora:
The unofficial CM 13 works pretty well, animations are pretty smooth and the system is pretty stable. I still have issues with USB OTG though, the mini Bluetooth headphone receiver that charged on kernel 3.1 via USB doesn't charge on 3.4; and my pendrive (that worked on 3.1,) doesn't work on 3.4 :/

What I get: (I'll happily provide logs)

[img=http://www87.zippyshare.com/thumb/5ICPFh3q/file.html][/img]

[img=http://www87.zippyshare.com/thumb/fbMlT2DY/file.html][/img]
[Nexus 7 Original Development] sheffzor:
Well, about the charging, we built it in way that it doesn't work unless something is detected by data bus.

We will check the OTG standards, if OTG should supply power without data bus connected, we will change it in that way.

Enviado do meu A0001 através de Tapatalk
[Nexus 7 Original Development] erk1725:
You guys are amazing and I thank you very much for all your hard work and effort and countless hours spent on this project! I would like to give this a go on my grouper and just wanted to clarify that the ROM and kernel needed are in the download tab? I will grab the recovery also, but I wanted to try aosp ROM and kernel.....just have to locate gapps. Im just having some trouble understanding the file names.

Thank you all very much

Edit: so I see it is ROM and kernel...so I will grab the recovery, check bootloader version and get some gapps......thank you all again, very much!
[Nexus 7 Original Development] C--Mon:
The gapps makes no difference.

Tried it right now, but still doesn't boot.

Also made a complete wipe and flashed boot.img manually via fastboot.

But also still doesn't boot :(
[Nexus 7 Original Development] n1kolaa:
Flash procedure: update twrp if not last version

Download cm/omni/aosp rom

Download gapps pico

Place both in phone memory

Go to twrp

Wipe data all expet external memory.

flash rom then gapps

Reboot afer flash and you are done
[Nexus 7 Original Development] C--Mon:
I followed the instructions from the first page step by step.

Your instructions are absolutely the same.

Makes no difference

But thank you anyway :)
[Nexus 7 Original Development] sheffzor:
WTF?

Enviado do meu A0001 através de Tapatalk
[Nexus 7 Original Development] abhifx:
turns out not only kernel, lots of other things have changed too (hal, blobs etc) thus the developers are providing complete ROM. you just cant flash any other ROM and flash this kernel over. that's what i understand as of now.

Also good thing is CM and omni are now part of beta testing ROMs.
[Nexus 7 Original Development] chosin137:
Parrot Mod

This working with Parrot Mod?
[Nexus 7 Original Development] NeoPreacher:
Yes. I'm using it with omni 3.4 (sadly disappeared from DL section).
[Nexus 7 Original Development] chosin137:
Hmmm is there a difference between 3.1 and 3.4 that you can notice?
[Nexus 7 Original Development] NeoPreacher:
I guess it needs a few more days to answer this question. It's running well so far.
[Nexus 7 Original Development] abhifx:
and it seems we have new updates with CM13 and TWRP with 3.4 kernel. fingers crossed for sleep of death fixes.