All of lore.kernel.org
 help / color / mirror / Atom feed
From: Christoph Hellwig <hch@infradead.org>
To: Bryan Donlan <bdonlan@gmail.com>
Cc: Christoph Hellwig <hch@infradead.org>,
	John Stultz <john.stultz@linaro.org>,
	LKML <linux-kernel@vger.kernel.org>,
	Robert Love <rlove@google.com>,
	Andrew Morton <akpm@linux-foundation.org>,
	Hugh Dickins <hughd@google.com>, Mel Gorman <mel@csn.ul.ie>,
	Dave Hansen <dave@linux.vnet.ibm.com>,
	Rik van Riel <riel@redhat.com>, Eric Anholt <eric@anholt.net>,
	Jesse Barnes <jbarnes@virtuousgeek.org>
Subject: Re: [RFC][PATCH] Anonymous shared memory (ashmem) subsystem
Date: Mon, 18 Jul 2011 23:36:02 -0400	[thread overview]
Message-ID: <20110719033602.GA4867@infradead.org> (raw)
In-Reply-To: <CAF_S4t_oOwsuPJdMXv+wPVhzecUag=TOWj1-KtFJqYUZOCBbog@mail.gmail.com>

On Mon, Jul 18, 2011 at 11:32:42PM -0400, Bryan Donlan wrote:
> The pinning stuff seems like a reasonable idea to me, but why should
> it be limited to ashmem using a private ioctl? If it were a proper
> syscall, I could see automatic discarding being useful in on-disk
> filesystems as well, for managing persistent caches.

Exactly.

> But yes, tmpfs
> already solved the problem of getting a shared-memory file descriptor
> - just open a random-name file in tmpfs, unlink it, and start passing
> it around.

Indeed.  And as mentioned before using /dev/zero as the file will
get you a pre-unlinked tmpfs fd without any races, and without the
need of actually mounting shmem into any namespace.

  reply	other threads:[~2011-07-19  3:36 UTC|newest]

Thread overview: 9+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2011-07-18 18:54 [RFC][PATCH] Anonymous shared memory (ashmem) subsystem John Stultz
2011-07-19  2:19 ` Christoph Hellwig
2011-07-19  3:32   ` Bryan Donlan
2011-07-19  3:36     ` Christoph Hellwig [this message]
2011-07-19 15:37       ` Dave Hansen
2011-07-19 15:41         ` Christoph Hellwig
2011-07-19 21:58           ` John Stultz
2011-07-19 14:33 ` Christoph Lameter
2011-07-19 15:55 ` Arnd Bergmann

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=20110719033602.GA4867@infradead.org \
    --to=hch@infradead.org \
    --cc=akpm@linux-foundation.org \
    --cc=bdonlan@gmail.com \
    --cc=dave@linux.vnet.ibm.com \
    --cc=eric@anholt.net \
    --cc=hughd@google.com \
    --cc=jbarnes@virtuousgeek.org \
    --cc=john.stultz@linaro.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=mel@csn.ul.ie \
    --cc=riel@redhat.com \
    --cc=rlove@google.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.