Same bug here — Xiaomi 17 Pro Max (popsicle, 2509FPN0BC), Portugal, MEO,
dual SIM, same build as you: OS3.0.318.0.WPBCNXM.
Your description matches mine exactly, including the one detail that
convinced me we have the same fault rather than two similar ones:
switching back from speaker to earpiece does NOT restore earpiece audio.
The earpiece stays dead for the rest of that call. Only hanging up and
dialling again brings it back. That's specific and counter-intuitive, and
it's not something two people report by coincidence.
I instrumented my device and captured two failures plus four healthy calls
as controls, with verbose audio HAL logging:
setprop persist.log.tag.AHAL VERBOSE
setprop persist.log.tag.APM_AudioPolicyManager VERBOSE
setprop persist.log.tag.AudioFlinger DEBUG
adb logcat -G 64M
--------------------------------------------------------------------
WHAT THE LOGS SHOW
--------------------------------------------------------------------
Best-instrumented failure, 18:05, incoming call, SIM 2:
18:05:28.296 setMode(MODE_IN_CALL)
18:05:28.299 AHAL_Telephony_QTI: switchAudioMode: to AudioMode:IN_CALL
18:05:29.051 RadDeviceStateListener: audioReceiverState: 1 <- earpiece ON
18:05:32.308 *** last audio-stack log line of the entire call ***
--- 7 min 56 s with ZERO lines from AudioFlinger / APM / AHAL ---
--- earpiece goes silent somewhere in here ---
18:13:28.930 I tap SPEAKER
18:13:29.479 RadDeviceStateListener: audioReceiverState: 0
18:26:19.383 call ended (continued 13 min on speaker)
Two things stand out.
1) Android reports the earpiece as active for the entire silent period.
audioReceiverState logs exactly ONE "1" at call start and ONE "0" only
when speaker is tapped eight minutes later. Nothing in between.
2) The whole audio stack — AudioFlinger, AudioPolicyManager, the Qualcomm
and Xiaomi HAL layers — logs absolutely nothing while the audio dies.
No error, no reconfiguration, no device change. Total silence, with
verbose logging on.
--------------------------------------------------------------------
WHY SPEAKER->EARPIECE DOESN'T HELP
--------------------------------------------------------------------
Enabling speaker changes the RX device INSIDE the existing voice session.
The session is never restarted:
18:13:28.941 APM: selectBestRxSinkDevicesForCall() device
AUDIO_DEVICE_OUT_SPEAKER using HW Bridge
18:13:28.942 APM: updateCallRoutingInternal rxDevice
{AUDIO_DEVICE_OUT_SPEAKER} txDevice 0x80000080
Speaker works. Going back to earpiece re-issues the same configuration the
DSP accepted at call start, and produces no sound. The session is only torn
down at hangup:
18:26:19.372 AHAL_Telephony_QTI: updateCalls CallState: ACTIVE ->
INACTIVE vsid:VSID_2
18:26:19.372 AHAL_Telephony_QTI: stopCall: Enter
18:26:20.105 AHAL_Telephony_QTI: VoiceStop: Exit
Reading: the earpiece RX path inside the Qualcomm voice session enters a
stuck state. Re-selecting the earpiece within the session doesn't clear it.
Only a full stopCall / new session does. Nothing above the DSP notices,
which is exactly why the logs are empty.
--------------------------------------------------------------------
RULED OUT, WITH EVIDENCE
--------------------------------------------------------------------
Routing Telecom route stayed EARPIECE from ring to speaker tap.
No stream_devices_changed for STREAM_VOICE_CALL.
Volume STREAM_VOICE_CALL: Min 1, Max 11, earpiece: 11. At maximum.
Pressing volume-up produced no volume_changed event at all.
Thermal 33.9-34.0 C during the failure. Zero mitigation events.
Dialer app Google Phone issued no audio commands between answer and my
speaker tap. You reproduce it on a different dialer.
Third-party You reproduced it in Safe Mode.
Hardware Xiaomi's own CIT tool (*#*#64663#*#*) -> Receiver test
PASSES after a failure. Transducer and amp are fine.
Framework Setup trace is directly comparable to healthy calls:
| metric | failed | healthy |
| setPhoneState duration | 777 ms | 831 ms |
| setMode(IN_CALL)->receiver:1 | 755 ms | 594 ms |
| setCommunicationDevice re- | no | no |
| applied after IN_CALL | | |
| MR2SystemProvider "Could not | x2 | x2 |
| map ... route: 1" | | |
| final route | EARPIECE| EARPIECE|
Note that the MR2SystemProvider error and the ~800 ms setPhoneState appear
in HEALTHY calls too. They are normal for incoming calls on this device.
If you've been treating either as a symptom, they aren't.
--------------------------------------------------------------------
ON YOUR 5G / EN-DC THEORY — I HAVE TO BE HONEST
--------------------------------------------------------------------
My logs do not confirm it. I want to say that plainly rather than pile on
agreement:
- Voice was LTE/VoLTE (networkType=13) on EVERY call, failed and healthy.
No VoNR anywhere, same as you.
- My healthy calls had MORE EN-DC availability than the failed one:
59 and 31 samples versus 27.
- In one of my two failure windows there were ZERO radio events of any kind.
- Mid-call at 18:07:35 I had NR re-added + PhysicalChannelConfig changed +
a RIL anomaly logged, and the earpiece did NOT fail. That's a direct
counter-example inside the same call that later failed.
I also checked the radio anomalies people tend to quote. They're real:
RILJ: Invalid PhysicalChannelConfig
java.lang.IllegalArgumentException: Physical cell ID 65535 is over limit
AnomalyReporter: RIL reported invalid PCC (AIDL) (21 occurrences)
"Unsupported band type" / "Unsupported unknown band" (519 occurrences)
PCI 65535 (0xFFFF) is an invalid sentinel, so the modem is genuinely
reporting garbage and that's worth reporting on its own. But all 21
Invalid PhysicalChannelConfig events land at call setup/teardown INCLUDING
on healthy calls, and also with no call active at all. NONE falls inside
either failure window. The band warnings are continuous background noise.
Unhealthy modem stack, yes. Trigger for this bug, the data says no.
One more caution: in my first failure, the RIL anomaly and the EN-DC burst
appear 60-70 ms AFTER I took the phone from my ear. Taking the phone away
turns the screen on, which triggers a network state refresh. So radio
events cluster at the moment you react to the failure BECAUSE you react.
That's a confound worth avoiding in this thread.
Your controlled result — fails every call on 5G, never on 3G/4G — is much
stronger evidence than anything I can extract retrospectively. I'm going to
replicate it before drawing conclusions, and I'd suggest we make that the
thread's focus.
--------------------------------------------------------------------
PRE-EMPTING THE "CUSTOM ROM" OBJECTION
--------------------------------------------------------------------
I'm on xiaomi.eu with an unlocked bootloader and NO root at all — no su
binary on the device. You're on Magisk. Different unlock method, different
root state, identical bug. Root is not a factor.
More importantly, xiaomi.eu only rebuilds system and system_ext. On my
device the vendor and odm partitions carry the untouched stock fingerprint:
vendor -> Xiaomi/popsicle/popsicle:16/BQ2A.250705.001-BP2A.250605.031.A3/
OS3.0.318.0.WPBCNXM:user/release-keys
vendor build date: Tue Aug 4 15:26:59 CST 2026
The audio HAL and the Qualcomm voice path live there:
/vendor/lib64/hw/audio.primary.default.so, AHAL_Module_QTI,
AHAL_Telephony_QTI, AHAL_Telephony_MI.
Combined with the log evidence that the framework layer behaves identically
in working and failing calls, the failure sits in stock, signed, unmodified
Xiaomi vendor code. The ROM I'm running does not touch it.
--------------------------------------------------------------------
TWO QUESTIONS
--------------------------------------------------------------------
1) Which ROM exactly are you on — official Chinese, or xiaomi.eu? You wrote
"Chinese ROM" and it matters a lot. If you're on the official ROM, that
closes the loop: same vendor blobs, two different ROMs, same bug, and
nobody can wave this away as a modding artefact.
It also matters practically. My bootloader is unlocked, so Service &
Feedback discards my reports before a human sees them. If you're on the
official ROM, yours actually enter Xiaomi's pipeline — and I'd gladly
hand you my full write-up and raw logs to attach.
2) Has anyone here run the A/B properly? Several long calls locked to
LTE-only, then the same on 5G, changing nothing else. That single test
settles the EN-DC question either way and costs nothing. One confirmed
failure while forced to 4G kills the theory outright.
--------------------------------------------------------------------
IF YOU WANT TO CONTRIBUTE DATA
--------------------------------------------------------------------
adb shell "setprop persist.log.tag.AHAL VERBOSE; \
setprop persist.log.tag.APM_AudioPolicyManager VERBOSE; \
setprop persist.log.tag.AudioFlinger DEBUG"
adb logcat -G 64M # re-run after every reboot, persist.logd.size is
# SELinux-denied on this device
# after a failure, within ~30 minutes:
adb logcat -b all -d > fail.txt
# and if you're still in the call:
adb shell dumpsys audio > fail_audio.txt
Grep markers: audioReceiverState, AHAL_Telephony_QTI, setCommunicationDevice,
updateCallRoutingInternal, Entering audio route.
The single most diagnostic line is audioReceiverState. If it reads 1
throughout a period when you hear nothing, the failure is below the HAL and
everything above is behaving normally.
Full write-up with all timestamps attached.