From: Max Gurtovoy <mgurtovoy@nvidia.com>
To: <linux-nvme@lists.infradead.org>, <dan.j.williams@intel.com>,
<logang@deltatee.com>, <linux-mm@kvack.org>, <hch@lst.de>
Cc: <sagi@grimberg.me>, <david@redhat.com>, <oren@nvidia.com>,
<linux-kernel@vger.kernel.org>, <akpm@linux-foundation.org>,
Max Gurtovoy <mgurtovoy@nvidia.com>
Subject: [RFC PATCH 0/3] PCI/P2PMEM: introduce pci_p2pdma_align_size API
Date: Wed, 2 Jun 2021 14:10:52 +0300 [thread overview]
Message-ID: <20210602111055.10480-1-mgurtovoy@nvidia.com> (raw)
Hi all,
In hotplugged memory (from check_pfn_span function):
"
Disallow all operations smaller than a sub-section and only
allow operations smaller than a section for
SPARSEMEM_VMEMMAP. Note that check_hotplug_memory_range()
enforces a larger memory_block_size_bytes() granularity for
memory that will be marked online, so this check should only
fire for direct arch_{add,remove}_memory() users outside of
add_memory_resource()
"
This restriction will disqualify, for example, large NVMe CMBs that might have
non power of 2 number of pages (e.g. 32767 pages of 4KB). For these
devices, the CMB size will be rounded down from 0x7fff000 to 0x7e00000
but it's better than having un-mapped CMB.
If we all agree on the approach, this RFC can assist as-is to these NVMe
devices and other P2PMEM devices in the future and can considered for
the next merge window.
Max Gurtovoy (3):
mm,memory_hotplug: export mhp min alignment
PCI/P2PMEM: introduce pci_p2pdma_align_size API
nvme-pci: align CMB size according to P2PMEM alignment
drivers/nvme/host/pci.c | 7 +++++++
drivers/pci/p2pdma.c | 23 +++++++++++++++++++++++
include/linux/memory_hotplug.h | 5 +++++
include/linux/pci-p2pdma.h | 5 +++++
mm/memory_hotplug.c | 33 +++++++++++++++++++--------------
5 files changed, 59 insertions(+), 14 deletions(-)
--
2.18.1
next reply other threads:[~2021-06-02 11:11 UTC|newest]
Thread overview: 10+ messages / expand[flat|nested] mbox.gz Atom feed top
2021-06-02 11:10 Max Gurtovoy [this message]
2021-06-02 11:10 ` [PATCH 1/3] mm,memory_hotplug: export mhp min alignment Max Gurtovoy
2021-06-02 12:14 ` David Hildenbrand
2021-06-03 10:52 ` Max Gurtovoy
2021-06-21 16:11 ` Max Gurtovoy
2021-06-02 11:10 ` [PATCH 2/3] PCI/P2PMEM: introduce pci_p2pdma_align_size API Max Gurtovoy
2021-06-02 11:10 ` [PATCH 3/3] nvme-pci: align CMB size according to P2PMEM alignment Max Gurtovoy
2021-06-02 14:39 ` Keith Busch
2021-06-02 14:51 ` Max Gurtovoy
2021-06-02 12:08 ` [RFC PATCH 0/3] PCI/P2PMEM: introduce pci_p2pdma_align_size API David Hildenbrand
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=20210602111055.10480-1-mgurtovoy@nvidia.com \
--to=mgurtovoy@nvidia.com \
--cc=akpm@linux-foundation.org \
--cc=dan.j.williams@intel.com \
--cc=david@redhat.com \
--cc=hch@lst.de \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-mm@kvack.org \
--cc=linux-nvme@lists.infradead.org \
--cc=logang@deltatee.com \
--cc=oren@nvidia.com \
--cc=sagi@grimberg.me \
/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
all inboxes | Powered by JetHome®