linux-usb.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Oliver Neukum <oneukum@suse.com>
To: Joakim Tjernlund <Joakim.Tjernlund@infinera.com>,
	"linux-usb@vger.kernel.org" <linux-usb@vger.kernel.org>
Subject: Re: ttyACM: disabled by hub (EMI?), re-enabling... Causes garbage chars & disconnect
Date: Mon, 08 Jun 2020 11:13:51 +0200	[thread overview]
Message-ID: <1591607631.24937.3.camel@suse.com> (raw)
In-Reply-To: <9971e8a97ea0f9d63864829fd8f2f4db897fc131.camel@infinera.com>

Am Freitag, den 05.06.2020, 10:09 +0000 schrieb Joakim Tjernlund:

> I can see that when I open the tty, a USB read is performed and then echoed back.
> Should an open really do that?

Yes. The tty interface does not pass read(2) down to the driver.

> If so, an flag to open(2), telling it to drop the input buffer would be really handy.

That actually looks like an unavoidable race condition to me.
How would you tell the difference between old data and newly
arriving data?

	Regards
		Oliver


  reply	other threads:[~2020-06-08  9:14 UTC|newest]

Thread overview: 22+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-05-25 14:46 ttyACM: disabled by hub (EMI?), re-enabling... Causes garbage chars & disconnect Joakim Tjernlund
2020-05-25 15:02 ` Oliver Neukum
2020-05-25 15:15   ` Joakim Tjernlund
2020-05-25 16:49     ` Joakim Tjernlund
2020-05-26  8:47       ` Oliver Neukum
2020-05-26  8:59         ` Joakim Tjernlund
2020-05-26 10:14           ` Oliver Neukum
2020-05-26 16:46             ` Joakim Tjernlund
2020-05-26 17:19               ` Joakim Tjernlund
2020-05-27  8:38                 ` Oliver Neukum
2020-05-27  9:40                   ` Joakim Tjernlund
2020-05-27 10:12                     ` Greg KH
2020-05-27 10:41                     ` Oliver Neukum
2020-05-27 13:16                       ` Joakim Tjernlund
2020-05-27 15:41                         ` Joakim Tjernlund
2020-06-05 10:09                           ` Joakim Tjernlund
2020-06-08  9:13                             ` Oliver Neukum [this message]
2020-06-08 11:39                               ` Joakim Tjernlund
2020-06-08 15:40                                 ` Oliver Neukum
2020-06-08 16:00                                   ` Joakim Tjernlund
2020-06-08 19:21                                     ` Oliver Neukum
2020-06-15 11:01           ` Joakim Tjernlund

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=1591607631.24937.3.camel@suse.com \
    --to=oneukum@suse.com \
    --cc=Joakim.Tjernlund@infinera.com \
    --cc=linux-usb@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;
as well as URLs for NNTP newsgroup(s).