mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Felipe Balbi <felipe.balbi@nokia.com>
To: "Balbi Felipe (Nokia-D/Helsinki)" <felipe.balbi@nokia.com>
Cc: ext Alan Cox <alan@lxorguk.ukuu.org.uk>,
	Linux Kernel Mailing List <linux-kernel@vger.kernel.org>,
	"dbrownell@users.sourceforge.net"
	<dbrownell@users.sourceforge.net>
Subject: Re: TTY loosing bytes ?
Date: Tue, 6 Oct 2009 16:55:18 +0300	[thread overview]
Message-ID: <20091006135518.GB4452@nokia.com> (raw)
In-Reply-To: <20091006134209.GA4452@nokia.com>

On Tue, Oct 06, 2009 at 03:42:09PM +0200, Balbi Felipe (Nokia-D/Helsinki) wrote:
> On Tue, Oct 06, 2009 at 03:40:12PM +0200, ext Alan Cox wrote:
> > > unfortunately it didn't work. Although now I don't the debugging prints
> > > complaining we've lost bytes, the transfer does get stuck in lot earlier
> > > stage.
> > > 
> > > Maybe this is one fix but there's still other problem with that code ?
> > 
> > Or with completely unrelated code. I guess you need to measure what goes
> > into receive_buf versus what appears in userspace
> 
> will do it soonish. Thanks Alan, I'll return to you when I have more
> debugging.

ok, here we are. For some reason the host side seems that it just
stopped sending data to us:

> [  177.413879]    37    37    37: read for 3 bytes
> [  177.413909]    37    37    37: read actually 3 bytes (total 3)
> [  177.413940]    37    37    37: read for 34 bytes
> [  177.413940]    37    37    37: read actually 34 bytes (total 37)
> [  177.414916]    37    37    37: write
> [  177.416992]    40    40    40: read for 3 bytes
> [  177.417022]    40    40    40: read actually 3 bytes (total 3)
> [  177.417053]    40    40    40: read for 37 bytes
> [  177.417053]    40    40    40: read actually 37 bytes (total 40)
> [  178.115966]    40    40    40: write
> [  178.116058]     0     0     0: write
> [  178.175689]    19    19    19: read for 3 bytes
> [  178.175720]    19    19    19: read actually 3 bytes (total 3)
> [  178.175750]    19    19    19: read for 16 bytes
> [  178.175781]    19    19    19: read actually 16 bytes (total 19)
> [  178.175842]    19    19    19: write
> [  180.784820] musb_hdrc periph: enabled ep1out for bulk OUT, maxpacket 512
> [  180.784851] musb_hdrc periph: enabled ep1in for bulk IN, maxpacket 512
> [  180.848358] musb_hdrc periph: enabled ep1out for bulk OUT, maxpacket 512
> [  180.848388] musb_hdrc periph: enabled ep1in for bulk IN, maxpacket 512
> [  186.659851] musb_hdrc periph: enabled ep2in for bulk IN, maxpacket 512
> [  186.659912] musb_hdrc periph: enabled ep2out for bulk OUT, maxpacket 512
> [  186.723907] musb_hdrc periph: enabled ep2in for bulk IN, maxpacket 512
> [  186.723937] musb_hdrc periph: enabled ep2out for bulk OUT, maxpacket 512
> [  186.848602]    37    37    37: read for 3 bytes
> [  186.848632]    37    37    37: read actually 3 bytes (total 3)
> [  186.848663]    37    37    37: read for 34 bytes
> [  186.848663]    37    37    37: read actually 34 bytes (total 37)
> [  186.849182]    37    37    37: write
> [  186.852539]    40    40    40: read for 3 bytes
> [  186.852569]    40    40    40: read actually 3 bytes (total 3)
> [  186.852600]    40    40    40: read for 37 bytes
> [  186.852630]    40    40    40: read actually 37 bytes (total 40)
> [  187.435577]    40    40    40: write
> [  187.435699]     0     0     0: write
> [  187.644683]    47    47    47: read for 3 bytes
> [  187.644714]    47    47    47: read actually 3 bytes (total 3)
> [  187.644744]    47    47    47: read for 44 bytes
> [  187.644775]    47    47    47: read actually 44 bytes (total 47)
> [  187.648620]    47    47    47: write
> [  192.939239]    24    24    24: read for 3 bytes
> [  192.939300]    24    24    24: read actually 3 bytes (total 3)
> [  192.939300]    24    24    24: read for 21 bytes
> [  192.939331]    24    24    24: read actually 21 bytes (total 24)
> [  192.939453]    24    24    24: write
> [  192.940246]    34    34    34: read for 3 bytes
> [  192.940246]    34    34    34: read actually 3 bytes (total 3)
> [  192.940277]    34    34    34: read for 31 bytes
> [  192.940307]    34    34    34: read actually 31 bytes (total 34)
> [  192.943206]    34    34    34: write
> [  192.944152]    34    34    34: read for 3 bytes
> [  192.944183]    34    34    34: read actually 3 bytes (total 3)
> [  192.944213]    34    34    34: read for 31 bytes
> [  192.944213]    34    34    34: read actually 31 bytes (total 34)
> [  192.944488]    34    34    34: write
> [  192.945373]    47    47    47: read for 3 bytes
> [  192.945373]    47    47    47: read actually 3 bytes (total 3)
> [  192.945404]    47    47    47: read for 44 bytes
> [  192.945434]    47    47    47: read actually 44 bytes (total 47)
> [  192.946594]    47    47    47: write
> [  192.981689]  6656  4096  3832: read for 3 bytes
> [  192.981750]  7168  4096  3832: read actually 3 bytes (total 3)
> [  192.981811]  7680  4096  3832: read for 65532 bytes
> [  192.982177] 11264 11264  3832: read actually 3829 bytes (total 3832)

this is weird. Why didn't we get more data ? Where's the rest of this
block ??

> [  194.410125] musb_hdrc periph: enabled ep3in for bulk IN, maxpacket 512
> [  194.410156] musb_hdrc periph: enabled ep3out for bulk OUT, maxpacket 512
> [  194.474456] musb_hdrc periph: enabled ep3in for bulk IN, maxpacket 512
> [  194.474487] musb_hdrc periph: enabled ep3out for bulk OUT, maxpacket 512
> [  200.706115] 65556 65556  3853: read for 3 bytes
> [  200.706176] 65556 65556  3853: read actually 3 bytes (total 3835)
> [  200.706207] 65556 65556  3853: read for 18 bytes
> [  200.706207] 65556 65556  3853: read actually 18 bytes (total 3853)
> [  200.706542] 65556 65556  3853: write

I'll add more messages to be sure what's going on.

-- 
balbi

      reply	other threads:[~2009-10-06 13:59 UTC|newest]

Thread overview: 9+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2009-10-06  9:48 Felipe Balbi
2009-10-06 11:45 ` Felipe Balbi
2009-10-06 12:12   ` Alan Cox
2009-10-06 13:01     ` Felipe Balbi
2009-10-06 13:11       ` Alan Cox
2009-10-06 13:27         ` Felipe Balbi
2009-10-06 13:40           ` Alan Cox
2009-10-06 13:42             ` Felipe Balbi
2009-10-06 13:55               ` Felipe Balbi [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20091006135518.GB4452@nokia.com \
    --to=felipe.balbi@nokia.com \
    --cc=alan@lxorguk.ukuu.org.uk \
    --cc=dbrownell@users.sourceforge.net \
    --cc=linux-kernel@vger.kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox

Powered by JetHome