All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH 1/3] droid 4: add special handling required for voice calls and SIM
@ 2020-09-15 13:23 Pavel Machek
  2020-09-15 15:19 ` Denis Kenzior
  0 siblings, 1 reply; 2+ messages in thread
From: Pavel Machek @ 2020-09-15 13:23 UTC (permalink / raw)
  To: ofono

[-- Attachment #1: Type: text/plain, Size: 1755 bytes --]

Droid 4 modem is "special" (aka broken) so it seems to need a bit of
error handling.
---
 drivers/atmodem/sim.c       | 1 +
 drivers/atmodem/vendor.h    | 1 +
 drivers/atmodem/voicecall.c | 4 ++++
 3 files changed, 6 insertions(+)

diff --git a/drivers/atmodem/sim.c b/drivers/atmodem/sim.c
index e750a139..f46cd3a2 100644
--- a/drivers/atmodem/sim.c
+++ b/drivers/atmodem/sim.c
@@ -199,6 +199,7 @@ static void at_sim_read_info(struct ofono_sim *sim, int fileid,
 	case OFONO_VENDOR_SPEEDUP:
 	case OFONO_VENDOR_QUALCOMM_MSM:
 	case OFONO_VENDOR_SIMCOM:
+	case OFONO_VENDOR_DROID:
 		/* Maximum possible length */
 		len += sprintf(buf + len, ",0,0,255");
 		break;
diff --git a/drivers/atmodem/vendor.h b/drivers/atmodem/vendor.h
index d839d1e0..2bfd3eb8 100644
--- a/drivers/atmodem/vendor.h
+++ b/drivers/atmodem/vendor.h
@@ -27,6 +27,7 @@ enum ofono_vendor {
 	OFONO_VENDOR_MBM,
 	OFONO_VENDOR_GOBI,
 	OFONO_VENDOR_QUALCOMM_MSM,
+	OFONO_VENDOR_DROID,
 	OFONO_VENDOR_OPTION_HSO,
 	OFONO_VENDOR_ZTE,
 	OFONO_VENDOR_HUAWEI,
diff --git a/drivers/atmodem/voicecall.c b/drivers/atmodem/voicecall.c
index 7ab6567f..6c80bd4e 100644
--- a/drivers/atmodem/voicecall.c
+++ b/drivers/atmodem/voicecall.c
@@ -160,6 +160,10 @@ static void clcc_poll_cb(gboolean ok, GAtResult *result, gpointer user_data)
 			poll_again = TRUE;
 			goto poll_again;
 		}
+		if (vd->vendor == OFONO_VENDOR_DROID) {
+			poll_again = TRUE;
+			goto poll_again;
+		}
 
 		ofono_error("We are polling CLCC and received an error");
 		ofono_error("All bets are off for call management");
-- 
2.11.0

-- 
(english) http://www.livejournal.com/~pavelmachek
(cesky, pictures) http://atrey.karlin.mff.cuni.cz/~pavel/picture/horses/blog.html

[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 195 bytes --]

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

* Re: [PATCH 1/3] droid 4: add special handling required for voice calls and SIM
  2020-09-15 13:23 [PATCH 1/3] droid 4: add special handling required for voice calls and SIM Pavel Machek
@ 2020-09-15 15:19 ` Denis Kenzior
  0 siblings, 0 replies; 2+ messages in thread
From: Denis Kenzior @ 2020-09-15 15:19 UTC (permalink / raw)
  To: ofono

[-- Attachment #1: Type: text/plain, Size: 826 bytes --]

Hi Pavel,

On 9/15/20 8:23 AM, Pavel Machek wrote:
> Droid 4 modem is "special" (aka broken) so it seems to need a bit of
> error handling.
> ---
>   drivers/atmodem/sim.c       | 1 +
>   drivers/atmodem/vendor.h    | 1 +
>   drivers/atmodem/voicecall.c | 4 ++++
>   3 files changed, 6 insertions(+)
> 

<snip>

> @@ -160,6 +160,10 @@ static void clcc_poll_cb(gboolean ok, GAtResult *result, gpointer user_data)
>   			poll_again = TRUE;
>   			goto poll_again;
>   		}

applied with an extra newline here to satisfy doc/coding-style.txt item M1.

> +		if (vd->vendor == OFONO_VENDOR_DROID) {
> +			poll_again = TRUE;
> +			goto poll_again;
> +		}
>   
>   		ofono_error("We are polling CLCC and received an error");
>   		ofono_error("All bets are off for call management");
> 

Regards,
-Denis

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

end of thread, other threads:[~2020-09-15 15:19 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2020-09-15 13:23 [PATCH 1/3] droid 4: add special handling required for voice calls and SIM Pavel Machek
2020-09-15 15:19 ` Denis Kenzior

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.