All of lore.kernel.org
 help / color / mirror / Atom feed
From: Earl Chew <echew@ixiacom.com>
To: "Eric W. Biederman" <ebiederm@xmission.com>
Cc: Andrew Morton <akpm@linux-foundation.org>,
	Ingo Molnar <mingo@elte.hu>,
	Peter Zijlstra <a.p.zijlstra@chello.nl>,
	Eric Paris <eparis@redhat.com>,
	"Serge E. Hallyn" <serge.hallyn@canonical.com>,
	"linux-kernel@vger.kernel.org" <linux-kernel@vger.kernel.org>,
	<adobriyan@gmail.com>
Subject: Re: [PATCH] Support single byte reads from integers published in procfs by kernel/sysctl.c
Date: Sun, 29 Jan 2012 17:13:18 -0800	[thread overview]
Message-ID: <4F25EEAE.6030908@ixiacom.com> (raw)
In-Reply-To: <m1ty3ekpv5.fsf@fess.ebiederm.org>

> I suspect what we want for writes is to read the existing value into an
> internal buffer, and then allow partial writes to the internal buffer.

Oh I see. Hmm ... I get the feeling that doubles the scope of the exercise ;-)

I'll give it some more thought.

> I don't know if writable seq_files exist.

No, they don't -- at least not out-of-the-box. From fs/seq_file.c :

>         /*
>          * seq_files support lseek() and pread().  They do not implement
>          * write() at all, but we clear FMODE_PWRITE here for historical
>          * reasons.
>          *
>          * If a client of seq_files a) implements file.write() and b) wishes to
>          * support pwrite() then that client will need to implement its own
>          * file.open() which calls seq_open() and then sets FMODE_PWRITE.
>          */
>         file->f_mode &= ~FMODE_PWRITE;

Earl


      reply	other threads:[~2012-01-30  1:13 UTC|newest]

Thread overview: 12+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2012-01-22 18:46 [PATCH] Support single byte reads from integers published in procfs by kernel/sysctl.c Earl Chew
2012-01-23 14:47 ` Eric W. Biederman
2012-01-23 15:49   ` Earl Chew
2012-01-23 16:35     ` Eric W. Biederman
2012-01-23 16:43       ` Eric W. Biederman
2012-01-23 16:47       ` Earl Chew
2012-01-24 22:50         ` Andrew Morton
2012-01-25  6:28           ` Eric W. Biederman
2012-01-25 15:27           ` Earl Chew
2012-01-29 22:56         ` Earl Chew
2012-01-30  0:15           ` Eric W. Biederman
2012-01-30  1:13             ` Earl Chew [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=4F25EEAE.6030908@ixiacom.com \
    --to=echew@ixiacom.com \
    --cc=a.p.zijlstra@chello.nl \
    --cc=adobriyan@gmail.com \
    --cc=akpm@linux-foundation.org \
    --cc=ebiederm@xmission.com \
    --cc=eparis@redhat.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=mingo@elte.hu \
    --cc=serge.hallyn@canonical.com \
    /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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.