yashsingh1/xdaforums huggingface dataset:
[Sony Ericsson Xperia Mini, Mini Pro, Xperia Pro, A] CTCaer:
Yeah of course.

Second log is normal. Nothing irregular or info about reboot.

If your CPU can't take the low voltages, when it reboots last_kmsg shows nothing. But a new one, called last_amsslog, is created.

This is created when the ARM9 (co-processor) crashes. When it's of low voltage, last_kmsg shows nothing, as I said.

Otherwise there's a small log about ARM9 inside kmsg too.

My self, I'm using the adreno jb drivers. Taken from a RAY thread (it had 3 options if I remember. Only the 2 were the full drivers).

But still I don't think that the 2nd log is about adreno. Probably low voltage. If these are often happening, try the 1.6 version.

It defaults to 1ghz and has stock voltages as default.
[Sony Ericsson Xperia Mini, Mini Pro, Xperia Pro, A] suaksoz:
I've done what you had asked. But the terminal output is still same ("insmod: can't open...") except "couldn't find..." line. :( I had done something in Lupus Menu in Lupus Kernel before trying yours (2.7). Maybe it coused that.

I am going to try JB.
[Sony Ericsson Xperia Mini, Mini Pro, Xperia Pro, A] Intuki:
Oh, I'll try 1.6:o

Strange thing that I never got reboots with vds kernels
[Sony Ericsson Xperia Mini, Mini Pro, Xperia Pro, A] frogerra:
It 2.7 supported frandom? Install CrossBreeder and doesnt work.

It's X-Ray with Tapatalk!
[Sony Ericsson Xperia Mini, Mini Pro, Xperia Pro, A] templeka:
It's written in op, kernel/memory optimizations.
[Sony Ericsson Xperia Mini, Mini Pro, Xperia Pro, A] CTCaer:
If you downloaded and used the script I provided:

Try editing the script and change the 1st line: from #!/sbin/sh to #!/system/bin/sh or /system/xbin

Also for some reason it doesn't parse the files correctly. That's why you see the not found errors. it eats the letters from the files. Like 'ac80211.ko, it should be mac80211.ko. Anywway my kernel needs the stock wifi modules. If with lupus kernel the wifi is working, that means that you flashed his custom wifi modules. You have to flash the stock ones from .587 or .13 fw.

I have lower voltages in lower frequencies, than vds kernel.

Btw v2.6

Frandom is built-in. It's already enabled. No need for using crossbreeder's frandom option.

You can see that /dev/random points to /dev/frandom and /dev/urandom points to /dev/erandom.

To sum it up, don't use

3. Modulate OS entropy levels for lag reduction ala Seeder.

4. Remove /dev/random as it's blocking .

5. Frandom support

of crossbreeder's options.

The linking of frandom at my kernel, is done at boot. That means that NOTHING can use original random and urandom.

So this renders these 3, as not needed.
[Sony Ericsson Xperia Mini, Mini Pro, Xperia Pro, A] Intuki:
Extreme UV causes some errors at CPU calculations and it needs to spend more battery life on fixing errors, doesn't it?
[Sony Ericsson Xperia Mini, Mini Pro, Xperia Pro, A] CTCaer:
Yep indeed. But lowering, for example 122mhz from 900mV to 750mV is not extreme. Even between 384 and 6XXmhz the stock are 900mV.

And as of 2.6 the voltages were stabilized for that reason also.

For a cost of an extra 3.8mW (it's like you lose 3 minutes from a 100%->0% time, playing a game at 1.4GHz), it hasn't that problem.

Also another reason these are further stabilized, is that when I measured the mW I was using my RAY which can't stand 1.6GHz even with 1400mV and also some frequencies is problematic for me.

Still there are SoCs that can't handle it. It's not 100%, that yours can't. But it's the biggest possibility, provided that your ARM9 crashed and nothing showed in kmsg.

That's why 1.6GHz+VDD version exists also.

I have to admit though, that I have to thank you for reading my posts carefully. That rung a happy bell here :)
[Sony Ericsson Xperia Mini, Mini Pro, Xperia Pro, A] vleutmans:
hmm i noticed that my wifi doesn't work anymore 'on stock 4.1.b.1.13 +cwm kernel', which is not fixed by wiping cache and dalvik cache...strange isn't it ?

I flashed LUPUS (without WIFI modules) before, and also CTCAER 2.7 some time ago, so WIFI modules are not touched I would expect.

Did LUPUS mess up something here, even without touching the WIFI modules?

Now WIFI luckily is working with xray kernel, C edition. Maybe this is useful information ? If not, then disregard this message ;)

Br.

Michel
[Sony Ericsson Xperia Mini, Mini Pro, Xperia Pro, A] CTCaer:
Yep that helps a lot.

Just checked and in latest versions, wedgess used advanced scripting to unify the kernel for gb/ics/cm, he incorporated a script which does this:

Check sdk number (ics or gb) or check if it's cm9. Then he copies the wifi modules needed to system.

So in the end you 2 because you flashed Lupus Kernel you have custom wifi modules.

Just flash the stock ones.

I repeat, Lupus kernel copies it's wifi modules on it's own.

So for all ppl just find a reliable update zip with the stock wifi modules (.587 or .13) and always have it somewhere in you sdcard when testing or changing kernels.

CTCaer Kernel uses stock WiFi modules

I always test both versions for working wifi and other things. So if your wifi is not working, something is wrong with your modules.

Still there are times that strange things, can happen. This ain't the case here though. :)
[Sony Ericsson Xperia Mini, Mini Pro, Xperia Pro, A] vleutmans:
This is what lupus does with the wifi drivers, it makes a logical link to other location.

127|root@android:/system/lib/modules/drivers/net/wireless/wl12xx # ls -l

ls -l

lrwxrwxrwx 1 root root 51 May 8 21:58 wl12xx.ko -> /res/ICSwifi3/drivers/net/wireless/wl12xx/wl12xx.ko

lrwxrwxrwx 1 root root 56 May 8 21:58 wl12xx_sdio.ko -> /res/ICSwifi3/drivers/net/wireless/wl12xx/wl12xx_sdio.ko

root@android:/system/lib/modules/drivers/net/wireless/wl12xx #

[edit: I put back the stock .13 wifi drivers (cleared cache and dalvik cache)...but...stock kernel still has 'non functional wifi'...LUPUS messed up even better :(( ]

Anywayz I will test a GB rom soon, so later-on will reflash Superleggera V5 completely...which doesn't take too long.

Br.

Michel
[Sony Ericsson Xperia Mini, Mini Pro, Xperia Pro, A] CTCaer:
Yep. Basically lupus-script.sh removes every modules and makes these links. And if you don't have the modules in /res/icswifi3 then the wifi breaks.

From stock firmware you need these for wifi to work:

/system/lib/modules/compat/compat.ko
/system/lib/modules/drivers/net/wireless/wl12xx/wl12xx.ko
/system/lib/modules/drivers/net/wireless/wl12xx/wl12xx_sdio.ko
/system/lib/modules/net/mac80211/mac80211.ko
/system/lib/modules/net/wireless/cfg80211.ko

Also compat_firmware_class.ko is not needed to load the stock drivers.

Btw no need to clear dalvik-cache for this. It has nothing to do, other than apps/framework.
[Sony Ericsson Xperia Mini, Mini Pro, Xperia Pro, A] arcatarc:
For the ones who need it those are the stock .13 wifi modules(flashable) ;)
[Sony Ericsson Xperia Mini, Mini Pro, Xperia Pro, A] CTCaer:
Nice. I'll update OP with them
[Sony Ericsson Xperia Mini, Mini Pro, Xperia Pro, A] wedgess:
Yes previous modules Will be moved to /system/lib/modules.old. So if someone switches to my kernel then back to yours they could just delete /system/lib/modules and rename /system/lib/modules.old to /system/lib/modules.

And people using my kernel will always have modules in /res/icswifi* folder as that's where I place them when compiling kernel.
[Sony Ericsson Xperia Mini, Mini Pro, Xperia Pro, A] CTCaer:
I will update OP, thank you.
[Sony Ericsson Xperia Mini, Mini Pro, Xperia Pro, A] Soul_Est:
Thank you very much for this kernel CTCaer. It runs beautifully with Xperia Ultimate HD.
[Sony Ericsson Xperia Mini, Mini Pro, Xperia Pro, A] CTCaer:
UPDATED to v2.8

CTCaer Kernel v2.8

At last, v2.8 is here, this brings:

Dual recovery. TWRP (volume keys) and CWM (power key)

Fixed init.d completely and for good for all methods.

Added 3rd button key reset (+vol up), to avoid accidental reboots.

zram now really uses snappy compression/decompression. It's really fast now.

You can really tell the difference when switching apps. No lag anymore.

Script to remove unused ramdisk files after boot to free ram. (cpio 7,8mb and Images/other 1.5mb)

Use max freq for CSI (camera sensor i/o path) -> new bandwidth: 250 MB/s (2000Mbps)

Use max freq for Jpeg encoding unit -> 147.4Mhz to 153.6Mhz

Faster pictures capturing

And many many more..

As always check post 2 for full changelog.

And OP for downloads.

Plus don't forget to press the thanks button :)
[Sony Ericsson Xperia Mini, Mini Pro, Xperia Pro, A] nedunilavan:
v2.8 with more & par better features...
[Sony Ericsson Xperia Mini, Mini Pro, Xperia Pro, A] vleutmans:
yes !!!

YES, I'm on it. Flashing now.

Will send feedback soon :)
[Sony Ericsson Xperia Mini, Mini Pro, Xperia Pro, A] ksmuthucv:
Sorry....I have posted it incorrect.
[Sony Ericsson Xperia Mini, Mini Pro, Xperia Pro, A] vleutmans:
YES

Here is what i was waiting for :)

Flashing now...and testing asap

---------- Post added at 11:00 AM ---------- Previous post was at 10:59 AM ----------

I really don't know, that kernel is pure stock .62 with CWM and init.d added to it.

Just try and you will know :)

[edit: BTW i didn't develop it, i just suggested the kernel, as I'm not a dev.]
[Sony Ericsson Xperia Mini, Mini Pro, Xperia Pro, A] arcatarc:
.....another "gem"from CTCaer.....
[Sony Ericsson Xperia Mini, Mini Pro, Xperia Pro, A] digitalac3:
Aww yeaaaaaaahh!!

Sent from my Ultimate Xperia Ray (ST18i)
[Sony Ericsson Xperia Mini, Mini Pro, Xperia Pro, A] foggyflute:
using it right now, love it, donated, keep up with us, I even love my Ray more than my main phone :-o
[Sony Ericsson Xperia Mini, Mini Pro, Xperia Pro, A] CTCaer:
Thank you a lot. :)
[Sony Ericsson Xperia Mini, Mini Pro, Xperia Pro, A] foggyflute:
well, I'm out of my PP balance so... there will be next time :D
[Sony Ericsson Xperia Mini, Mini Pro, Xperia Pro, A] vleutmans:
init.d ?

Hmm weird, it doesn't run my init.d script....investigating.

[edit] seems my script was not OK too...keep you updated

[edit3] now is working !!! sorry DEV for scaring you :-S

Anyone ?
[Sony Ericsson Xperia Mini, Mini Pro, Xperia Pro, A] CTCaer:
When you said, it was not working again (like 2.7), after spending a lot of time to implement a script code,

to fix init.d for everyone (ramdisk method, iridaki method and int2sd and other)

I was like:

ahahhahaha

Thank god it's working :D

As you can see, here is the new script I have in 2.8:

# CTCaer: fix double init.d
if /sbin/busybox [ ! -f /system/etc/install-recovery.sh ];
then
/sbin/busybox mount -o remount,rw /system
/sbin/busybox mkdir -p /system/etc/init.d
/sbin/busybox chmod 777 /system/etc/init.d/*
/system/bin/logwrapper /sbin/busybox run-parts /system/etc/init.d
else
RECRUN="run-parts"
REC=`cat /system/etc/install-recovery.sh | grep $RECRUN`
if [[ $REC != "" ]];
then
echo "done"
else
/sbin/busybox mount -o remount,rw /system
/sbin/busybox mkdir -p /system/etc/init.d
/sbin/busybox chmod 777 /system/etc/init.d/*
/system/bin/logwrapper /sbin/busybox run-parts /system/etc/init.d
fi;
fi;

This ensures that if iridaki's method exist, then don't run init.d through ramdisk.

If it's not there, then run init.d through ramdisk (autonomous).

If it's there, but does not have init.d inside install-recovery.sh, then again run it through ramdisk.

^That's how the new script in v2.8 works now.

Please don't scare me again before testing :D
[Sony Ericsson Xperia Mini, Mini Pro, Xperia Pro, A] arcatarc:
CTCaer,Iridaki.....many thanks to GREECE.. ;)

Inviato da me!
[Sony Ericsson Xperia Mini, Mini Pro, Xperia Pro, A] Dunc001:
Fantastic work on latest version - FINALLY correctly functioning init.d! First time ever that Mounts2SD has functioned fully on my Ray and not in Safe Mode! And TWRP FTW :cool: Many many thanks for the great work! I have a question on zram - the ROM I am using (Smart) has a zram init.d script and a zram.ko module - are these needed or should it function out of the box with this kernel?

EDIT - Spoke too soon, M2SD now running in Safe Mode again after one reboot because ServiceManager is already running when it attempts to execute :(
[Sony Ericsson Xperia Mini, Mini Pro, Xperia Pro, A] CTCaer:
Well, zram module (.ko file) is needless in ICS and JB kernels. All of them have the module inside the kernel. Sony stock too.

Stock and stock based kernels use a file inside /system/bin called zram_start.sh

It has these inside:

#!/system/bin/sh

echo $(([B]60[/B]*1024*1024)) > /sys/block/zram0/disksize
/system/xbin/busybox mknod -m 600 /dev/zram0 b 253 0
/system/xbin/busybox mkswap /dev/zram0
/system/xbin/busybox swapon /dev/zram0

Your init.d zram script, probably has the same.

So if you have the zram_start.sh script, then you can delete the init.d one.

Zram usage, benefits and more (wall of text, but good info):

In bold, is the value that says how much data can zram compress. Stock is 60 (mb).

It means, it can take 60mb out of ram, compress it to lets say 18-20mb (if ratio is 67-70%, 3-3.3:1)

and put it back to ram and use only 18-20mb. With zram now you saved 40mb.

This is good, because some data, can't be freed with dalvik's gargbage collection.

For example next launcher for me, always use 35mb actual data. But with zram, it uses 20mb.

This have an effect on every app. That's why it has to be fast on compressing/decompressing.

Now with 2.8 it uses a lot less cpu.

Still I think that zram taking 20mb ram is a lot (well for me).

If you want to reduce it, just say how much you want to take,

and then multiply it by 3, and right that number at the script (bold number above).

For example, in CTCaer kernel we have 15mb more total ram than Stock kernel.

15x3=45. So I've changed zram, from 60 to 45.

Other may want a lower value, like 30 or 24 or 16. This translates to 10 or 8 or 5.5mb actual ram used by zram.

The benefits of having zram, is that we can have more apps open and still reduce the ram used by them.

I have, next launcher, youtube, whatsapp, lightflow, next notifications, beautiful widgets, 3 other widgets,

manga watcher, sports tracker, system tuner pro, every system app that needs to be open when there's free ram and other services and still have 114mb free.

Normally without zram, with so many apps running in background, the killing would have started.

So for that reason I recommend using it. If you don't want the system a lot zram, just lower the value.

My recommendation: 45 to 30, for our Ray.

Here something to try: Use your ray with no zram (rename zram_start.sh to .bak)

Fire up system tuner, let it refresh the ram used on every app (it will lower by a lot).

This is the actual used ram. Take a screenshot.

Now rename zram script back to what it was.

Use your phone for a day. Normal use without any game (so it won't kill the background processes)

Check actual ram used in system tuner. You will be amazed.

And as I said, the difference with 2.8 is that zram is a lot faster. No lag when switching apps.
[Sony Ericsson Xperia Mini, Mini Pro, Xperia Pro, A] CTCaer:
I just checked what it means by "safe mode".

Basically that's related to this only. It's not a "real" bug of kernel/ramdisk.

Init.d ramdisk method starts in the same time where the original init.d was.

Basically to "fix" safe mode, we have to move init.d support to class core and move it above service manager.

Unfortunately I won't do it ever, because almost all scripts, are designed with that in mind.

And there are some scripts that rely on starting core services and also some main (like vold).

As for you, as far as I understand, m2sd works in safe mode but it disables moving of /data but it moves apps.

I have something in mind (2nd init.d in /system/specialscripts), but I don't have time now.

Still, moving all /data to /sd-ext (like what m2sd does), is too much for sd card to take.

The best way is apps/scripts that move all apps to /sd-ext/app (and make a symlink back to /data/) and also move the largest libs from /data/data/

That way, the system only reads from sd card partition and the performance doesn't lower and also the sd card does not wear off.

It's what I do (manually).

You can also move dalvik to /sd-ext and create a symlink.

So to sum up, moving init.d above the core services won't happen for CTCaer kenrel, for compatibility reasons.

Maybe sometime I'll implement the feature you want, a 2nd service to start only these specific scripts.

You can try that for now (for manual lovers):

Apps are already moved by that script. So now the biggest storage eater is dalvik.

Make a backup 1st to be safe!
1. Recovery, mount system,data,sd-ext, fire up adb.
2. mkdir /sd-ext/dalvik-cache
3. chmod 771 /sd-ext/dalvik-cache
4. chown system.system /sd-ext/dalvik-cache
5. cp /data/dalvik-cache/* /sd-ext/dalvik-cache
6. rm -rf /data/dalvik-cache
7. ln -s /sd-ext/dalvik-cache /data/

After that do a ls -l inside /data to make sure that there's a symbolic link named dalvik-cache that points to /sd-ext/dalvik-cache.

You just freed 100mb+ from /data on your own.

Btw you can just skip part 5 and just let it rebuild the cache.
[Sony Ericsson Xperia Mini, Mini Pro, Xperia Pro, A] vleutmans:
swappiness and vfs_cache_pressure

Hi ctcaer,

Maybe you might know this stuff:

if I set /proc/sys/vm/swappiness to 100 and also vfs_cache_pressure to 100...will it make better/more use of zram ?

[edit: testing now, is see zram is almost fully used now]..will test in games too.

default values (from your kernel) :

/proc/sys/vm/swappiness : 20 (stock=60 i think)

vfs_cache_pressure : 25 (stock=100)

[edit: I found out zram is causing hick-ups in game like "radiant defense"...so i disabled it by making the zram script (zram_start.sh) non-executable in /system/bin, i think the easiest method to do. It's not a kernel issue, it's zram itself. BTW hick-ups are present with default and tweaked swappiness and vfs_cache_pressure settings.

Ofcourse I don't state everyone should disable ZRAM...only try when you face similar behaviour in gaming.

Br.

Michel
[Sony Ericsson Xperia Mini, Mini Pro, Xperia Pro, A] nedunilavan:
Wifi works like a BOSS...

Viber works flawlessly without any interruption or disconnection...

Thanks man...
[Sony Ericsson Xperia Mini, Mini Pro, Xperia Pro, A] tobbbie:
I think that swappiness and cache-pressure should not be set to extreme values. It forces the kernel to swap out all candidate memory including the one which should better stay in RAM. If you leave it (stock or ctcaer tuned) then more apps can utilize ZRAM and it is not hogged by just one app. After some app-switching all ZRAM should be used anyway - no need to get all ZRAM used by just one app after first switch.
[Sony Ericsson Xperia Mini, Mini Pro, Xperia Pro, A] CTCaer:
Making swappiness 100 will have the opposite effect, because the zram use, will be extensive.

Same with caches.

Yeah zram/swap can introduce some hiccups in games. That's because of kswapd0 thread.

The easiest way to benefit from zram and also don't let kswapd0 take priority is:

an init.d script which has

renice 12 `pidof kswapd0`

It will decrease the hiccups (that are because of kswapd0/zram) to none.

The above can benefit you when using a swapfile or swap partition also.

Normal priority of a game is 0. kswapd0 is 0 also. That's why. With this the priority of kswapd0 lowers by a lot.
[Sony Ericsson Xperia Mini, Mini Pro, Xperia Pro, A] tobbbie:
To avoid mis-understanding:

If you have set 60MB of ZRAM it will

NOT eat away 60MB of your RAM (instead much less, see further down)

NOT add 60MB of RAM to your device

Instead it will add another type of memory to the kernel, the SWAP space.

This type of memory was originally NOT used in Kernels for Android as it usually refers to magnetic disc where the amount write operations would simply not matter. With NAND flash wearing out with many writes this was not useful to have.

Writing to RAM would not give problems, but then you could better use RAM directly - here the compromise logic comes:

Spend some RAM, but get 3 times more SWAP in exchange.

So a setting of 60MB ZRAM swap space will simply supply 60MB of swap to the kernel. The kernel will utilize this swap space according to need and set of swappiness.

How much of RAM is finally eaten by the granted 60MB of swap just depends of what is swapped out. After boot when no swap is used yet, the RAM used is zero. While the swap is being used over time, the granted 60MB are gradually used for swapping out pages of memory. Once all pages are used (no free pages in zram swap) you could first look how much of RAM is used - usually it is ~1/3rd of the granted swap space.

Over time (depending on what is swapped in or out), the actual RAM taken may vary (more or less) - just look up in \sys\devices\virtual\block\zram0\ the "files" compr_data_size and orig_data_size.
[Sony Ericsson Xperia Mini, Mini Pro, Xperia Pro, A] viorel78:
CTCaer why TWRP can not flashed ArcatarcXperiaIcsOdexer.zip CWM flashed successfully
[Sony Ericsson Xperia Mini, Mini Pro, Xperia Pro, A] CTCaer:
2 things come to mind:

Either not signed zip (you can bypass that inside twrp),

or

It uses an old updater binary.

If it comes to updater binary, it's normal for now.

Twrp uses a newer updater api (recovery API 3).

Basically you have to replace the updater binary with a new one.

Team Win have released one (don't know if it has incompatibilities with our devices, but probably not):

update-binary-3

I'll investigate more on that matter when I have time, to see if there are any other solutions.

EDIT:----

I'll update OP for difference between twrp/cwm
[Sony Ericsson Xperia Mini, Mini Pro, Xperia Pro, A] faraaz3:
ctcaer bro y is it that i get full speed in wifi only in kernels 3 and 3.4...ive tried all other kernels including urs ,,download speed only 2KBPS...only this problem restricts me from shifting back to ics:(
[Sony Ericsson Xperia Mini, Mini Pro, Xperia Pro, A] tobbbie:
I use stock .431 and this kernel - DL is 18Mbit/s and UL 2.6Mbit/s at my desk with WIFI - so no limit seen here with this kernel...

Seems you have a problem in upper layers or wifi modules.
[Sony Ericsson Xperia Mini, Mini Pro, Xperia Pro, A] CTCaer:
Yep, as tobbbie said. Either that or a problem with router, that newer wifi drivers from 3.x kernels bypass.

Using stock based .587/.13 rom and reach 2.1MB/s (16.8Mbps), which is my home's adsl2 max speed.
[Sony Ericsson Xperia Mini, Mini Pro, Xperia Pro, A] sheppii:
CTCaer, did you made some tweaks for sio scheduler in v2.8? Cause battery life with combination of smartassV2 governor and sio scheduler is outstanding - almost 5 days on my Ray with common use! :silly:
[Sony Ericsson Xperia Mini, Mini Pro, Xperia Pro, A] faraaz3:
ctcaer any solution for the wifi problem????..plzzz i like ur kernel so much..searched google cracked my head..cudnt do anything:(
[Sony Ericsson Xperia Mini, Mini Pro, Xperia Pro, A] arcatarc:
Try updating the firmware of your router:you can find it on the manufacturer site..

Inviato da me!
[Sony Ericsson Xperia Mini, Mini Pro, Xperia Pro, A] CTCaer:
I tuned it on 2.7.

But, 2.8 has tweaks in PowerManager, such as, fixes to ACPI suspend code and most importantly, uninterruptible sleep by fixing balance_dirty_pages() function. The last one fixes a problem in IO, which is when you suspend the phone it halts and degenerate to a wait busy loop. And thus the phone can't sleep. Now it does its job and says goodnight :P

Yeah you have to update router's firmware or change router.

I won't upgrade the kernel wifi drivers, because it will break stock compatibility.
[Sony Ericsson Xperia Mini, Mini Pro, Xperia Pro, A] esrom02:
am I right that to boot in to TWRP, I will press volume keys? (up or down?) and to boot into CWM, I will press power button? that is when the led turns blue while phone is booting right? and I can use this with .587 based ROM?
[Sony Ericsson Xperia Mini, Mini Pro, Xperia Pro, A] CTCaer:
Doesn't matter which volume key.

When led turns red:

Volume Up or Volume Down --> TWRP

Power key --> CWM

You can use whatever stock based ICS rom (even stock based MIUI). Doesn't matter which version!