Track port-s open/close and peer RST, switch P-CSCF with a full security
agreement teardown after Vodafone UK early resets, and keep only one
native VoLTE start in flight per device.
Native VoLTE still has the operator default 3gnet bearer for LTE
attach; that cannot be CGACT-deactivated. Hideck must not use it as
usbnet. Always flush/down the data iface when NetworkEnabled is
false, including after IMS PDN comes up.
SIM swap can leave qmi_wwan/qmi-proxy holding a dead cdc-wdm
session while AT still works. Recovery then kept allocating CTL
clients on that wedged port. Prefer AT IMEI during rescan, skip
startup UIM reset when the card is already ready, and if CTL
allocate times out twice with AT alive, USB-reset only that modem.
QMI DMS allocate timeout after SIM swap was tearing down the worker
because identity refresh only used QMI and recovery treated empty
identity as half-ready. Leave the worker running while StartCore
retries, and read IMSI/ICCID from the AT port so card policy can
apply without a CFUN reboot.
Modem reboot leaves the proxy socket dead while NAS reconcile stays
in flight, so health checks never reopen QMI. Treat that broken pipe
as transport-down, keep AT VoLTE when IMS client allocate fails, and
fall back to AT+CNUM for the local number.
Map QMI disconnecting and early CANCEL/BYE to a missed call, and use standalone titles so WeCom, QQ, Feishu, and other channels no longer stack 通话结束.
Co-authored-by: Cursor <cursoragent@cursor.com>
When a Lebara UK eSIM flips to 20404, reset the same ICCID with Disable/Enable or a parking profile, wait for a stable 23487 IMSI, then start VoWiFi. Keep the RF lock. Do not start VoWiFi during recover or on classify-failure for unrelated cards.
Native HoldCall/ResumeCall were stubs. Send VOICE_MANAGE_CALLS
HOLD_ACTIVE_ACCEPT_WAITING_OR_HELD, then local hold/unhold if the
modem rejects the network supplementary service.
DJI/Baiwang USB audio enumerates but opening PCM kills QMI on the
same composite. Skip QPCMV and ALSA there; QPCMV failure also skips
PCM open. Working UAC is unchanged. China MCC 460/461 force native
VoLTE. Rebuild QMI when the proxy socket dies during a native call.
Why: a transient AT/QMI timeout aborted native IMS provision, and QMI LTE placeholder RSSI made the overview look like there was no signal.
Why this works: native VoLTE start retries timeout-class errors, serializes AT on one port, and the overview uses RSRP when RSSI is a sentinel. Shutdown now takes the stop context so IMS can finish Contact Expires=0.
Remaining: Lebara UK RF-lock and unique-MBN failures stay non-retryable.
Why: a one-shot 5s SMSC read left later starts empty, and Darwin qmi-proxy errors hid a successful IMEI rebind.
Why this works: start retries the read, remembers the last IMSI/ICCID SMSC, and the bootstrap test accepts proxy-unsupported as a rebound start failure.
Remaining: preset SMSC fallback is still not a carrier-plan field.
/send, automatic tasks, and the balance gateway now use SendRoutedSMS.
A VoWiFi failure falls back to CS once; it does not also send on IMS.
Notify /status shows MWI, and vocall hold from notify stays skipped.
Keep the latest RFC 3842 snapshot on the pool, attach it to device
runtime JSON, and clear it when VoWiFi is disabled. Call-waiting
notify is forwarded from the same dispatcher.
Default Wi-Fi calling was skipping bind-time RFOff and treating QMI LowPower as airplane, so the modem could camp after restart. Persist the flight mode and uncamp if NAS comes back while radio is suppressed.
Co-authored-by: Cursor <cursoragent@cursor.com>
Subscribe to MWI, accept in-dialog REFER and call waiting, and advertise
preconditions plus identity headers without enabling emergency calls.
Co-authored-by: Cursor <cursoragent@cursor.com>
Register now advertises outbound, prefers Service-Route then Path, and
tears down RFC 3680 subscriptions in-dialog. Voice adds hold/resume and
RFC 4028 timers; SWu sends AKA' bidding, IKE fragmentation, redirect
limits, and a correctly coded AUTS. Host SMS gets SMMA backpressure and
CS fallback without double-send.
Co-authored-by: Cursor <cursoragent@cursor.com>
TS 24.341 5.3.2.6.2: REGISTER Contact includes +g.3gpp.smsip-msisdn-less so
future SIMs can use MSISDN-less SMS over IP.
TS 24.341 5.3.1.4.2: 488 when In-Reply-To is present and does not match a
submitted SM. Late reports still match the delivery store. RP-MR is not used
to steal another message when In-Reply-To is set.
IR.51: carrier profile now carries sos.epdg.epc.mncXXX.mccYYY.pub.3gppnetwork.org.
Ordinary VoWiFi IKE still uses the standard/custom ePDG.
Keep a single proxy child in the hideck cgroup, do not spawn another
when the socket is busy, and tear it down on shutdown so a restart
does not leave /dev/cdc-wdm busy.
Isochronous UAC traffic on the virtual xHCI stalls cdc-wdm writes.
Close ALSA with a 300ms budget before EndCall, ignore leftover EndCall
responses as indications, and skip QMI health eviction during the call
and for 20s after so wwan0 is not marked offline.
Identity probes were spending the rescan budget on GET_VERSION/sync,
so USB re-enumeration left configured modems with empty IMEI. Skip the
open handshake for DMS-only reads and retry IMEI on the same device AT
port when QMI fails.
Signaling used a silent PCM sink, so 10000 connected with no sound.
Open the USB-parent ALSA device during the call and do not claim UAC
ready until that card exists.
Why: after swapping CTE for a China SIM, QMI still reported inserted from the old snapshot, and GetIMSI failure blocked turning off airplane. Reboots could not enumerate the new card.
Why this works: IsSimInserted live-queries UIM when the snapshot has no IMSI/ICCID. Lebara RF lock still applies from cache or 23487 history; a UIM error without Lebara evidence no longer fail-closes flight-mode off. QSIMDET stays 0,0 and CFUN=1,1 is not automatic.
Remaining: physical SIM insert still has no UIM resample path; native VoLTE Enable is not on 179 yet.
Why: quality review found triplicate radio policy, untyped native_volte, duplicated mu-law, and IMS lifecycle buried in manager.go.
Why this works: camped modes share PhoneModeCampsOnCell and applyPhoneRadioPolicy; DeviceStatus.NativeVoLTE is volte.Status; PCM bridge calls phone G.711; IMS clients live in ims_clients.go. VoWiFiEnabled JSON/DB name is unchanged.
Remaining: live IMS/UAC still wait on a China VoLTE SIM; AudioRuntime stays unwired until helper audit; Enable half-applied rollback is not in this change.
udev no longer resets a 3s timer on every ttyUSB event. USB
rescan/rebuild sends RFOff before NAS search, then applies the
existing card policy. Process restart does not flight-cycle
already camped SIMs.
Subscribe to kernel uevents and rematch IMEI-only configs after unplug.
Abandon in-flight recovery on delete so the same ID can be added again.
Keep the add dialog on theme tokens and prefill the device ID.