Open Source Telephony
 help / color / mirror / Atom feed
* [PATCH 1/2] gobi: Use LOW_POWER instead of PERSIST_LOW_POWER
@ 2024-04-30 17:37 Denis Kenzior
  2024-04-30 17:37 ` [PATCH 2/2] udevng: Add support for Telit FN990 Denis Kenzior
  2024-05-01 21:00 ` [PATCH 1/2] gobi: Use LOW_POWER instead of PERSIST_LOW_POWER patchwork-bot+ofono
  0 siblings, 2 replies; 3+ messages in thread
From: Denis Kenzior @ 2024-04-30 17:37 UTC (permalink / raw)
  To: ofono; +Cc: Denis Kenzior

PERSIST_LOW_POWER setting is supposed to tell the device that it should
not enter online state at the next bootup.  Unfortunately, no USB
devices tested seem to honor this setting.

Telit devices in particular will turn off the SIM and become unusable
until set back into online mode.  Use low-power instead of persistent
low power state instead.  AlwaysOnline support is now no longer needed.
---
 plugins/gobi.c   | 4 ++--
 plugins/udevng.c | 1 -
 2 files changed, 2 insertions(+), 3 deletions(-)

diff --git a/plugins/gobi.c b/plugins/gobi.c
index 550ce78733f5..39c1ab81fa56 100644
--- a/plugins/gobi.c
+++ b/plugins/gobi.c
@@ -226,7 +226,7 @@ static void get_oper_mode_cb(struct qmi_result *result, void *user_data)
 	switch (data->oper_mode) {
 	case QMI_DMS_OPER_MODE_ONLINE:
 		param = qmi_param_new_uint8(QMI_DMS_PARAM_OPER_MODE,
-					QMI_DMS_OPER_MODE_PERSIST_LOW_POWER);
+					QMI_DMS_OPER_MODE_LOW_POWER);
 		if (!param) {
 			shutdown_device(modem);
 			return;
@@ -480,7 +480,7 @@ static int gobi_disable(struct ofono_modem *modem)
 		goto out;
 
 	param = qmi_param_new_uint8(QMI_DMS_PARAM_OPER_MODE,
-					QMI_DMS_OPER_MODE_PERSIST_LOW_POWER);
+					QMI_DMS_OPER_MODE_LOW_POWER);
 	if (!param)
 		return -ENOMEM;
 
diff --git a/plugins/udevng.c b/plugins/udevng.c
index b9d115f16b7d..243dcd6e91ec 100644
--- a/plugins/udevng.c
+++ b/plugins/udevng.c
@@ -850,7 +850,6 @@ static gboolean setup_telitqmi(struct modem_info *modem)
 		return FALSE;
 
 	ofono_modem_set_boolean(modem->modem, "ForceSimLegacy", TRUE);
-	ofono_modem_set_boolean(modem->modem, "AlwaysOnline", TRUE);
 
 	return TRUE;
 }
-- 
2.44.0


^ permalink raw reply related	[flat|nested] 3+ messages in thread

* [PATCH 2/2] udevng: Add support for Telit FN990
  2024-04-30 17:37 [PATCH 1/2] gobi: Use LOW_POWER instead of PERSIST_LOW_POWER Denis Kenzior
@ 2024-04-30 17:37 ` Denis Kenzior
  2024-05-01 21:00 ` [PATCH 1/2] gobi: Use LOW_POWER instead of PERSIST_LOW_POWER patchwork-bot+ofono
  1 sibling, 0 replies; 3+ messages in thread
From: Denis Kenzior @ 2024-04-30 17:37 UTC (permalink / raw)
  To: ofono; +Cc: Denis Kenzior

---
 plugins/udevng.c | 8 ++++++--
 1 file changed, 6 insertions(+), 2 deletions(-)

diff --git a/plugins/udevng.c b/plugins/udevng.c
index 243dcd6e91ec..83e8f3e98a22 100644
--- a/plugins/udevng.c
+++ b/plugins/udevng.c
@@ -834,7 +834,8 @@ static gboolean setup_telitqmi(struct modem_info *modem)
 		DBG("%s %s %s %s %s", info->devnode, info->interface,
 				info->number, info->label, subsystem);
 
-		if (g_strcmp0(info->interface, "255/255/255") == 0 &&
+		if ((!g_strcmp0(info->interface, "255/255/255") ||
+				!g_strcmp0(info->interface, "255/255/80")) &&
 				g_strcmp0(info->number, "02") == 0) {
 			if (g_strcmp0(subsystem, "net") == 0)
 				net = info;
@@ -849,7 +850,8 @@ static gboolean setup_telitqmi(struct modem_info *modem)
 	if (setup_qmi(modem, qmi, net) < 0)
 		return FALSE;
 
-	ofono_modem_set_boolean(modem->modem, "ForceSimLegacy", TRUE);
+	if (g_strcmp0(modem->model, "1070"))
+		ofono_modem_set_boolean(modem->modem, "ForceSimLegacy", TRUE);
 
 	return TRUE;
 }
@@ -2037,6 +2039,8 @@ static struct {
 	{ "telit",	"cdc_acm",	"1bc7", "0021"	},
 	{ "telitqmi",	"qmi_wwan",	"1bc7", "1201"	},
 	{ "telitqmi",	"option",	"1bc7", "1201"	},
+	{ "telitqmi",	"qmi_wwan",	"1bc7", "1070"	},
+	{ "telitqmi",	"option",	"1bc7", "1070"	},
 	{ "droid",	"qmi_wwan",	"22b8", "2a70"	},
 	{ "droid",	"option",	"22b8", "2a70"	},
 	{ "nokia",	"option",	"0421", "060e"	},
-- 
2.44.0


^ permalink raw reply related	[flat|nested] 3+ messages in thread

* Re: [PATCH 1/2] gobi: Use LOW_POWER instead of PERSIST_LOW_POWER
  2024-04-30 17:37 [PATCH 1/2] gobi: Use LOW_POWER instead of PERSIST_LOW_POWER Denis Kenzior
  2024-04-30 17:37 ` [PATCH 2/2] udevng: Add support for Telit FN990 Denis Kenzior
@ 2024-05-01 21:00 ` patchwork-bot+ofono
  1 sibling, 0 replies; 3+ messages in thread
From: patchwork-bot+ofono @ 2024-05-01 21:00 UTC (permalink / raw)
  To: Denis Kenzior; +Cc: ofono

Hello:

This series was applied to ofono.git (master)
by Denis Kenzior <denkenz@gmail.com>:

On Tue, 30 Apr 2024 12:37:34 -0500 you wrote:
> PERSIST_LOW_POWER setting is supposed to tell the device that it should
> not enter online state at the next bootup.  Unfortunately, no USB
> devices tested seem to honor this setting.
> 
> Telit devices in particular will turn off the SIM and become unusable
> until set back into online mode.  Use low-power instead of persistent
> low power state instead.  AlwaysOnline support is now no longer needed.
> 
> [...]

Here is the summary with links:
  - [1/2] gobi: Use LOW_POWER instead of PERSIST_LOW_POWER
    https://git.kernel.org/pub/scm/network/ofono/ofono.git/?id=75ba0c33e3e3
  - [2/2] udevng: Add support for Telit FN990
    https://git.kernel.org/pub/scm/network/ofono/ofono.git/?id=e41785fbd397

You are awesome, thank you!
-- 
Deet-doot-dot, I am a bot.
https://korg.docs.kernel.org/patchwork/pwbot.html



^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2024-05-01 21:00 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2024-04-30 17:37 [PATCH 1/2] gobi: Use LOW_POWER instead of PERSIST_LOW_POWER Denis Kenzior
2024-04-30 17:37 ` [PATCH 2/2] udevng: Add support for Telit FN990 Denis Kenzior
2024-05-01 21:00 ` [PATCH 1/2] gobi: Use LOW_POWER instead of PERSIST_LOW_POWER patchwork-bot+ofono

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox