All of lore.kernel.org
 help / color / mirror / Atom feed
From: David Howells <dhowells@redhat.com>
To: Matthew Wilcox <willy@infradead.org>
Cc: dhowells@redhat.com, Jesper Dangaard Brouer <brouer@redhat.com>,
	Christoph Lameter <cl@linux.com>,
	Andrew Morton <akpm@linux-foundation.org>,
	linux-mm <linux-mm@kvack.org>
Subject: Re: Bulk kmalloc
Date: Mon, 13 May 2019 13:04:40 +0100	[thread overview]
Message-ID: <4824.1557749080@warthog.procyon.org.uk> (raw)
In-Reply-To: <20190510165001.GA3162@bombadil.infradead.org>

Matthew Wilcox <willy@infradead.org> wrote:

> kvmalloc() is the normal solution here.  Usual reasons for not being
> able to do that would be that you do DMA to the memory or that you need
> to be able to free each of these objects individually.

I don't need to DMA to the memory - but it might be worth my while removing
status, cb_expires_at, cb_version and cb_type from struct afs_vnode and
replacing them with an RCU-managed pointer to an afs_status_cb struct.

I could then use plain RCU rather than a seqlock to manage reading from the
record (the problem being that updating these records cannot be done
atomically).  That would allow me to make afs_d_revalidate() more efficient by
doing the checks first in LOOKUP_RCU mode.

I'm not sure it's worth the extra RCU load, though.

David


      parent reply	other threads:[~2019-05-13 12:04 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
     [not found] <14647.1557415738@warthog.procyon.org.uk>
2019-05-10 11:50 ` Bulk kmalloc Jesper Dangaard Brouer
2019-05-10 16:23   ` David Howells
2019-05-10 16:50     ` Matthew Wilcox
2019-05-10 17:11       ` Christoph Hellwig
2019-05-10 17:35         ` Matthew Wilcox
2019-05-13 12:04       ` David Howells [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=4824.1557749080@warthog.procyon.org.uk \
    --to=dhowells@redhat.com \
    --cc=akpm@linux-foundation.org \
    --cc=brouer@redhat.com \
    --cc=cl@linux.com \
    --cc=linux-mm@kvack.org \
    --cc=willy@infradead.org \
    /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.