Hi Richard,
> attached, and connection managers (at least connman) start
> to hammer us to connect a context, eventhough it happens
> automatically in LTE.
What happens automatically? Yes, it is true that you need a default
context to attach to LTE. So activating a context is basically a part
of the LTE attach procedure.
But that default context does not need to be an internet context (e.g.
Verizon uses (or used to) use an ims context for this). So ConnMan
still
might need to activate an Internet context even if we're on LTE.
To do that wouldn't we need to be able to flag attached even without
registered context for LTE?
Or will the modem not attach to 4G until the context is configured?
I can not test that case with my modems.
It sort of depends on the configuration. But basically we will not get
on LTE without a default bearer. The default bearer configuration can
come from the modem itself, or actually from the network. That default
bearer is essentially an active context. This is why gprs.c goes to the
trouble of matching it against existing contexts, but if it isn't found,
then adds a new one (which is supposed to be transient/temporary).
Typically, on a well-configured system, you'll have the default bearer
setup via LongTermEvolution.DefaultAccessPointName and also provisioned
in the provisioning database. But as I mentioned earlier, the default
context doesn't have to be an internet one.
Regards,
-Denis
I'm also not sure that the heuristic of 0 active contexts means not
attached is a good one. Shouldn't you be using +CREG or +CEREG status
for this?
As you say that is probably more correct :)
First I wanted to get things running with the current solution which
uses an active
context as condition.
> ---
> src/gprs.c | 9 +++++----
> 1 file changed, 5 insertions(+), 4 deletions(-)
>
> diff --git a/src/gprs.c b/src/gprs.c
> index 94d13f82..cb31e2d2 100644
> --- a/src/gprs.c
> +++ b/src/gprs.c
> @@ -2738,11 +2738,12 @@ void
ofono_gprs_context_deactivated(struct ofono_gprs_context *gc,
> * If "Attached" property was about to be signalled as TRUE
but there
> * were still active contexts, try again to signal
"Attached" property
> * to registered applications after active contexts have
been released.
> + *
> + * ... or in the case of LTE where the attached state were
a registered
> + * context is a condition for being attached
> */
> - if (gc->gprs->flags & GPRS_FLAG_ATTACHED_UPDATE) {
> - gc->gprs->flags &= ~GPRS_FLAG_ATTACHED_UPDATE;
> - gprs_attached_update(gc->gprs);
> - }
> + gc->gprs->flags &= ~GPRS_FLAG_ATTACHED_UPDATE;
> + gprs_attached_update(gc->gprs);
> }
>
> int ofono_gprs_context_driver_register(
>
Regards,
-Denis
_______________________________________________
ofono mailing list
ofono@ofono.org
https://lists.ofono.org/mailman/listinfo/ofono