From: Jon Derrick <jonathan.derrick@intel.com>
To: Christoph Hellwig <hch@infradead.org>
Cc: Haggai Eran <haggaie@mellanox.com>,
linux-rdma@vger.kernel.org, linux-nvme@lists.infradead.org,
Liran Liss <liranl@mellanox.com>,
linux-pci@vger.kernel.org, Yishai Hadas <yishaih@mellanox.com>,
Stephen Bates <stephen.bates@microsemi.com>,
Leon Romanovsky <leonro@mellanox.com>,
Artemy Kovalyov <artemyko@mellanox.com>,
Jerome Glisse <j.glisse@gmail.com>, Jon Derrick:;
Subject: Re: [RFC 6/7] NVMe: Use genalloc to allocate CMB regions
Date: Mon, 1 Aug 2016 10:20:58 -0600 [thread overview]
Message-ID: <20160801162057.GA11476@localhost.localdomain> (raw)
In-Reply-To: <20160801155348.GB23224@infradead.org>
On Mon, Aug 01, 2016 at 08:53:49AM -0700, Christoph Hellwig wrote:
> On Mon, Aug 01, 2016 at 09:57:32AM +0300, Haggai Eran wrote:
> > Register the CMB in a gen_pool dedicated to manage CMB regions. Use the
> > pool to allocate the SQs to make sure they are registered.
>
> And why would the NVMe driver care if "they are registered"?
>
> Once we start allowing diverse CMB uses (what happened to Jon's patches
> btw?) genalloc might be a good backend allocator, but without that
> it's entirely pointless. Also please don't introduce useless header
> files.
My concern is using CMB as a generic memory space could lead to invalid uses and untested paths in broken firmware (leading to bricked drives...). The spec defines what it's allowed to be used for, but doesn't really leave it open for general purpose usage outside of that. Because of that I think it needs more hand-holding by the kernel to prevent invalid usage.
What I would like to see is a set of knobs controlling the 'chunks' of memory's usages (controlled through sysfs/configfs?) and the kernel takes care of allocation. My set was going to expose a resource file for WDS/RDS but everything else was unhandled except for its current sqes usage. I think the genalloc could fit into this scheme quite well.
Thoughts?
next prev parent reply other threads:[~2016-08-01 16:48 UTC|newest]
Thread overview: 16+ messages / expand[flat|nested] mbox.gz Atom feed top
2016-08-01 6:57 [RFC 0/7] RDMA subsystem DMA-BUF support Haggai Eran
2016-08-01 6:57 ` [RFC 1/7] IB/mlx5: Helper for posting work-requests on the UMR QP Haggai Eran
2016-08-01 6:57 ` [RFC 2/7] IB/mlx5: Support registration and invalidate operations " Haggai Eran
2016-08-01 6:57 ` [RFC 3/7] IB/core: Helpers for mapping DMA-BUF in MRs Haggai Eran
2016-08-01 6:57 ` [RFC 4/7] IB/uverbs: Add command to register a DMA-BUF fd Haggai Eran
2016-08-01 6:57 ` [RFC 5/7] IB/mlx5: Implement reg_user_dma_buf_mr Haggai Eran
2016-08-01 6:57 ` [RFC 6/7] NVMe: Use genalloc to allocate CMB regions Haggai Eran
[not found] ` <20160801155348.GB23224@infradead.org>
2016-08-01 16:20 ` Jon Derrick [this message]
2016-08-02 7:15 ` Haggai Eran
2016-08-02 6:48 ` Haggai Eran
2016-08-01 6:57 ` [RFC 7/7] NVMe: CMB on DMA-BUF Haggai Eran
2016-08-01 15:52 ` Christoph Hellwig
2016-08-02 7:10 ` Haggai Eran
2016-08-04 11:56 ` hch
2016-08-07 5:24 ` Haggai Eran
2016-08-03 10:02 ` Sagi Grimberg
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=20160801162057.GA11476@localhost.localdomain \
--to=jonathan.derrick@intel.com \
--cc=artemyko@mellanox.com \
--cc=haggaie@mellanox.com \
--cc=hch@infradead.org \
--cc=j.glisse@gmail.com \
--cc=leonro@mellanox.com \
--cc=linux-nvme@lists.infradead.org \
--cc=linux-pci@vger.kernel.org \
--cc=linux-rdma@vger.kernel.org \
--cc=liranl@mellanox.com \
--cc=stephen.bates@microsemi.com \
--cc=yishaih@mellanox.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 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).