linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Bart Van Assche <bvanassche@acm.org>
To: Bodo Stroesser <bostroesser@gmail.com>, Christoph Hellwig <hch@lst.de>
Cc: Joel Becker <jlbec@evilplan.org>,
	linux-kernel@vger.kernel.org,
	"Martin K . Petersen" <martin.petersen@oracle.com>,
	Yanko Kaneti <yaneti@declera.com>,
	Brendan Higgins <brendanhiggins@google.com>
Subject: Re: [PATCH 2/4] configfs: Fix writing at a non-zero offset
Date: Mon, 26 Jul 2021 09:26:49 -0700	[thread overview]
Message-ID: <d12f24b6-7066-f9bb-1b88-6cc23c9c45c1@acm.org> (raw)
In-Reply-To: <7bee65ce-f5f1-a525-c72d-221b5d23cf3e@gmail.com>

On 7/26/21 7:58 AM, Bodo Stroesser wrote:
> On 23.07.21 23:23, Bart Van Assche wrote:
> Let's say user writes 5 times to configfs file while keeping it open.
> On every write() call it writes 1 character only, e.g. first "A", then 
> "B", ...
> 
> The original code before the changes 5 times called flush_write_buffer 
> for the
> strings "A\0", "B\0", ... (with the '\0' not included in the count 
> parameter,
> so count is 1 always, which is the length of the last write).

Isn't that behavior a severe violation of how POSIX specifies that the 
write() system call should be implemented?

Thanks,

Bart.

  reply	other threads:[~2021-07-26 16:38 UTC|newest]

Thread overview: 17+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-07-23 21:23 [PATCH 0/4] Improve the configfs read and write iterators further Bart Van Assche
2021-07-23 21:23 ` [PATCH 1/4] configfs: Rework the overflow check in fill_write_buffer() Bart Van Assche
2021-07-23 21:23 ` [PATCH 2/4] configfs: Fix writing at a non-zero offset Bart Van Assche
2021-07-26 14:58   ` Bodo Stroesser
2021-07-26 16:26     ` Bart Van Assche [this message]
2021-07-26 21:13       ` Bodo Stroesser
2021-07-26 21:52         ` Bart Van Assche
2021-07-27  0:54           ` Bodo Stroesser
2021-07-27  3:17             ` Bart Van Assche
2021-07-27  7:27               ` Bodo Stroesser
2021-07-27 16:47                 ` Bart Van Assche
2021-07-28 17:14                   ` Bodo Stroesser
2021-07-28 17:55                     ` Bart Van Assche
2021-07-23 21:23 ` [PATCH 3/4] kunit: Add support for suite initialization and cleanup Bart Van Assche
2021-07-27 21:26   ` Brendan Higgins
2021-07-29  3:33     ` Bart Van Assche
2021-07-23 21:23 ` [PATCH 4/4] configfs: Add unit tests Bart Van Assche

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=d12f24b6-7066-f9bb-1b88-6cc23c9c45c1@acm.org \
    --to=bvanassche@acm.org \
    --cc=bostroesser@gmail.com \
    --cc=brendanhiggins@google.com \
    --cc=hch@lst.de \
    --cc=jlbec@evilplan.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=martin.petersen@oracle.com \
    --cc=yaneti@declera.com \
    --subject='Re: [PATCH 2/4] configfs: Fix writing at a non-zero offset' \
    /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;
as well as URLs for NNTP newsgroup(s).