Tarantool development patches archive
 help / color / mirror / Atom feed
From: Cyrill Gorcunov <gorcunov@gmail.com>
To: tml <tarantool-patches@dev.tarantool.org>
Subject: Re: [Tarantool-patches] [PATCH v2] fio/coio: Handle partial writes
Date: Wed, 4 Dec 2019 14:25:58 +0300	[thread overview]
Message-ID: <20191204112558.GL10140@uranus> (raw)
In-Reply-To: <20191204111749.22115-1-gorcunov@gmail.com>

On Wed, Dec 04, 2019 at 02:17:49PM +0300, Cyrill Gorcunov wrote:
...
> +static inline int
> +write_should_retry(void)
> +{
> +	/* Retry on O_NONBLOCK */
> +	if (errno == EAGAIN)
> +		return true;
> +	/* Retry if been interrupted */
> +	if (errno == EINTR)
> +		return true;
> +	/* Unexpected error */
> +	return false;
> +}

Guys, I just thought, previously if the file we're writting to
has been opened with o_nonblock and eagain happened we were
returning an error. With this patch we gonna retry write operation,
and this changes behaviour. Maybe I should consider EINTR only?

  reply	other threads:[~2019-12-04 11:26 UTC|newest]

Thread overview: 9+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2019-12-04 11:17 Cyrill Gorcunov
2019-12-04 11:25 ` Cyrill Gorcunov [this message]
2019-12-04 11:34 ` Konstantin Osipov
2019-12-04 11:48   ` Cyrill Gorcunov
2019-12-04 14:35 ` [Tarantool-patches] [PATCH v3] " Cyrill Gorcunov
2020-02-20 22:10   ` Alexander Turenko
2020-02-21 12:02     ` Cyrill Gorcunov
2020-02-21 14:48       ` Alexander Turenko
2020-06-10  9:53 [Tarantool-patches] [PATCH v2] fio/coio: handle " Cyrill Gorcunov

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=20191204112558.GL10140@uranus \
    --to=gorcunov@gmail.com \
    --cc=tarantool-patches@dev.tarantool.org \
    --subject='Re: [Tarantool-patches] [PATCH v2] fio/coio: Handle partial writes' \
    /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

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox