[PATCH] fixup! mm/hmm/devmem: device memory hotplug using ZONE_DEVICE

From: JÃrÃme Glisse
Date: Thu Apr 06 2017 - 17:16:56 EST


---
mm/hmm.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/mm/hmm.c b/mm/hmm.c
index ff8ec59..f567a8b 100644
--- a/mm/hmm.c
+++ b/mm/hmm.c
@@ -898,7 +898,7 @@ static int hmm_devmem_pages_create(struct hmm_devmem *devmem)
ret = arch_add_memory(nid, align_start, align_size,
devmem->pagemap.type);
mem_hotplug_done();
- if (!ret)
+ if (ret)
goto error_add_memory;

for (pfn = devmem->pfn_first; pfn < devmem->pfn_last; pfn++) {
--
2.9.3


--ZPt4rx8FFjLCG7dd--