yashsingh1/xdaforums huggingface dataset:
[Sony Xperia M2] buzzywaw:
How to Restore Stock Firmware

anyone know how to get back the original stock rom??

i have flash the latest Sony Firmware FTF file, with flash tool 09.18.6

but ended with error message :root .....

disabling root access in dev mode also can fix that

do i have to flash the stock kernel first before flashing the phone

thanx
[Sony Xperia M2] Grimberg111:
I guess you are looking for this tool: developer.sonymobile.com/open-devices/flash-tool/how-to-download-and-install-the-flash-tool/

Sorry not for link form, new user so can't post links.
[Sony Xperia M2] galaxyfreak:
For the packages list, I googled "how to build kernel xda" and clicked on first result

Some were even missing and I bravely ignored it. Still works :P
[Sony Xperia M2] buzzywaw:
thanks,

but the emma wont detect my device

in selection tab is only for the LTE version D2303

mine is D2305

can't i continue flashing with the different model ??

sorry for the silly question
[Sony Xperia M2] Th3 Ant:
That's unity engine bug... They don't want to fix it because it happens only on custom ROMs...

The fix is to delete/rename "android.hardware.audio.low_latency.xml" file in system/etc/permissions folder

Sent from my Xperia M2
[Sony Xperia M2] iFlashed:
Will try later

Thanks

Enviado desde mi Xperia M2 Aqua mediante Tapatalk
[Sony Xperia M2] Grimberg111:
The DXXXX is attleast in my knowledge just different models of the radio. To my knowledge, it should work just fine with all of M2's. Not sure though.

Just to make sure: you did boot into flash mode? If I recall correctly, the front indicator led should turn green when it's in flash mode.

Other thing that might be worth trying is trying another USB port in your pc.

Also check the drivers. I had some serious problems with the drivers on windows when Xperia M2 would show up, but with wrong drivers so the flash tool could not communicate with my phone.
[Sony Xperia M2] f2065:
D2403, for 2 days, several times noticed critical bugs.

- WiFi MAC has changed. Why??? I have a MAC binding in many places. This is the problem now.

- freezes when start ICQ. And even for a long time holding the volume and power - did not react. Then I rebooted but lost the SD card! I rebooted it again - it all came back to normal, the SD card was found. And ICQ works.

- Reboots for some reason lost the SD-card. But after the second reboot - the SD card is restored.

- sometimes when restart, the touchscreen does not work! I can not do anything - just adjust the volume and the open/close power-menu. Off/reboot - I can not! For a long time holding volume- & power - does not react. I have to disassemble and press the OFF-button with a needle.

- When installing programs, there are various errors in the Play Market, such as error 963 and others. But the solutions described in the network do not work. It helps your phone off and back on again. Play Market again works fine.

And it seems that all bugs occur only after connecting / disconnecting the charger. It is likely that when connecting or disconnecting the charger something globally corrupts in RAM and random errors begin.
[Sony Xperia M2] Konstantinosj77:
Thanks for the report!

Just a small hint: Force reboot is vol.+ & power button. :)
[Sony Xperia M2] f2065:
Another bug:

PIN-code is set.

However, the lock screen is put forward top panel buttons!

You can without knowing the PIN - disable / enable Internet, flashlight, offline mode, and other functions!
[Sony Xperia M2] Konstantinosj77:
That's not a bug.
[Sony Xperia M2] iFlashed:
[MENTION=4635923]galaxyfreak[/MENTION] I have checked my packages, and I have installed the ones which weren't installed, except 'lib32z1-dev', which gave me error while installing because it shoud be an update library, and I think is not important at all...

After this, I tried to compile, and same error. This are the commands I follow in order to compile, tell me please if I'm wrong :S

Cloning cross compiler arm-eabi-4.8 :

git clone https://android.googlesource.com/platform/prebuilts/gcc/linux-x86/arm/arm-eabi-4.6/

Variable CROSS_COMPILE to arm-eabi path:

export CROSS_COMPILE=/home/iflashed/kalinet/arm-eabi-4.8/bin/arm-eabi-

Cloning kernel sources from kj77's github

git clone https://github.com/kj77/android_kernel_sony_msm8226.git -b release-cve

Making menuconfig

make ARCH=arm CROSS_COMPILE=$CROSS_COMPILE menuconfig

Compile

make ARCH=arm CROSS_COMPILE=$CROSS_COMPILE -j3

After 5sec compiling, then it gives that error.
[Sony Xperia M2] methos_276:
I wiped everything when I flashed beta 3 and I feel the battery drain too, wiped cache, dalvik, internal memory, system and wiped cache after flashing the rom, gapps and supersu, sdcard flashed as internal memory works ok, some fancy lag now & then but nothing serious, anyway I would like to say thanks to the developers for the hard work
[Sony Xperia M2] f2065:
Bluetooth-MAC also became wrong - 00:00:00:00:5A:AD.

Why does the LOS do not read the real MAC-addresses of Wi-Fi and Bluetooth ?
[Sony Xperia M2] Otaku-San:
Does anyone else has the Problem with Beta 3 that he isn't receiving Calls? I just get some Minutes after someone tried to call me a Message that I have a new Voice Message on my Mailbox...
[Sony Xperia M2] Lucifer Jackson:
Can i try this rom on my D2302. If yes then please let me know about the full procedu

Can i try this rom on my D2302. If yes then please let me know about the full procedure.
[Sony Xperia M2] xazakasrizava:
No, all is fine for me. You may just have a weak signal.
[Sony Xperia M2] Otaku-San:
Okay, yeah that could be the Problem. Because Messaging works fine.
[Sony Xperia M2] xazakasrizava:
I have the same problem in my house sometimes that's why ?
[Sony Xperia M2] Lucifer Jackson:
Help me out new here

Can i try this rom on my D2302. If yes then please let me know about the full procedure.
[Sony Xperia M2] Nitin69:
Yes you can use this rom in D2302,

To install you have to follow below steps :-

1. Unlock bootloader

2. Update bootloader

3. Install TWRP Recovery & root phone

4. Install ROM, GAPPS

5. Enjoy
[Sony Xperia M2] Lucifer Jackson:
Is it fully working or bugs present

I am a student of 10th grade. Going to flash a rom for the first time if you say that it is fully working. I have no option to get new phone if it dies [middle class family ]. So requesting for a bit of assistance.

Thank you
[Sony Xperia M2] LilBlinx:
Your phone can NOT be bricked when flashing a rom. Only when flashing kernel/unlocking bootloader
[Sony Xperia M2] Nitin69:
No problem, will help you but since you are a student study in xda forums and learn.
[Sony Xperia M2] f2065:
The problem of random bugs continues!

And again after the charger (maybe it's an accidental coincidence?).

Many programs have stopped running.

I wanted to run CatLog - that's even it does not start.

Read logs through ADB, and there's a problem:

03-17 11:37:48.939 7306 7306 E SQLiteDatabase: Failed to open database '/mnt/expand/4b72170c-6e0f-43da-9c13-d5728de4e98b/user/0/com.nolanlawson.logcat/databases/catlog.db'.
03-17 11:38:24.604 7629 7629 E SQLiteDatabase: Failed to open database '/mnt/expand/4b72170c-6e0f-43da-9c13-d5728de4e98b/user/0/com.alibaba.aliexpresshd/databases/cache.db'.
03-17 11:38:54.626 7850 7937 E SQLiteDatabase: Failed to open database '/storage/emulated/0/Android/data/com.lonelycatgames.Xplore/cache/thumbnails.db'.
03-17 11:37:40.103 7235 7235 E SQLiteDatabase: Failed to open database '/mnt/expand/4b72170c-6e0f-43da-9c13-d5728de4e98b/user/0/ru.yandex.metro/databases/yandex2.db'.
03-17 11:37:37.330 6911 6977 E SQLiteDatabase: Failed to open database '/mnt/expand/4b72170c-6e0f-43da-9c13-d5728de4e98b/user/0/com.alibaba.aliexpresshd/databases/accs.db'.
03-17 06:09:12.949 17323 17444 E SQLiteDatabase: Failed to open database '/mnt/expand/4b72170c-6e0f-43da-9c13-d5728de4e98b/user/0/mobi.mgeek.TunnyBrowser/databases/google_analytics_v4.db'.
03-17 05:10:38.112 14481 14528 E SQLiteDatabase: Failed to open database '/mnt/expand/4b72170c-6e0f-43da-9c13-d5728de4e98b/user/0/com.icq.mobile.client/databases/agent-dao'.

Launched X-Plore, checked - the files of these path and databases - exist.

But X-Plore can not open them. Without errors, just does not open.

After rebooting the phone - everything returned to normal, X-Plore opens these databases. And programs that did not work - again work.

So the bug is that the work with the databases breaks down.

It happens about every day, and every time it starts after charging the phone. I did not charge specially for a day and a half - everything was fine.

Then after charging - a bug.
[Sony Xperia M2] Lucifer Jackson:
Any bug found in D2302

Sir, is there any bug found in D2302? Is it a problematic one?

Thanks [very new user, never done things like that just saw a bit of videos that's why disturbing a bit.]
[Sony Xperia M2] Konstantinosj77:
Interesting,I don't get this on OmniROM and I have a theory about it!

Delete /system/lib/hw/power.eagle.so reboot and test again.
[Sony Xperia M2] proadi96:
I haven't been playing with my xperia since few months and today I decided to check back on XDA and seen some 7.1.1 ROMS are out and I was like whaaaaat lemme try these :D Installed Lineage and its working nicely, awesome work guys. Just one thing is bugging me... It might seem like a stupid question but... how to root Lineage? I seen the root option in developer settings but that seems to work with ADB only? Any ideas? I've searched the thread but no one seem to have answered that question? Thanks in advance
[Sony Xperia M2] galaxyfreak:
Flash SU

https://mirrorbits.lineageos.org/su/addonsu-arm-signed.zip
[Sony Xperia M2] Lucifer Jackson:
Sir, is there any bug found in D2302? Is it a problematic one?

Thanks [very new user, never done things like that just saw a bit of videos that's why disturbing a bit.]
[Sony Xperia M2] Konstantinosj77:
Stop spamming the thread. Just read!

Many users posted reports that this ROM is working fine on D2302.

There are infinite guides around the M2 section on how to flash ROMs.
[Sony Xperia M2] proadi96:
Thanks [MENTION=4635923]galaxyfreak[/MENTION] that worked beautifully.
[Sony Xperia M2] iHusky:
can someone tell me how to flash this kernel fix?
[Sony Xperia M2] leho6694:
[/COLOR]

Arise Sound Systems Leviticus 1.3(one of editions viper4android atmos) work 100 % on this rom:)

Pls ring and notification Volume unlink
[Sony Xperia M2] Otaku-San:
What is this Text under the WiFi SSID?

Is this a Bug?
[Sony Xperia M2] Otaku-San:
Hotspot works fine for Me i can Connect to it with other Devices Have Tried with my iPhone 5 and it connects without any Problems. What Error do you get?
[Sony Xperia M2] f2065:
found small bugs:

1. The first time one of the options has no text. Only icon. Do not understand what it is. See attached screenshot

A similar icon is then shown in the memoryâ€¦

2. Settings - Status bar - Status bar icons - Time. Show hours, minutes, and senconds - It does not work. Seconds no.

3. Old timezone - version 2016g. Already there 2016j.

4. The camera does not start by pressing a hardware button camera.

5. does not work focusing on the half-pressing the button In the camera.
[Sony Xperia M2] Th3 Ant:
Try doing first setup in english, then change language for yours

Sent from my Pixel
[Sony Xperia M2] galaxyfreak:
You've enabled Verbose WiFi logging in developer settings.
[Sony Xperia M2] Otaku-San:
Yes thanks. But I can't Turn it Off now it is still there after turning it Off in the Developer Options. :confused:
[Sony Xperia M2] galaxyfreak:
Reboot your phone after turning it off.
[Sony Xperia M2] Otaku-San:
Thank you ;)
[Sony Xperia M2] f2065:
After the combination storage - all the additional storage does not seen anywhere else.

I inserted microSD 16GB and formatted for internal storage - and under Storage shown that storage was 21.96gb (all right).

When connected to the computer and select "Transfer files" - in Windows Explorer shows only one drive (size 4.99gb) - this is an old internal memory.

In androd I anywhere (except the settings) do not see the new storage, except the old 5 gb.
[Sony Xperia M2] mantazzo:
Can't answer about first three, but 4 and 5 I think is the same as in CM13. About 4 - you can set that you can press lock button twice to open camera. About 5 - no idea, maybe a different application is needed..?
[Sony Xperia M2] kice007:
1. The first time one of the options has no text. Only icon. Do not understand what it is. See attached screenshot

A similar icon is then shown in the memoryâ€¦

2. Settings - Status bar - Status bar icons - Time. Show hours, minutes, and senconds - It does not work. Seconds no.

3. Old timezone - version 2016g. Already there 2016j.

4. The camera does not start by pressing a hardware button camera.

5. does not work focusing on the half-pressing the button In the camera.

True. Not a huge bug but still , not working. Overall , 10/10 lag-free on M2 Aqua D2403 way better than omnirom 7.1
[Sony Xperia M2] Umesh1041:
Dear [MENTION=4635923]galaxyfreak[/MENTION]

First things first..THIS IS ONE HECK OF A ROM MATE!!!

Secondly..Great work with the rom....and tq from all the DS users..

Third.. [MENTION=7309485]jobinrjohnson[/MENTION] post abt the ds fix..he was right..apply it in the next beta

Fourth...try taking a look at this thread http://xdaforums.com/xperia-m2/general/mod-interactive-alternative-to-stock-t3474487 and try applying it into the next build as it gives super performance and battery life too...

Lastly....THANKS A BUNCH FOR THE FCKN AWESOME ROM!!!
[Sony Xperia M2] jobinrjohnson:
That is a tweak you can apply it via kernel auditor or something like that if you want. I think it will. Cause some unexpected behaviors like random reboots or some other issues.
[Sony Xperia M2] ARandomIndian:
In other news I saw galaxy is/was added to the contributors list in settings>About Phone>Contributors

Nice achievement, also found someone similar to Konstantinosj77, that is - if it's not him.
[Sony Xperia M2] 3rr0r-3y3-(KuTtY):
Downloading ..... Thank for this ROm i am wait for this so long .......
[Sony Xperia M2] galaxyfreak:
1. They're probably missing Russian translation. What menu is that?

2. CM bug. Was fixed yesterday :)

https://github.com/CyanogenMod/andr...mmit/fddb769a4ddf705ef1ed0616bccac37b38acd1cb

3. I don't get it. Where, what?

4. & 5. Did it work on any previous CM ROMs?
[Sony Xperia M2] daniloazevedo:
LiveDisplay not working for me too.
[Sony Xperia M2] vasiliusO:
Sorry for my English.

Thanks for ROM

I have the same problem.

Furthermore, after reboot booth cards do not work.

Solution of jobinrjohnson work for me.

P.S. M2 D2302

1. Flash last stock

2. Flash TWRP from 1-st post

3. Flash ROM
[Sony Xperia M2] galaxyfreak:
[MENTION=7309485]jobinrjohnson[/MENTION] and everyone else who confirmed:

Alright, DS build.prop edit makes sense now, according to this, it only affects DS.

https://github.com/CyanogenMod/andr...mmit/c5df20b6ce335899d680e29b9e98b4396e4a078b

Will include in next build.
[Sony Xperia M2] galaxyfreak:
Fastboot mode

ADB:
[Sony Xperia M2] f2065:
Did not help. As before, half a day everything was fine, it was charged, and when the charge reached 95% - the previous bugs started.

But the problem begins Errors with the appearance "Read-only file system"

E null : Failed to store cache

E null : java.io.FileNotFoundException: /mnt/expand/4b72170c-6e0f-43da-9c13-d5728de4e98b/user/0/ru.yandex.metro/cache/metro-config-cache (Read-only file system)

E libEGL : error unlinking cache file /mnt/expand/4b72170c-6e0f-43da-9c13-d5728de4e98b/user_de/0/ru.yandex.metro/code_cache/com.android.opengl.shaders_cache: Read-only file system (30)

Then mass errors begin "E SQLiteDatabase: Failed to open database".

W FileUtils: Failed to chmod(/mnt/expand/4b72170c-6e0f-43da-9c13-d5728de4e98b/user/0/ru.yandex.metro/files): android.system.ErrnoException: chmod failed: EROFS (Read-only file system)

W FileUtils: Failed to chmod(/mnt/expand/4b72170c-6e0f-43da-9c13-d5728de4e98b/user/0/ru.yandex.metro/files): android.system.ErrnoException: chmod failed: EROFS (Read-only file system)

E SQLiteDatabase: Failed to open database '/mnt/expand/4b72170c-6e0f-43da-9c13-d5728de4e98b/user/0/com.alibaba.aliexpresshd/databases/cache.db'.

E SQLiteDatabase: android.database.sqlite.SQLiteException: not an error (code 0): Could not open the database in read/write mode.

P.S. /sdcard in the mode ReadOnly. I can not rename any of my files. After reboot - everything is normal again
[Sony Xperia M2] galaxyfreak:
Noone has reported similar issue yet.

How about removing ru.yandex.metro app?
[Sony Xperia M2] f2065:
Are there any conditions that do not match?

- D2403 rev5

- microSD 64gb

- microSD SanDisk Extreme

- microSD format internal storage

- migrate data to microSD

Earlier complained that some SD-cards did not work. Probably the reason was the same?

A bug has been seen before this installation.

In general, the problem is that the SD-card filesystem switches to ReadOnly mode.

Why can this happen?
[Sony Xperia M2] vijaykmr:
According to Xperia M2 specifications, 32GB card is officially supported.
[Sony Xperia M2] f2065:
In the official firmware 5.1.1 64GB cards are working for many users for a long time. Including cards SanDisk Extreme 64.

PS. Usually, the bug was 12-30 hours after the reboot: by this time I connected the charger and the charge went up to 95-100%, and by this time a bug appeared.

Now I'm charged on 93% phone rebooted, immediately connected the charger. Several hours passed - there is no bug.

It is likely that the bug is not connected with charging, but is related to the time of uptime
[Sony Xperia M2] galaxyfreak:
[MENTION=596047]f2065[/MENTION], appreciate the reports but we can't work on it if we can't reproduce. Gotta establish a pattern how to reproduce the bug.
[Sony Xperia M2] f2065:
Or maybe the charger is connected with a bug. Now the bug came up again, earlier than usual, but just after the charger.

Did the eject SD card and re-insert. Without reboot. The SD card again worked fine. Why does it go into the mode ReadOnly ???

I'll try to use SD card Transcend 32GB…
[Sony Xperia M2] Vtrendzzy:
I'm using this ROM without gapps & it's running very smoothly.

One weird bug.

When Bluetooth headset is connected, WiFi gets disconnected within a sec then headset disconnects. Auto connects WiFi and headset then again within a sec disconnect.

It feels like they both are battling against each other to stay connected.

I encountered this bug while using YouTube. I mean any online streaming video.

Gapps has nothing to do with it as my galaxy s4 mini has gapps and MM 6.0.1. Also has this issue.

It maybe Linage os specific bug but if anyone else came across this bug then please report.
[Sony Xperia M2] f2065:
Reading NFC-cards someone works?

In the old versions it worked. Now I tried it - I do not see any NFC card. NFС is enabled. In the application permissions settings - the NFC is not managed.

It's just me it does not work or all of Beta-3?
[Sony Xperia M2] Lucifer Jackson:
I have heard in a website that xda has developed a final and stable marshmallow for D2302. Can anyone please provide me the link.
[Sony Xperia M2] ARandomIndian:
https://xdaforums.com/xperia-m2/orig-development/rom-cyanogenmod-12-developement-t2971213
[Sony Xperia M2] ARandomIndian:
[MENTION=4550509]Konstantinosj77[/MENTION] [MENTION=4635923]galaxyfreak[/MENTION]

With a few tweaks battery life is amazing
[Sony Xperia M2] :
I have a problem, I installed the new recovery with adb fastboot, then installed the kernel with adb fastboot, then installed the rom with recovery, but it keeps on loading the system. I tried a diffrent order when I installed kernel after rom with recovery but it's still giving the same result. What am I doing wrong? :confused:
[Sony Xperia M2] Hrustus:
What tweaks? :3
[Sony Xperia M2] galaxyfreak:
The second order you tried is correct.

1) Flash Recovery

2) Boot into that recovery

3) Wipe Data

4) Flash ROM

5) Flash kernel
[Sony Xperia M2] f2065:
Day with a SD-card 32GB (Transcend Class 10, without UHS). There is no bug.

We can assume that the bug occurs with 64GB SD-cards or UHS-I SD-cards.

UHS-I SD-card now probably have many on 32GB. Therefore, it is more likely that the problem with supporting 64GB SD-cards…

I assume that the conditions for reproducing the bug:

microSD 64gb AND microSD format internal storage AND migrate data to microSD AND opengapps-nano AND uptime about 24 hours

Are there more users with a 64GB SD-card (microSDXC) ?
[Sony Xperia M2] :
What do I need to wipe? Everytime I installed the ROM I just swiped to revert to factory reset. Do I need to use advanced wipe and then set something?
[Sony Xperia M2] ARandomIndian:
Kernal and system I'll post all my changes as soon as i can,

L-Speed and Greenify

to get you started (NOTE: Do not mess with anything Doze related on Greenify only through L-Speed)
[Sony Xperia M2] galaxyfreak:
No, I've meant factory reset. It should be ok
[Sony Xperia M2] galaxyfreak:
So it's not just a few tweaks :P

You've recompiled the kernel?
[Sony Xperia M2] ARandomIndian:
L-Speed makes a bunch of changes to the kernal at the same time not sacrificing to much performance It's quite good,

That along with Greenify's hibernation mode makes standby time impressive,

I didn't not touch the kernal myself per say, i don't have enough knowledge to improve on what you guys already made :good: I'll mostly end up bricking it if i make similar changes myself.

I'll post all the changes in the night
[Sony Xperia M2] f2065:
List of bugs I have in LOS Beta-3:

1. Offline charge - lags, and hands when try to poweron.

2. Reboot with connected charger - hands and/or poweroff, instead of restarting.

3. SD-cards 64gb (or SanDisk UHS-I ?)- go into ReadOnly-mode after day of work.

4. Wi-Fi MAC does not match (random?).

5. Bluetooth MAC invalid (00:00:00:00:5a:ad - standard MAC for errors).

6. NFC does not work! Do not read the NFC-cards that were read in older versions of CM14.1. The MIFARE card, which was read in the old CM14.1 - is not readable in LOS Beta3. After errors, NFC stops responding at all. Reboot does not help. It helps only poweroff-poweron.

Now I will try OmniROM…
[Sony Xperia M2] galaxyfreak:
Probably both on same cause. Can confirm. Will try to fix.

No idea, can't reproduce.

Also maybe related. Can confirm, will look into it.

Konstantinos says his NFC card works. Will look over Mifare again, but nothings changed.
[Sony Xperia M2] f2065:
64GB (or 128GB) cards microSDXC? SanDisk cards? UHS-I cards?

MIFARE Plus X - does not work (worked fine before).

MIFARE Ultralight - worked.
[Sony Xperia M2] galaxyfreak:
16GB Sandisk is what I use.

No idea about various types of Mifare. Suprised any other than Classic work. Only thing I can suggest is replacing files about NFC from earlier build where it worked and report back if you find which file is the culprit.
[Sony Xperia M2] f2065:
Omni has the same problem, SanDisk Extreme 64gb goes into ReadOnly mode. An hour after installation, in the process of downloading software from the PlayMarket…

Will SanDisk Extreme 32gb work properly?

What kind of high-speed card do I buy to work with LOS/Omni?

It can be possible to make a debug kernel which will have a lot of information in the log output to find the reason for the transition to ReadOnly ?

Now there is no information on the reasons in the log, and there is no information about re-mounting the SD card.

Can a 64GB SD card work badly with an ext4, and require an exFAT?

Is it possible to somehow format the SD card in exFAT for combining memory?

I repaired MIFARE Plus !!!

You have broken libnfc-brcm.conf in all the latest firmwares (LOS, Omni)…

Need line NFA_PROPRIETARY_CFG={05:FF:FF:06:81:80:77:FF:FF} - ©…