From 1fa67b3842d4bda8ec2c27dedc231f462f6d105f Mon Sep 17 00:00:00 2001 From: Aleksander Morgado Date: Fri, 16 Sep 2022 10:07:25 +0000 Subject: iface-modem-3gpp: allow applying domain registration updates altogether When processing QMI and MBIM messages to report domain registration updates, we should do that altogether so that we don't report bogus transitions to idle if the registration state switches from one domain to another. Fixes https://gitlab.freedesktop.org/mobile-broadband/ModemManager/-/issues/629 --- src/mm-iface-modem-3gpp.h | 29 ++++++++++++++++++++--------- 1 file changed, 20 insertions(+), 9 deletions(-) (limited to 'src/mm-iface-modem-3gpp.h') diff --git a/src/mm-iface-modem-3gpp.h b/src/mm-iface-modem-3gpp.h index ae380611..08ef956e 100644 --- a/src/mm-iface-modem-3gpp.h +++ b/src/mm-iface-modem-3gpp.h @@ -321,16 +321,27 @@ void mm_iface_modem_3gpp_shutdown (MMIfaceModem3gpp *self); /* Objects implementing this interface can report new registration info, * access technologies and location. + * * This may happen when handling unsolicited registration messages, or when - * the interface asks to run registration state checks. */ -void mm_iface_modem_3gpp_update_cs_registration_state (MMIfaceModem3gpp *self, - MMModem3gppRegistrationState state); -void mm_iface_modem_3gpp_update_ps_registration_state (MMIfaceModem3gpp *self, - MMModem3gppRegistrationState state); -void mm_iface_modem_3gpp_update_eps_registration_state (MMIfaceModem3gpp *self, - MMModem3gppRegistrationState state); -void mm_iface_modem_3gpp_update_5gs_registration_state (MMIfaceModem3gpp *self, - MMModem3gppRegistrationState state); + * the interface asks to run registration state checks. + * + * The registration updates may be "deferred" so that they are applied all at + * the same time. + */ +void mm_iface_modem_3gpp_update_cs_registration_state (MMIfaceModem3gpp *self, + MMModem3gppRegistrationState state, + gboolean deferred); +void mm_iface_modem_3gpp_update_ps_registration_state (MMIfaceModem3gpp *self, + MMModem3gppRegistrationState state, + gboolean deferred); +void mm_iface_modem_3gpp_update_eps_registration_state (MMIfaceModem3gpp *self, + MMModem3gppRegistrationState state, + gboolean deferred); +void mm_iface_modem_3gpp_update_5gs_registration_state (MMIfaceModem3gpp *self, + MMModem3gppRegistrationState state, + gboolean deferred); +void mm_iface_modem_3gpp_apply_deferred_registration_state (MMIfaceModem3gpp *self); + void mm_iface_modem_3gpp_update_subscription_state (MMIfaceModem3gpp *self, MMModem3gppSubscriptionState state); void mm_iface_modem_3gpp_update_access_technologies (MMIfaceModem3gpp *self, -- cgit v1.2.3-70-g09d2