Linux USB
 help / color / mirror / Atom feed
From: sashiko-bot@kernel.org
To: "Mehmet Fide" <mehmet.fide@gmail.com>
Cc: linux-usb@vger.kernel.org
Subject: Re: [PATCH v2 2/2] usb: gadget: u_serial: implement flush_buffer
Date: Mon, 19 Oct 2026 09:15:22 +0000	[thread overview]
Message-ID: <sashiko-outbox-176883@kernel.org> (raw)
In-Reply-To: <20261019090904.3264978-2-mehmet.fide@gmail.com>

> From: Mehmet Fide <mehmet.fide@screeningeagle.com>
> 
> gs_close() waits up to GS_CLOSE_TIMEOUT (15 s) for the write buffer
> to drain while the gadget is connected. When the host does not read
> the port, for example because no application on the host has it open,
> the last close blocks for the full timeout. tcflush(TCOFLUSH) cannot
> avoid that: u_serial has no flush_buffer operation, so the request is
> a no-op.
> 
> Implement flush_buffer: discard the buffered output under the port
> lock and wake up the close and write waiters. As on other tty drivers,
> a hangup and an interrupt character (ISIG without NOFLSH) now discard
> the pending output as well.
> 
> Signed-off-by: Mehmet Fide <mehmet.fide@screeningeagle.com>

Sashiko has reviewed this patch and found no issues.

-- 
Sashiko AI review · https://sashiko.dev/#/patchset/20261019085855.3259716-1-mehmet.fide@gmail.com?part=2


      reply	other threads:[~2026-10-19  9:15 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-10-19  8:58 [PATCH v2 0/2] usb: gadget: u_serial: flush_buffer, and keep the port for its tty Mehmet Fide
2026-10-19  9:09 ` [PATCH v2 1/2] usb: gadget: u_serial: keep the port until its tty is released Mehmet Fide
2026-10-19  9:23   ` sashiko-bot
2026-10-19  9:09 ` [PATCH v2 2/2] usb: gadget: u_serial: implement flush_buffer Mehmet Fide
2026-10-19  9:15   ` sashiko-bot [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=sashiko-outbox-176883@kernel.org \
    --to=sashiko-bot@kernel.org \
    --cc=linux-usb@vger.kernel.org \
    --cc=mehmet.fide@gmail.com \
    --cc=sashiko-reviews@lists.linux.dev \
    /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