netdev.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH net-next] qmi_wwan: set FLAG_SEND_ZLP to avoid network initiated disconnect
@ 2017-12-14 18:55 Bjørn Mork
  2017-12-14 21:39 ` Vamsi Samavedam
       [not found] ` <20171214185550.15779-1-bjorn-yOkvZcmFvRU@public.gmane.org>
  0 siblings, 2 replies; 4+ messages in thread
From: Bjørn Mork @ 2017-12-14 18:55 UTC (permalink / raw)
  To: netdev; +Cc: linux-usb, Bjørn Mork

It has been reported that the dummy byte we add to avoid
ZLPs can be forwarded by the modem to the PGW/GGSN, and that
some operators will drop the connection if this happens.

In theory, QMI devices are based on CDC ECM and should as such
both support ZLPs and silently ignore the dummy byte.  The latter
assumption failed.  Let's test out the first.

Signed-off-by: Bjørn Mork <bjorn@mork.no>
---
I am a bit worried about the effect of this change on all the
devices I can't test myself. But trying it is the only way we
can ever find out....


 drivers/net/usb/qmi_wwan.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/drivers/net/usb/qmi_wwan.c b/drivers/net/usb/qmi_wwan.c
index 304ec6555cd8..1ed00519f29e 100644
--- a/drivers/net/usb/qmi_wwan.c
+++ b/drivers/net/usb/qmi_wwan.c
@@ -826,7 +826,7 @@ static int qmi_wwan_resume(struct usb_interface *intf)
 
 static const struct driver_info	qmi_wwan_info = {
 	.description	= "WWAN/QMI device",
-	.flags		= FLAG_WWAN,
+	.flags		= FLAG_WWAN | FLAG_SEND_ZLP,
 	.bind		= qmi_wwan_bind,
 	.unbind		= qmi_wwan_unbind,
 	.manage_power	= qmi_wwan_manage_power,
@@ -835,7 +835,7 @@ static const struct driver_info	qmi_wwan_info = {
 
 static const struct driver_info	qmi_wwan_info_quirk_dtr = {
 	.description	= "WWAN/QMI device",
-	.flags		= FLAG_WWAN,
+	.flags		= FLAG_WWAN | FLAG_SEND_ZLP,
 	.bind		= qmi_wwan_bind,
 	.unbind		= qmi_wwan_unbind,
 	.manage_power	= qmi_wwan_manage_power,
-- 
2.11.0

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

* Re: [PATCH net-next] qmi_wwan: set FLAG_SEND_ZLP to avoid network initiated disconnect
  2017-12-14 18:55 [PATCH net-next] qmi_wwan: set FLAG_SEND_ZLP to avoid network initiated disconnect Bjørn Mork
@ 2017-12-14 21:39 ` Vamsi Samavedam
  2017-12-14 21:42   ` Bjørn Mork
       [not found] ` <20171214185550.15779-1-bjorn-yOkvZcmFvRU@public.gmane.org>
  1 sibling, 1 reply; 4+ messages in thread
From: Vamsi Samavedam @ 2017-12-14 21:39 UTC (permalink / raw)
  To: Bjørn Mork; +Cc: netdev, linux-usb

On Thu, Dec 14, 2017 at 07:55:50PM +0100, Bjørn Mork wrote:
> It has been reported that the dummy byte we add to avoid
> ZLPs can be forwarded by the modem to the PGW/GGSN, and that
> some operators will drop the connection if this happens.
> 
> In theory, QMI devices are based on CDC ECM and should as such
> both support ZLPs and silently ignore the dummy byte.  The latter
> assumption failed.  Let's test out the first.
> 
> Signed-off-by: Bjørn Mork <bjorn@mork.no>
> ---
> I am a bit worried about the effect of this change on all the
> devices I can't test myself. But trying it is the only way we
> can ever find out....

flag zlp is tested with pids: 9034,9048,904c,9075, 908E,9079,
908A,909F and 90A4. In general, qualcomm usb firmware can
handle zlps.

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

* Re: [PATCH net-next] qmi_wwan: set FLAG_SEND_ZLP to avoid network initiated disconnect
  2017-12-14 21:39 ` Vamsi Samavedam
@ 2017-12-14 21:42   ` Bjørn Mork
  0 siblings, 0 replies; 4+ messages in thread
From: Bjørn Mork @ 2017-12-14 21:42 UTC (permalink / raw)
  To: Vamsi Samavedam; +Cc: netdev, linux-usb

Vamsi Samavedam <vskrishn@codeaurora.org> writes:

> On Thu, Dec 14, 2017 at 07:55:50PM +0100, Bjørn Mork wrote:
>> It has been reported that the dummy byte we add to avoid
>> ZLPs can be forwarded by the modem to the PGW/GGSN, and that
>> some operators will drop the connection if this happens.
>> 
>> In theory, QMI devices are based on CDC ECM and should as such
>> both support ZLPs and silently ignore the dummy byte.  The latter
>> assumption failed.  Let's test out the first.
>> 
>> Signed-off-by: Bjørn Mork <bjorn@mork.no>
>> ---
>> I am a bit worried about the effect of this change on all the
>> devices I can't test myself. But trying it is the only way we
>> can ever find out....
>
> flag zlp is tested with pids: 9034,9048,904c,9075, 908E,9079,
> 908A,909F and 90A4. In general, qualcomm usb firmware can
> handle zlps.

Thanks.  That's very good to know.


Bjørn

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

* Re: [PATCH net-next] qmi_wwan: set FLAG_SEND_ZLP to avoid network initiated disconnect
       [not found] ` <20171214185550.15779-1-bjorn-yOkvZcmFvRU@public.gmane.org>
@ 2017-12-15 18:50   ` David Miller
  0 siblings, 0 replies; 4+ messages in thread
From: David Miller @ 2017-12-15 18:50 UTC (permalink / raw)
  To: bjorn-yOkvZcmFvRU
  Cc: netdev-u79uwXL29TY76Z2rM5mHXA, linux-usb-u79uwXL29TY76Z2rM5mHXA

From: Bjørn Mork <bjorn-yOkvZcmFvRU@public.gmane.org>
Date: Thu, 14 Dec 2017 19:55:50 +0100

> It has been reported that the dummy byte we add to avoid
> ZLPs can be forwarded by the modem to the PGW/GGSN, and that
> some operators will drop the connection if this happens.
> 
> In theory, QMI devices are based on CDC ECM and should as such
> both support ZLPs and silently ignore the dummy byte.  The latter
> assumption failed.  Let's test out the first.
> 
> Signed-off-by: Bjørn Mork <bjorn-yOkvZcmFvRU@public.gmane.org>
> ---
> I am a bit worried about the effect of this change on all the
> devices I can't test myself. But trying it is the only way we
> can ever find out....

:-)  Applied to net-next, thanks.
--
To unsubscribe from this list: send the line "unsubscribe linux-usb" in
the body of a message to majordomo-u79uwXL29TY76Z2rM5mHXA@public.gmane.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

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

end of thread, other threads:[~2017-12-15 18:50 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2017-12-14 18:55 [PATCH net-next] qmi_wwan: set FLAG_SEND_ZLP to avoid network initiated disconnect Bjørn Mork
2017-12-14 21:39 ` Vamsi Samavedam
2017-12-14 21:42   ` Bjørn Mork
     [not found] ` <20171214185550.15779-1-bjorn-yOkvZcmFvRU@public.gmane.org>
2017-12-15 18:50   ` David Miller

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).