yashsingh1/xdaforums huggingface dataset:
[Xperia Z5 Q&A, Help & Troubleshooting] linpe:
Workaround?

Hi guys, I have the same fingerprint issue on my Xperia Z5 Compact (E5823, unlocked bootloader, Stock MM (32.2.A.0.253), modified stock kernel (only added SuperSU, TWRP, DRM Fix)) and it happens once a day (sometimes twice). I have tried every single method from this thread and still only temporary fix is reboot (completely frustrating -.- ) So I was thinking, if we can't find the real cause of the problem, maybe we can fix it with some workaround solution.

*Note: This is just an idea and I don't know how to do it by myself. I am posting it here in a hope that this might inspire someone who actually know how to do this.

Facts:

1. When fingerprint stops working and on lock screen is message "Fingerprint hardware not available", we can go to Service Menu (dial *#*#7378423#*#*) --> Service Test --> Fingerprint Test --> and there is message "Sensor not OK"

2. After reboot, fingerprint is working again and in Service Menu --> Service Test --> Fingerprint Test --> there is message "Sensor OK"

Idea:

Maybe we don't have to reboot the whole system. We could kill and start again only services related to fingerprint sensor. Even better, what if we can make an script which will always be running and do something like this:

IF (Fingerprint Test = "Sensor not OK"){

Restart Fingerprint Services;

Keep Listening Fingerprint Test;

}

ELSE{

Keep Listening Fingerprint Test;

}

P.S. Here is an .log file from my Z5C if someone need details of all manifests.

https://goo.gl/Ls9cW4

Important things to know:

1. Whenever I try to unlock device (no matter if fingerprint works fine or bad) I can see this error in log:

766 2843 E fpc_fingerprint_hal: capture_single_image failed -4

766 2843 E fpc_fingerprint_hal: do_identify failed -4

2. When I try to unlock device and on lock screen is message "Fingerprint hardware not available", in log file I can see:

766 2843 E fpc_fingerprint_hal: capture_single_image failed -5

766 2843 E fpc_fingerprint_hal: do_identify failed -5

766 2843 E fpc_fingerprint_hal: capture_single_image failed -4

766 2843 E fpc_fingerprint_hal: do_identify failed -4

3. I think breakpoint for fingerprint sensor is this:

1651 3922 E LocSvc_libulp: W/Loc HAL handshake did not happen yet...

766 2843 E fpc_fingerprint_hal: fpc_wait_finger_down failed -5

4. Useful article about Fingerprint Hardware Abstraction Layer (HAL):

https://source.android.com/security/authentication/fingerprint-hal.html

"...one of the major functions in the /hardware/libhardware/include/hardware/fingerprint.h file:

set_notify. Registers a user function that will get notifications from the HAL. If the HAL state machine is in a busy state, the function is blocked until the HAL leaves the busy state."

Really hope that some fix will come eventually...
[Xperia Z5 Q&A, Help & Troubleshooting] pmolto:
Same issue here (marshmallow 32.1.A.1.185 rooted with a few xposed modules). I've tried everything described at the thread (with no success), except rom update and deodex patch.

At first it was happening every 1 or 2 weeks (even coming from brand new phone). But now it is daily.

From an adb shell I see two services which I am able to kill as root:

root@E6653:/ # ps|grep finger

ps|grep finger

system 15366 1 17228 3296 binder_thr 7f7f196d34 S /system/bin/fingerprintd

system 15367 720 1532872 36244 SyS_epoll_ 7f9a9087ac S com.fingerprints.serviceext

After this, they are automatically restarted by the OS. I am waiting for the issue to happen again, just to check if recent linpe's proposal could drive to a workaround.

Just in case anybody could try it before me: In the example above, both services were killed (in fact restarted) through the PID number at the second column:

root@E6653:/ # kill 15366 15367

kill 15366 15367

root@E6653:/ #
[Xperia Z5 Q&A, Help & Troubleshooting] CrisperNeO:
Possible to kill the services without adb?

---------- Post added at 11:37 AM ---------- Previous post was at 11:25 AM ----------

I managed to kill them using terminal emulator. However the fingerprint had not come back and there is even no error message "fingerprint hardware not available" showing anymore.
[Xperia Z5 Q&A, Help & Troubleshooting] linpe:
Same here + I have noticed in Service Menu-->Service Test there is no Fingerprint Test anymore
[Xperia Z5 Q&A, Help & Troubleshooting] kiritoxda:
The problem started when i upgrade Google play service, Have you guys try downgrading google play service?
[Xperia Z5 Q&A, Help & Troubleshooting] linpe:
I have just downgraded Google play service and made full reboot. I will post results here...

Edited: No success :(
[Xperia Z5 Q&A, Help & Troubleshooting] NinjaPanda500:
I too have been really frustrated with this issue and none of the solutions in this thread are working for me. I'm also getting the annoying video playback bug every time the I get the fingerprint bug as well.

However, I just noticed something while trying to figure out this issue today. Idk if this helps point to a solution at all, but I feel like it might have something to do with the DRM patches...

In the Display settings for Image Enhancement, with the DRM Patch working properly, it splits the preview window into two parts showing what difference the XReality thing does. However, after the fingerprint hardware issue starts happening (and subsequently the video playback issues), the Image Enhancement view no longer has the split view, and changing between the settings no longer makes any difference like (just like how it behaves if you use stock without the DRM patch).

I'm not too familiar with how the DRM patches work, but hopefully this could point someone in the right direction? :)
[Xperia Z5 Q&A, Help & Troubleshooting] NinjaPanda500:
Just as I say this I get an instance where the fingerprint reader stops working, but the videos playback and the Image Enhancement menu continues to work fine. Well, I thought those were connected somehow, but just got proven wrong.
[Xperia Z5 Q&A, Help & Troubleshooting] CrisperNeO:
Ditto...
[Xperia Z5 Q&A, Help & Troubleshooting] snurre:
This thread is awesome! Not the subject of course, but I like how everyone share details and experience around this problem. That's why I love this forum.

I'm sure some genius gets to the bottom of this at some point!

I'm having the same problem, also the playback issue and the split preview disappearing(didn't notice that until now). All three problems is solved by a reboot.

It's seems to happen after every night or so.
[Xperia Z5 Q&A, Help & Troubleshooting] Nayibmc:
By disabling the body sensor permission from Play Services it worked for almost all day, from about 7 a.m to 7p.m.
[Xperia Z5 Q&A, Help & Troubleshooting] pmolto:
I tried it before, in my case it did not solve it...

Recently, I totally froze the Google Play Services, and I had no problems after that (ok, in fact other dependency problems as Maps or Hangouts). I debugged it for about 36 hours and the issue did not happen again (in my case it is reproducible in less than 12 hours). So, it seems to be definately related with the Google Play Services, as noted before by some of you.

After that I have unfrozen it and tried with G.P.Services versions 8.3 (default with my ROM version), 9.2, and the most recent 9.4. I faced the problem again with all of them. Now I am going to try the 9.0 (May 2016) corresponding (I guess) to the period of time where the phone was working fine... Will post results here.
[Xperia Z5 Q&A, Help & Troubleshooting] CrisperNeO:
I also have a strong feeling that it relates to the Google Play Services as I remember that I didn't have the problem some month ago, and then Google Play Services got updated.
[Xperia Z5 Q&A, Help & Troubleshooting] ZawyNesio:
Hi, maybe it's not a solution, but I'm on stock (latest 32.2.A.0.253) and using AndroPlus Kernel (v34) with TWRP 3.0.2 and it seems that this issue isn't any more (almost for 2 days).

Maybe it's something with kernel (remember that the kernel have control to the hardware). I almost forgot to say, I'm using a LATAM E6603. I'll report in few days if the issue come back.
[Xperia Z5 Q&A, Help & Troubleshooting] Antho02:
just froze mine and fingerprint stopped working immediately :/
[Xperia Z5 Q&A, Help & Troubleshooting] ImS0Raw:
I'm running stock kernel and no problems for a few weeks now. Used to have it almost daily.
[Xperia Z5 Q&A, Help & Troubleshooting] delca85:
So your advice is to install androplus kernel?

Thanks a lot!

Inviato dal mio E6853 con Tapatalk 2
[Xperia Z5 Q&A, Help & Troubleshooting] ZawyNesio:
Yes, indeed, but it doesn't secure the issue is solved, so, you can try it and post here what's the result. I need to say that I made a clean install

First I wipe system, cache, dalvik, and data (I have many restores so I decided to wipe system, either I come from CM13) then flash a stock Rom (Generic LATAM to e6603) and then flash via fastboot the AndroPlus Kernel v34 and the TWRP.

Right now I have xposed, some modifications in ui and any issues with fingerprint (for now)
[Xperia Z5 Q&A, Help & Troubleshooting] EDGN:
Im Running Xpower 3.0 Rom with Xposed. I also experienced this error. 2 Days ago i flashed the AndroPlus Kernel 33 (as the Rom is based on .224)

I also wiped Cache & Dalvik Cache. Sine then the error is gone! Additionaly my Battery life improved a bit and some random Reboots stopped.
[Xperia Z5 Q&A, Help & Troubleshooting] stipi69:
Same here with or without xposed.

Fails over time untill rebooted on either:

- Z5 Xpower v3.0 stock based rom (current)

- xperia X rom based on slim v2.4

- will try stock.253 and report
[Xperia Z5 Q&A, Help & Troubleshooting] EDGN:
Just try the Androplus Kernel v33 bro
[Xperia Z5 Q&A, Help & Troubleshooting] pmolto:
No success with ROM 32.1.A.1.185 + Androplus kernel v30.

Now going to try a whole wipe, ROM 32.2.A.0.253 and stock kernel.
[Xperia Z5 Q&A, Help & Troubleshooting] Antho02:
people without root still have this issue?
[Xperia Z5 Q&A, Help & Troubleshooting] nabeelahmad909:
restart your phone and it all set
[Xperia Z5 Q&A, Help & Troubleshooting] quack3d:
I upgraded to 32.2.A.0.253 and used rootkernel to get root and recovery from here: http://xdaforums.com/xperia-z5/development/root-automatic-repack-stock-kernel-dm-t3301605

Flashed xposed and everything works peachy. No issues with fingerprint hardware missing anymore.
[Xperia Z5 Q&A, Help & Troubleshooting] kiritoxda:
Guys I am convinced that Google Play Service is the cause of this issue. I think I have a solution but I need your help. Go to the PlayStore and download "Disable Service" by WangQi. Run the app and navigate to "Google Play services" under System. There you will find over 400 services you can disable by unchecking them. Keep unchecking the services until you find the culprit. I know this will require alot of work since you have to wait a day or two to make sure the issue is resolved. Do not uncheck all the service at once since some apps require Google Play service to function or it can break your phone, make sure you TWRP backup your phone before preceding.
[Xperia Z5 Q&A, Help & Troubleshooting] Nayibmc:
I'm not really sure, but I think what triggers this problem in my case is watching YouTube videos. I say this because the fingerprint sensor worked for almost a whole day, until I started watching some YouTube videos and got the error that doesn't let me play any video on the app. As soon as that happened, fingerprint sensor and image enhancement also stopped working.

I thought the problems were just three: YouTube, fingerprint and image enhancement. But apparently video recording also gets affected.

By the way, does this happen to someone with a non-rooted phone? Or is it just for rooted Z5s?
[Xperia Z5 Q&A, Help & Troubleshooting] kiritoxda:
Your problem can be solved by disabling Body Sensor in Google Play service.
[Xperia Z5 Q&A, Help & Troubleshooting] CrisperNeO:
I'll try this.

I also have strong feeling that this is related to Google Paly Services...
[Xperia Z5 Q&A, Help & Troubleshooting] kiritoxda:
Hey, try disabling FingerprintScannerIntentService under Google Play service, i had mines unchecked for a day now and i haven't had any issues.
[Xperia Z5 Q&A, Help & Troubleshooting] CrisperNeO:
Did it and the issue occurred once, I have restarted the phone, speculating that this works with a restart... Will report back.
[Xperia Z5 Q&A, Help & Troubleshooting] quack3d:
Any of you still have the issue with .253 firmware?
[Xperia Z5 Q&A, Help & Troubleshooting] linpe:
Unfortunately yes...
[Xperia Z5 Q&A, Help & Troubleshooting] quack3d:
AndroidPlusKernel?
[Xperia Z5 Q&A, Help & Troubleshooting] rolo143:
I also have this problem. I was watching YouTube videos and I locked my phone, then fingerprint sensor stop working. It also affects playing videos in YouTube there's a message that says "There was a problem while playing. Touch to retry" and every other video I try to play on facebook, twitter, etc. (except chrome) I only fix this problem by rebooting my phone and that also fixes fingerprint scanner. I think this problem is because of google play services but I dont know how to fix it. Disabling body sensors permission from google play services might work, but I need them to play need for speed, lol. So I dont really know what's the cause of this, but its really frustrating.

By the way I'm also rooted, does this happen without root and xposed?
[Xperia Z5 Q&A, Help & Troubleshooting] fernandocechinel:
I bought the Z5 E6683 dual last year, and after a few updates, the "fingerprint scanner" was remover from the lock screen menu and diagnoses tool.

I read that sony removed this features from the Z5, but there is anyway to enable it again? My phone dosnt have warranty...
[Xperia Z5 Q&A, Help & Troubleshooting] kiritoxda:
Your problem has to do with mediaserver crashing and the only way to fix it now is to disable body sensor from the play service.
[Xperia Z5 Q&A, Help & Troubleshooting] CrisperNeO:
Confirming that this service is not the one. Don't know which one to try next...
[Xperia Z5 Q&A, Help & Troubleshooting] kiritoxda:
It's trial and error from this point on, you can try disabling 10 service at a time starting for the top of the list until you find the culprit.
[Xperia Z5 Q&A, Help & Troubleshooting] pmolto:
Second day running my E6653 without the fingerprint issue (until now it was every 12 hours or so). Now I am on 32.2.A.0.253 ROM, stock kernel, flashed whith every possible wipe option, rooted, and (still) no xposed.
[Xperia Z5 Q&A, Help & Troubleshooting] linpe:
modified stock kernel (only added SuperSU, TWRP, DRM Fix)
[Xperia Z5 Q&A, Help & Troubleshooting] quack3d:
Any chance the DRM fix is different from the one in rootkernel? Or could the culprit be the dm-verity or Sony RIC? I can't remember what I selected on those.
[Xperia Z5 Q&A, Help & Troubleshooting] CrisperNeO:
Yup... disabled the analytics services and some of the reporting services first.

---------- Post added at 07:37 AM ---------- Previous post was at 07:37 AM ----------

Can you share your Google Play Services version?

---------- Post added at 07:39 AM ---------- Previous post was at 07:37 AM ----------

Hi guys,

as said I strongly feel that it's related to Google Play Services, because I hadn't this problem before for a long time (have been on Romaur 4.2.1 for a long while). And the only thing that gets updated is the Google Play Services.

The issue happen to me almost once a day (pretty much at the similar time period). I have xposed + Amplify installed and have limited several Google Play Services related alarms. I'm guessing that the culprit is limited, therefore once it triggers alarm successfully, the fingerprint sensor is then gone.

I'll try to find out which one is the bad guy.
[Xperia Z5 Q&A, Help & Troubleshooting] kiritoxda:
Alright you do that and ill disable sync services and sensors.
[Xperia Z5 Q&A, Help & Troubleshooting] linpe:
I modified kernel with rootkernel v4.51 and here are options I selected:

Sony RIC - Disabled

TWRP - Installed

BusyBox - Installed

SuperSU - Installed

DRM Fix - Installed

Did someone try rootkernel v5.0?
[Xperia Z5 Q&A, Help & Troubleshooting] quack3d:
I used v. 5 rc4 of rootkernel.

Sony RIC - Disabled

TWRP - Installed

BusyBox - Not Installed

SuperSU - Not Installed (flashed a .zip later)

DRM Fix - Installed

And like I said, upgraded from .185 to .253 and no issues with fingerprint anymore.
[Xperia Z5 Q&A, Help & Troubleshooting] linpe:
I will try rootkernel v5.0 rc4 and post here if fingerprint issue is solved.
[Xperia Z5 Q&A, Help & Troubleshooting] pmolto:
In my case, things are now going fine with the G.P.S. 9.4.52.

I faced the issue with theree different (older) GPS versions, althought it was running the previous 32.1.A.1.185 ROM (as per noted in previous messages).
[Xperia Z5 Q&A, Help & Troubleshooting] ImS0Raw:
No. Been running stable for weeks now.
[Xperia Z5 Q&A, Help & Troubleshooting] linpe:
Do you have rooted or not rooted stock kernel? If rooted, which version of rootkernel did you use?
[Xperia Z5 Q&A, Help & Troubleshooting] jew94:
Hi

I've tried all the solutions above but nothing works.

I've found that the error is related to the screen rotation or rotation lock. Does anyone know anything about this?

TIA
[Xperia Z5 Q&A, Help & Troubleshooting] Zephyron:
Have had this problem for a while, updated to .253 and and installed androplus v34 and the missing finger print hardware problem seems to be gone. I have xposed systemless and a few mods installed and its been about two weeks now without problems.
[Xperia Z5 Q&A, Help & Troubleshooting] CrisperNeO:
Stock rom?
[Xperia Z5 Q&A, Help & Troubleshooting] botanicfts:
So, since yesterday I have the same problem on my Z5 Compact. The first time I added applications and processes from fingerprint scanner to white list (doze) and reboot. A day later, the problem reappeared, this time helped only reboot. Im on xpower v3.0 with stock kernel with drm fix.
[Xperia Z5 Q&A, Help & Troubleshooting] Zephyron:
Yep, stock rom
[Xperia Z5 Q&A, Help & Troubleshooting] linpe:
Hi guys,

this fingerprint issue bothered me for a while and here is what solved my problem (for now):

I have rebuild .253 kernel with rootkernel v5.0 rc4 (before I was using v4.51) and just reflashed it. I didn't wipe any data or cache while reflashing kernel. So far so good, after 35 hours my fingerprint is working normally (before, fingerprint would stop working every 8-12 hours), hope it will stay like this. I will post here if anything changes.

P.S. Here are options I selected while rebuilding kernel with rootkernel v5.0 rc4:

DM Verity - Disabled

Sony RIC - Disabled

TWRP - Installed

BusyBox - Installed

SuperSU - Installed

DRM Fix - Installed
[Xperia Z5 Q&A, Help & Troubleshooting] EDGN:
Meanwhile it should be clear that this is a Kernel related Problem as all Users with newer Kernel dont have this Issue anymore. So if you have this Problem, u should flash a newer Kernel.
[Xperia Z5 Q&A, Help & Troubleshooting] christiansfreeman:
the problem is not kernel related it is bootloader related I believe

Hello I hope we really get to the source of this problem. For now I just dont use the fingerprint scanner so I dont have to deal with this issue . Anywho I have had this phone since november never had any fingerprint related issues . EVER . two weeks ago I decided to unlock my bootloader to get the ambient display feature (how stupid ) tried 3 different roms but over time I get the fingerprint hardware not available . so I decided to flash the newest ftf and relock my bootloader . Guess what ? Still have the stupid fingerprint error . & ive never had this problem prior to unlocking bootloader . Now am upset cause I knew I should have kept the phone the way the manufacter created it there so advanced now Im tired of the advesre affects of modifying phone . I honestly dont think with the current marshmallow we can have a 100 percent stable fingerprint scanner with a previous unlocked bootloader. No drm keys backup
[Xperia Z5 Q&A, Help & Troubleshooting] EDGN:
That should be the reason in your case.
[Xperia Z5 Q&A, Help & Troubleshooting] CrisperNeO:
Actually I'm having Z5P E6883. I'm not familiar with the rootkernel. Where do I find it?
[Xperia Z5 Q&A, Help & Troubleshooting] linpe:
http://xdaforums.com/xperia-z5/development/root-automatic-repack-stock-kernel-dm-t3301605
[Xperia Z5 Q&A, Help & Troubleshooting] Antho02:
i was also thinking about flash again the kernel, and maybe the full rom later if kernel didnt improve fingerprint

does the kernel is country related or can use customized_FR kernel with customized_DE rom for exemple?
[Xperia Z5 Q&A, Help & Troubleshooting] EDGN:
Its not Country related. U have to make sure that the Kernel is supposed for ur Rom Base. (.185, .224 & .253)
[Xperia Z5 Q&A, Help & Troubleshooting] ImS0Raw:
Rooted and used the latest version of rootkernel or else I couldn't get recovery.
[Xperia Z5 Q&A, Help & Troubleshooting] linpe:
Did same, now my fingerprint finally works good :)

Hope it will stay like that...
[Xperia Z5 Q&A, Help & Troubleshooting] kiritoxda:
Does rootkernel work for the Z5 Premium?
[Xperia Z5 Q&A, Help & Troubleshooting] linpe:
I think rootkernel should work with entire Z5 family.
[Xperia Z5 Q&A, Help & Troubleshooting] crisr:
Solved with AndroPlusKernel v34

I had this issue "Fingerprint hardware not available" several times a day since I upgraded to 32.2.A.0.253 Marshmallow firmware. In fact I got it on the very first boot after installation (Android initial configuration - but I don't remember if at that point I was already rooted or not - bootloader was unlocked since rooting Lollipop). Anyway, the problem ocurred with AndroPlusKernel v31, and none of the solutions which involved erasing caches or disabling battery optimization worked. Once I flashed AndroPlusKernel v34 (I had to re-root), the problem never happened again, and my phone has been stable for several weeks now. I even reenabled all battery optimizations. Hope this helps.
[Xperia Z5 Q&A, Help & Troubleshooting] Antho02:
yep talked about .253 in both

thanks for the info ;)
[Xperia Z5 Q&A, Help & Troubleshooting] Sh4rkill3r:
happaned to me a few times, stock rom, LOCKED BL, no root. Always with low battery. Looks like it disable itself on stamina/doze.
[Xperia Z5 Q&A, Help & Troubleshooting] PhobiaSoft:
Already have the apps related to Fingerprint Scanning removed from the Doze feature, but the glitch still occurs. All disabling the Body Sensors permission did was prevent me from using gmail, the glitch still happened after the phone had been active for a few hours. Anyone find a permenant fix yet? I'm running a custom ROM, so it may be related to that - although it is based on stock.
[Xperia Z5 Q&A, Help & Troubleshooting] Nayibmc:
I just noticed Facebook videos, live video and gifs also stop working
[Xperia Z5 Q&A, Help & Troubleshooting] kiritoxda:
Hey did you solve the issue on your device yet?
[Xperia Z5 Q&A, Help & Troubleshooting] depotjam:
Solve

Try renaming these files on /system/etc/firmware/

tzwidevine.b00 -> tzwidevine.b00.bak

tzwidevine.b01 -> tzwidevine.b01.bak

tzwidevine.b02 -> tzwidevine.b02.bak

tzwidevine.b03 -> tzwidevine.b03.bak

tzwidevine.mdt -> tzwidevine.mdt.bak

Then reboot.

Work for me and my several friends..
[Xperia Z5 Q&A, Help & Troubleshooting] kiritoxda:
Oh cool, i came across a different solution, I installed Z5P_Sunkernel_Permissive_v22_II_1.6 kernel from http://xdaforums.com/showpost.php?p=66156424&postcount=24 and that fixed it for me but i will try your solution if the problem ever occurs again thanks.
[Xperia Z5 Q&A, Help & Troubleshooting] CrisperNeO:
Where did the idea come? I'll have a try, it's a brand new approach!

I have also tried this, however I ended up with bootloop (I'm having E6883 though).
[Xperia Z5 Q&A, Help & Troubleshooting] kiritoxda:
Your using the E6883 which is the dual version right? you need to download "Z5P-dsds_Sunkernel_Permissive_v22_II_1.6.zip" which is the last file on the download list.
[Xperia Z5 Q&A, Help & Troubleshooting] CrisperNeO:
Yeah, did it like this... Didn't work.
[Xperia Z5 Q&A, Help & Troubleshooting] kiritoxda:
I dunno then, My phone is E6853 with RomAur 3.0