Re: RFC: move kernel/memremap.c to mm/

2019-07-17 Thread Dan Williams
On Wed, Jul 17, 2019 at 10:49 PM Christoph Hellwig wrote: > > Hi Dan, > > was there any really good reason to have memremap.c in kernel/ back > when you started it? It seems to be pretty much tried into the mm > infrastructure, and I keep mistyping the path. Would you mind a simple > git-mv patc

[PATCH v2 7/7] driver-core, libnvdimm: Let device subsystems add local lockdep coverage

2019-07-17 Thread Dan Williams
ot;Rafael J. Wysocki" Cc: Greg Kroah-Hartman Signed-off-by: Dan Williams --- drivers/acpi/nfit/core.c| 28 drivers/acpi/nfit/nfit.h| 24 ++ drivers/base/core.c |3 ++ drivers/nvdimm/btt_devs.c | 16 + drivers/

[PATCH v2 6/7] libnvdimm/bus: Fix wait_nvdimm_bus_probe_idle() ABBA deadlock

2019-07-17 Thread Dan Williams
mespace instantiation") Cc: Vishal Verma Tested-by: Jane Chu Signed-off-by: Dan Williams --- drivers/nvdimm/bus.c | 14 +- drivers/nvdimm/region_devs.c |4 2 files changed, 13 insertions(+), 5 deletions(-) diff --git a/drivers/nvdimm/bus.c b/drivers/nvdimm/bus

[PATCH v2 1/7] drivers/base: Introduce kill_device()

2019-07-17 Thread Dan Williams
e. This refactoring does not change any behavior, but it is a pre-requisite for follow-on fixes and therefore marked for -stable. Cc: Greg Kroah-Hartman Cc: "Rafael J. Wysocki" Fixes: 4d88a97aa9e8 ("libnvdimm, nvdimm: dimm driver and base libnvdimm device-driver...") Cc:

[PATCH v2 5/7] libnvdimm/bus: Stop holding nvdimm_bus_list_mutex over __nd_ioctl()

2019-07-17 Thread Dan Williams
table as it is a pre-requisite for a follow-on fix. Cc: Fixes: bf9bccc14c05 ("libnvdimm: pmem label sets and namespace instantiation") Cc: Vishal Verma Tested-by: Jane Chu Signed-off-by: Dan Williams --- drivers/nvdimm/bus.c | 96 --

[PATCH v2 4/7] libnvdimm/bus: Prepare the nd_ioctl() path to be re-entrant

2019-07-17 Thread Dan Williams
staging buffers are moved to the heap. Reported-by: Vishal Verma Signed-off-by: Dan Williams --- drivers/nvdimm/bus.c | 59 +++--- 1 file changed, 37 insertions(+), 22 deletions(-) diff --git a/drivers/nvdimm/bus.c b/drivers/nvdimm/bus.c index 4271

[PATCH v2 3/7] libnvdimm/region: Register badblocks before namespaces

2019-07-17 Thread Dan Williams
") Cc: Cc: Vishal Verma Signed-off-by: Dan Williams --- drivers/nvdimm/region.c | 22 +++--- 1 file changed, 11 insertions(+), 11 deletions(-) diff --git a/drivers/nvdimm/region.c b/drivers/nvdimm/region.c index ef46cc3a71ae..488c47ac4c4a 100644 --- a/drivers/nvdimm/regi

[PATCH v2 2/7] libnvdimm/bus: Prevent duplicate device_unregister() calls

2019-07-17 Thread Dan Williams
tl/issues/96 Tested-by: Tested-by: Jane Chu Signed-off-by: Dan Williams --- drivers/nvdimm/bus.c | 25 + 1 file changed, 25 insertions(+) diff --git a/drivers/nvdimm/bus.c b/drivers/nvdimm/bus.c index 2dca3034fee0..42713b210f51 100644 --- a/drivers/nvdimm/bus.c +++ b/d

[PATCH v2 0/7] libnvdimm: Fix async operations and locking

2019-07-17 Thread Dan Williams
he failing stress test and the existing libnvdimm unit tests with CONFIG_PROVE_LOCKING=y and the new "dev->lockdep_mutex" shadow lock with no lockdep warnings. --- Dan Williams (7): drivers/base: Introduce kill_device() libnvdimm/bus: Prevent duplicate device_u

Re: [PATCH v2 2/2] mm,memory_hotplug: Fix shrink_{zone,node}_span

2019-07-17 Thread Dan Williams
pgdat}_span for sub-section > removal") > Signed-off-by: Oscar Salvador Looks good, Reviewed-by: Dan Williams

Re: [PATCH] dax: Fix missed PMD wakeups

2019-07-16 Thread Dan Williams
On Fri, Jul 12, 2019 at 2:14 AM Jan Kara wrote: > > On Thu 11-07-19 08:25:50, Matthew Wilcox wrote: > > On Thu, Jul 11, 2019 at 07:13:50AM -0700, Matthew Wilcox wrote: > > > However, the XA_RETRY_ENTRY might be a good choice. It doesn't normally > > > appear in an XArray (it may appear if you're

Re: [PATCH v3] virtio_pmem: fix sparse warning

2019-07-16 Thread Dan Williams
On Fri, Jul 12, 2019 at 7:11 AM Michael S. Tsirkin wrote: > > On Fri, Jul 12, 2019 at 10:46:10AM +0530, Pankaj Gupta wrote: > > This patch fixes below sparse warning related to __virtio > > type in virtio pmem driver. This is reported by Intel test > > bot on linux-next tree. > > > > nd_virtio.c:5

Re: [PATCH 2/2] mm,memory_hotplug: Fix shrink_{zone,node}_span

2019-07-16 Thread Dan Williams
On Mon, Jul 15, 2019 at 2:24 PM Oscar Salvador wrote: > > On Mon, 2019-07-15 at 21:41 +0530, Aneesh Kumar K.V wrote: > > Oscar Salvador writes: > > > > > Since [1], shrink_{zone,node}_span work on PAGES_PER_SUBSECTION > > > granularity. > > > The problem is that deactivation of the section occurs

Re: [PATCH 0/3] resource: find_next_iomem_res() improvements

2019-07-16 Thread Dan Williams
On Tue, Jul 16, 2019 at 3:29 PM Nadav Amit wrote: > > > On Jul 16, 2019, at 3:20 PM, Dan Williams wrote: > > > > On Tue, Jul 16, 2019 at 3:13 PM Nadav Amit wrote: > >>> On Jul 16, 2019, at 3:07 PM, Dan Williams > >>> wrote: > >>

Re: [PATCH 0/3] resource: find_next_iomem_res() improvements

2019-07-16 Thread Dan Williams
On Tue, Jul 16, 2019 at 3:13 PM Nadav Amit wrote: > > > On Jul 16, 2019, at 3:07 PM, Dan Williams wrote: > > > > On Tue, Jul 16, 2019 at 3:01 PM Andrew Morton > > wrote: > >> On Tue, 18 Jun 2019 21:56:43 + Nadav Amit wrote: > >> > >>&g

Re: [PATCH 0/3] resource: find_next_iomem_res() improvements

2019-07-16 Thread Dan Williams
gt; > > saved value. > > > > Thanks for the detailed explanation. I’ll give it a try (the moment I find > > some free time). I still think that patch 2/3 is beneficial, but based on > > your feedback, patch 3/3 should be dropped. > > It has been a while. What sh

Re: [PATCH 1/2] mm,sparse: Fix deactivate_section for early sections

2019-07-15 Thread Dan Williams
n_nr); > } > > - if (early_section(ms) && memmap) > + if (section_is_early && memmap) > free_map_bootmem(memmap); > else > depopulate_section_memmap(pfn, nr_pages, altmap); Reviewed-by: Dan Williams In fact, this bug was re-introduced between v9 and v10 as I had seen this bug before, but did not write a reproducer for the unit test.

Re: linux-next: manual merge of the akpm-current tree with the hmm tree

2019-07-15 Thread Dan Williams
On Sat, Jul 6, 2019 at 10:04 PM Andrew Morton wrote: > > On Fri, 5 Jul 2019 12:08:15 + Jason Gunthorpe wrote: > > > On Thu, Jul 04, 2019 at 04:29:55PM -0700, Dan Williams wrote: > > > Guys, Andrew has kicked the subsection patches out of -mm because of > > >

Re: linux-next: build failure after merge of the nvdimm tree

2019-07-05 Thread Dan Williams
On Fri, Jul 5, 2019 at 12:20 AM Stephen Rothwell wrote: > > Hi all, > > After merging the nvdimm tree, today's linux-next build (x86_64 > allmodconfig) failed like this: > > In file included from :32: > ./usr/include/linux/virtio_pmem.h:19:2: error: unknown type name 'uint64_t' > uint64_t start;

Re: [PATCH] dax: Fix missed PMD wakeups

2019-07-05 Thread Dan Williams
On Fri, Jul 5, 2019 at 12:10 PM Matthew Wilcox wrote: > > On Thu, Jul 04, 2019 at 04:27:14PM -0700, Dan Williams wrote: > > On Thu, Jul 4, 2019 at 12:14 PM Matthew Wilcox wrote: > > > > > > On Thu, Jul 04, 2019 at 06:54:50PM +0200, Jan Kara wrote: > > > >

[GIT PULL] dax fix for v5.2-rc8

2019-07-04 Thread Dan Williams
Hi Linus, please pull from: git://git.kernel.org/pub/scm/linux/kernel/git/nvdimm/nvdimm tags/dax-fix-5.2-rc8 ...to receive a single dax fix that has been soaking awaiting other fixes under discussion to join it. As it is getting late in the cycle lets proceed with this fix and save follow-on ch

Re: [PATCH v3 0/4] Devmap cleanups + arm64 support

2019-07-04 Thread Dan Williams
On Thu, Jul 4, 2019 at 12:59 PM Jason Gunthorpe wrote: > > On Thu, Jul 04, 2019 at 11:53:24AM -0700, Andrew Morton wrote: > > On Wed, 26 Jun 2019 20:35:51 -0700 Andrew Morton > > wrote: > > > > > > Let me know and I can help orchestate this. > > > > > > Well. Whatever works. In this situation

Re: linux-next: manual merge of the akpm-current tree with the hmm tree

2019-07-04 Thread Dan Williams
Guys, Andrew has kicked the subsection patches out of -mm because of the merge conflicts. Can we hold off on the hmm cleanups for this cycle? On Thu, Jul 4, 2019 at 2:08 PM Stephen Rothwell wrote: > > Hi Jason, > > On Thu, 4 Jul 2019 13:28:41 + Jason Gunthorpe wrote: > > > > BTW, do you use

Re: [PATCH] dax: Fix missed PMD wakeups

2019-07-04 Thread Dan Williams
On Thu, Jul 4, 2019 at 12:14 PM Matthew Wilcox wrote: > > On Thu, Jul 04, 2019 at 06:54:50PM +0200, Jan Kara wrote: > > On Wed 03-07-19 20:27:28, Matthew Wilcox wrote: > > > So I think we're good for all current users. > > > > Agreed but it is an ugly trap. As I already said, I'd rather pay the >

Re: [PATCH] dax: Fix missed PMD wakeups

2019-07-03 Thread Dan Williams
On Wed, Jul 3, 2019 at 12:53 PM Matthew Wilcox wrote: > > On Wed, Jul 03, 2019 at 10:01:37AM -0700, Dan Williams wrote: > > On Wed, Jul 3, 2019 at 5:17 AM Matthew Wilcox wrote: > > > > > > On Wed, Jul 03, 2019 at 12:24:54AM -0700, Dan Williams wrote: > >

Re: [PATCH] dax: Fix missed PMD wakeups

2019-07-03 Thread Dan Williams
On Wed, Jul 3, 2019 at 5:17 AM Matthew Wilcox wrote: > > On Wed, Jul 03, 2019 at 12:24:54AM -0700, Dan Williams wrote: > > This fix may increase waitqueue contention, but a fix for that is saved > > for a larger rework. In the meantime this fix is suitable for -stable > >

[PATCH] dax: Fix missed PMD wakeups

2019-07-03 Thread Dan Williams
y: Robert Barror Reported-by: Seema Pandit Signed-off-by: Dan Williams --- fs/dax.c | 34 -- 1 file changed, 12 insertions(+), 22 deletions(-) diff --git a/fs/dax.c b/fs/dax.c index 9fd908f3df32..592944c522b8 100644 --- a/fs/dax.c +++ b/fs/dax.c @@ -144,19 +14

Re: dev_pagemap related cleanups v4

2019-07-02 Thread Dan Williams
On Tue, Jul 2, 2019 at 11:42 AM Jason Gunthorpe wrote: > > On Mon, Jul 01, 2019 at 10:25:17AM +0200, Christoph Hellwig wrote: > > And I've demonstrated that I can't send patch series.. While this > > has all the right patches, it also has the extra patches already > > in the hmm tree, and four ex

Re: [PATCH] filesystem-dax: Disable PMD support

2019-07-02 Thread Dan Williams
On Tue, Jul 2, 2019 at 5:23 PM Boaz Harrosh wrote: > > On 02/07/2019 18:37, Dan Williams wrote: > <> > > > > I'd be inclined to do the brute force fix of not trying to get fancy > > with separate PTE/PMD waitqueues and then follow on with a more clever >

Re: [PATCH] filesystem-dax: Disable PMD support

2019-07-02 Thread Dan Williams
On Mon, Jul 1, 2019 at 8:34 PM Matthew Wilcox wrote: > > On Sun, Jun 30, 2019 at 02:37:32PM -0700, Dan Williams wrote: > > On Sun, Jun 30, 2019 at 8:23 AM Matthew Wilcox wrote: > > > I think my theory was slightly mistaken, but your fix has the effect of > > >

Re: [PATCH] net: usb: asix: init MAC address buffers

2019-07-01 Thread Dan Williams
On Mon, 2019-07-01 at 06:45 +0700, Phong Tran wrote: > This is for fixing bug KMSAN: uninit-value in ax88772_bind > > Tested by > https://groups.google.com/d/msg/syzkaller-bugs/aFQurGotng4/cFe9nxMCCwAJ > > Reported-by: syzbot+8a3fc6674bbc3978e...@syzkaller.appspotmail.com > > syzbot found the fo

Re: [PATCH] filesystem-dax: Disable PMD support

2019-06-30 Thread Dan Williams
On Sun, Jun 30, 2019 at 8:23 AM Matthew Wilcox wrote: > > On Sun, Jun 30, 2019 at 01:01:04AM -0700, Dan Williams wrote: > > On Sun, Jun 30, 2019 at 12:27 AM Dan Williams > > wrote: > > > > > > On Sat, Jun 29, 2019 at 9:03 AM Matthew Wilcox > > > w

Re: [PATCH] filesystem-dax: Disable PMD support

2019-06-30 Thread Dan Williams
On Sun, Jun 30, 2019 at 12:27 AM Dan Williams wrote: > > On Sat, Jun 29, 2019 at 9:03 AM Matthew Wilcox wrote: > > > > On Thu, Jun 27, 2019 at 07:39:37PM -0700, Dan Williams wrote: > > > On Thu, Jun 27, 2019 at 12:59 PM Matthew Wilcox > > > wrote: > >

Re: [PATCH] filesystem-dax: Disable PMD support

2019-06-30 Thread Dan Williams
On Sat, Jun 29, 2019 at 9:03 AM Matthew Wilcox wrote: > > On Thu, Jun 27, 2019 at 07:39:37PM -0700, Dan Williams wrote: > > On Thu, Jun 27, 2019 at 12:59 PM Matthew Wilcox wrote: > > > > > > On Thu, Jun 27, 2019 at 12:09:29PM -0700, Dan Williams wrote: > > &g

Re: [PATCH] filesystem-dax: Disable PMD support

2019-06-28 Thread Dan Williams
On Fri, Jun 28, 2019 at 9:37 AM Matthew Wilcox wrote: > > On Thu, Jun 27, 2019 at 07:39:37PM -0700, Dan Williams wrote: > > On Thu, Jun 27, 2019 at 12:59 PM Matthew Wilcox wrote: > > > On Thu, Jun 27, 2019 at 12:09:29PM -0700, Dan Williams wrote: > > > > > Thi

Re: [PATCH] filesystem-dax: Disable PMD support

2019-06-27 Thread Dan Williams
On Thu, Jun 27, 2019 at 12:59 PM Matthew Wilcox wrote: > > On Thu, Jun 27, 2019 at 12:09:29PM -0700, Dan Williams wrote: > > > This bug feels like we failed to unlock, or unlocked the wrong entry > > > and this hunk in the bisected commit looks suspect to me. Why do we

Re: [PATCH] filesystem-dax: Disable PMD support

2019-06-27 Thread Dan Williams
On Thu, Jun 27, 2019 at 11:58 AM Dan Williams wrote: > > On Thu, Jun 27, 2019 at 11:29 AM Dan Williams > wrote: > > > > On Thu, Jun 27, 2019 at 9:06 AM Dan Williams > > wrote: > > > > > > On Thu, Jun 27, 2019 at 5:34 AM Matthew Wilcox > >

Re: [PATCH] filesystem-dax: Disable PMD support

2019-06-27 Thread Dan Williams
On Thu, Jun 27, 2019 at 11:29 AM Dan Williams wrote: > > On Thu, Jun 27, 2019 at 9:06 AM Dan Williams wrote: > > > > On Thu, Jun 27, 2019 at 5:34 AM Matthew Wilcox wrote: > > > > > > On Wed, Jun 26, 2019 at 05:15:45PM -0700, Dan Williams wrote: > > &

Re: [PATCH] filesystem-dax: Disable PMD support

2019-06-27 Thread Dan Williams
On Thu, Jun 27, 2019 at 9:06 AM Dan Williams wrote: > > On Thu, Jun 27, 2019 at 5:34 AM Matthew Wilcox wrote: > > > > On Wed, Jun 26, 2019 at 05:15:45PM -0700, Dan Williams wrote: > > > Ever since the conversion of DAX to the Xarray a RocksDB benchmark has > >

Re: [PATCH] filesystem-dax: Disable PMD support

2019-06-27 Thread Dan Williams
On Thu, Jun 27, 2019 at 5:34 AM Matthew Wilcox wrote: > > On Wed, Jun 26, 2019 at 05:15:45PM -0700, Dan Williams wrote: > > Ever since the conversion of DAX to the Xarray a RocksDB benchmark has > > been encountering intermittent lockups. The backtraces always include > >

[PATCH] filesystem-dax: Disable PMD support

2019-06-26 Thread Dan Williams
y") Cc: Matthew Wilcox Cc: Jan Kara Cc: Reported-by: Robert Barror Reported-by: Seema Pandit Signed-off-by: Dan Williams --- fs/Kconfig |3 +++ 1 file changed, 3 insertions(+) diff --git a/fs/Kconfig b/fs/Kconfig index f1046cf6ad85..85eecd0d4c5d 100644 --- a/fs/Kconfig +++ b/fs/Kc

Re: [PATCH v4 08/10] device-dax: Add a driver for "hmem" devices

2019-06-25 Thread Dan Williams
On Tue, Jun 25, 2019 at 8:39 AM Jonathan Cameron wrote: > > On Mon, 24 Jun 2019 11:20:16 -0700 > Dan Williams wrote: > > > Platform firmware like EFI/ACPI may publish "hmem" platform devices. > > Such a device is a performance differentiated memory range like

Re: [PATCH v4 01/10] acpi/numa: Establish a new drivers/acpi/numa/ directory

2019-06-25 Thread Dan Williams
On Tue, Jun 25, 2019 at 8:01 AM Jonathan Cameron wrote: > > On Mon, 24 Jun 2019 11:19:32 -0700 > Dan Williams wrote: > > > Currently hmat.c lives under an "hmat" directory which does not enhance > > the description of the file. The initial motivation for givin

Re: WWAN Controller Framework (was IPA [PATCH v2 00/17])

2019-06-24 Thread Dan Williams
On Mon, 2019-06-24 at 11:30 -0500, Alex Elder wrote: > OK I want to try to organize a little more concisely some of the > discussion on this, because there is a very large amount of volume > to date and I think we need to try to narrow the focus back down > again. > > I'm going to use a few terms

[PATCH v4 10/10] acpi/numa/hmat: Register "specific purpose" memory as an "hmem" device

2019-06-24 Thread Dan Williams
-43fff : Application Reserved 24000-33fff : hmem.0 24000-33fff : dax0.0 34000-43fff : hmem.1 34000-43fff : dax1.0 Cc: Len Brown Cc: Keith Busch Cc: "Rafael J. Wysocki" Cc: Vishal Verma Cc: Jonathan Cameron Reviewed-by: Dave Hansen

[PATCH v4 07/10] resource: Uplevel the pmem "region" ida to a global allocator

2019-06-24 Thread Dan Williams
tifier for persistent and performance-differentiated memory, and a standalone header / source file was NAK'd, house it with the rest of the general resource enumeration implementation. Cc: Keith Busch Suggested-by: Matthew Wilcox Signed-off-by: Dan Williams --- drivers/nvdimm/Kconfig |

[PATCH v4 08/10] device-dax: Add a driver for "hmem" devices

2019-06-24 Thread Dan Williams
HMEM symbol to gate performing the enumeration work. Cc: Vishal Verma Cc: Keith Busch Cc: Dave Jiang Reported-by: kbuild test robot Reviewed-by: Dave Hansen Signed-off-by: Dan Williams --- drivers/dax/Kconfig| 27 +++ drivers/dax/Makefile |2 ++

[PATCH v4 06/10] x86, efi: Add efi_fake_mem support for EFI_MEMORY_SP

2019-06-24 Thread Dan Williams
search for attempts to set EFI_MEMORY_SP via efi_fake_mem and update the e820 table accordingly. Cc: Cc: Borislav Petkov Cc: Ingo Molnar Cc: "H. Peter Anvin" Cc: Thomas Gleixner Cc: Ard Biesheuvel Reviewed-by: Dave Hansen Signed-off-by: Dan Williams --- arch/x86/include/asm/e

[PATCH v4 09/10] acpi/numa/hmat: Register HMAT at device_initcall level

2019-06-24 Thread Dan Williams
tree is populated with "Application Reserved" (IORES_DESC_APPLICATION_RESERVED). e820__reserve_resources_late() happens at subsys_initcall time. Cc: "Rafael J. Wysocki" Cc: Len Brown Cc: Keith Busch Cc: Jonathan Cameron Reviewed-by: Dave Hansen Signed-off-by: Dan Williams --

[PATCH v4 04/10] x86, efi: Push EFI_MEMMAP check into leaf routines

2019-06-24 Thread Dan Williams
" Cc: Andy Lutomirski Cc: Thomas Gleixner Cc: Peter Zijlstra Reviewed-by: Dave Hansen Signed-off-by: Dan Williams --- arch/x86/include/asm/efi.h |9 - arch/x86/kernel/setup.c | 19 +-- arch/x86/platform/efi/efi.c |3 +++ arch/x86/pl

[PATCH v4 05/10] x86, efi: Reserve UEFI 2.8 Specific Purpose Memory for dax

2019-06-24 Thread Dan Williams
Cc: Peter Zijlstra Cc: Thomas Gleixner Cc: Ard Biesheuvel Reported-by: kbuild test robot Reviewed-by: Dave Hansen Signed-off-by: Dan Williams --- arch/x86/Kconfig | 23 +++ arch/x86/boot/compressed/eboot.c |5 - arch/x86/boot/compressed/kaslr.c |3

[PATCH v4 03/10] efi: Enumerate EFI_MEMORY_SP

2019-06-24 Thread Dan Williams
e dumps and save the kernel policy for a follow-on change. Reviewed-by: Ard Biesheuvel Reviewed-by: Dave Hansen Signed-off-by: Dan Williams --- drivers/firmware/efi/efi.c |5 +++-- include/linux/efi.h|1 + 2 files changed, 4 insertions(+), 2 deletions(-) diff --git a/drivers/f

[PATCH v4 00/10] EFI Specific Purpose Memory Support

2019-06-24 Thread Dan Williams
ttps://uefi.org/sites/default/files/resources/UEFI_Spec_2_8_final.pdf [3]: https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/commit/?id=e1cf33aafb84 [4]: https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/commit/?id=c221c0b0308f [5]: http://patchwork.ozlabs.org/co

[PATCH v4 02/10] acpi/numa/hmat: Skip publishing target info for nodes with no online memory

2019-06-24 Thread Dan Williams
...result for HMAT parsing. Reviewed-by: Dave Hansen Signed-off-by: Dan Williams --- drivers/acpi/numa/hmat.c | 14 +++--- 1 file changed, 11 insertions(+), 3 deletions(-) diff --git a/drivers/acpi/numa/hmat.c b/drivers/acpi/numa/hmat.c index 96b7d39a97c6..2c220cb7b620 100644 ---

[PATCH v4 01/10] acpi/numa: Establish a new drivers/acpi/numa/ directory

2019-06-24 Thread Dan Williams
fael J. Wysocki" Reviewed-by: Dave Hansen Signed-off-by: Dan Williams --- drivers/acpi/Kconfig |9 + drivers/acpi/Makefile |3 +-- drivers/acpi/hmat/Makefile |2 -- drivers/acpi/numa/Kconfig |7 ++- drivers/acpi/numa/Makefile |3 +++ drivers/acpi/

[-mm PATCH] docs/vm: Update ZONE_DEVICE memory model documentation

2019-06-20 Thread Dan Williams
Mike notes that Sphinx needs a newline before the start of a bulleted list, and v10 of the subsection patch set changed the subsection size from an arch-variable 'PMD_SIZE' to a constant 2MB. Cc: Jonathan Corbet Reported-by: Mike Rapoport Signed-off-by: Dan Williams --- Hi Andrew

Re: [PATCH] device-dax: Add a 'resource' attribute

2019-06-20 Thread Dan Williams
asier to provide this information in the sysfs hierarchy. > > Cc: Dave Hansen > Cc: Dan Williams > Signed-off-by: Vishal Verma Looks good to me, applied.

[PATCH] mm/sparsemem: Cleanup 'section number' data types

2019-06-20 Thread Dan Williams
David points out that there is a mixture of 'int' and 'unsigned long' usage for section number data types. Update the memory hotplug path to use 'unsigned long' consistently for section numbers. Cc: Michal Hocko Cc: Oscar Salvador Reported-by: David Hildenbran

Re: [PATCH 3/3] resource: Introduce resource cache

2019-06-20 Thread Dan Williams
On Thu, Jun 20, 2019 at 2:31 PM Andi Kleen wrote: > > Dan Williams writes: > > > > The underlying issue is that the x86-PAT implementation wants to > > ensure that conflicting mappings are not set up for the same physical > > address. This is mentioned in the devel

Re: [PATCH v10 08/13] mm/sparsemem: Prepare for sub-section ranges

2019-06-20 Thread Dan Williams
On Thu, Jun 20, 2019 at 9:37 AM David Hildenbrand wrote: > > On 20.06.19 18:19, Dan Williams wrote: > > On Thu, Jun 20, 2019 at 3:31 AM David Hildenbrand wrote: > >> > >> On 19.06.19 07:52, Dan Williams wrote: > >>> Prepare the memory hot-{add,remove} p

Re: [PATCH v10 00/13] mm: Sub-section memory hotplug support

2019-06-20 Thread Dan Williams
On Thu, Jun 20, 2019 at 5:31 AM Aneesh Kumar K.V wrote: > > Dan Williams writes: > > > Changes since v9 [1]: > > - Fix multiple issues related to the fact that pfn_valid() has > > traditionally returned true for any pfn in an 'early' (onlined at > >

Re: [PATCH v10 08/13] mm/sparsemem: Prepare for sub-section ranges

2019-06-20 Thread Dan Williams
On Thu, Jun 20, 2019 at 3:31 AM David Hildenbrand wrote: > > On 19.06.19 07:52, Dan Williams wrote: > > Prepare the memory hot-{add,remove} paths for handling sub-section > > ranges by plumbing the starting page frame and number of pages being > > handled through arch_

Re: [PATCH v2 00/17] net: introduce Qualcomm IPA driver

2019-06-19 Thread Dan Williams
On Wed, 2019-06-19 at 12:47 -0600, Subash Abhinov Kasiviswanathan wrote: > > > There is a n:1 relationship between rmnet and IPA. > > > rmnet does the de-muxing to multiple netdevs based on the mux id > > > in the MAP header for RX packets and vice versa. > > > > Oh, so you mean that even though I

Re: [PATCH 6/6] driver-core, libnvdimm: Let device subsystems add local lockdep coverage

2019-06-19 Thread Dan Williams
On Tue, Jun 11, 2019 at 4:40 PM Dan Williams wrote: > > For good reason, the standard device_lock() is marked > lockdep_set_novalidate_class() because there is simply no sane way to > describe the myriad ways the device_lock() ordered with other locks. > However, that leaves subsy

Re: [PATCH 3/3] resource: Introduce resource cache

2019-06-19 Thread Dan Williams
[ add Andi ] On Wed, Jun 19, 2019 at 6:00 AM Bjorn Helgaas wrote: > > On Tue, Jun 18, 2019 at 12:40 AM Nadav Amit wrote: > > > > > On Jun 17, 2019, at 10:33 PM, Nadav Amit wrote: > > > > > >> On Jun 17, 2019, at 9:57 PM, Andrew Morton > > >> wrote: > > >> > > >> On Wed, 12 Jun 2019 21:59:03 -

Re: [PATCH v2 00/17] net: introduce Qualcomm IPA driver

2019-06-19 Thread Dan Williams
On Tue, 2019-06-18 at 23:06 +0200, Arnd Bergmann wrote: > On Tue, Jun 18, 2019 at 10:39 PM Johannes Berg > wrote: > > On Tue, 2019-06-18 at 22:33 +0200, Arnd Bergmann wrote: > > It seems to me though that this is far more complex than what I'm > > proposing? What I'm proposing there doesn't even n

[PATCH v2] libnvdimm: Enable unit test infrastructure compile checks

2019-06-19 Thread Dan Williams
catch unit test build regressions. Note that there are a few x86isms in the implementation, so this does not bother compile testing this architectures other than 64-bit x86. Cc: Jérôme Glisse Cc: Jason Gunthorpe Reported-by: Christoph Hellwig Signed-off-by: Dan Williams --- Changes since v1

Re: [PATCH v10 12/13] libnvdimm/pfn: Fix fsdax-mode namespace info-block zero-fields

2019-06-19 Thread Dan Williams
On Wed, Jun 19, 2019 at 9:30 AM Aneesh Kumar K.V wrote: > > Dan Williams writes: > > > At namespace creation time there is the potential for the "expected to > > be zero" fields of a 'pfn' info-block to be filled with indeterminate > > data. While

Re: [PATCH] libnvdimm: Enable unit test infrastructure compile checks

2019-06-19 Thread Dan Williams
On Wed, Jun 19, 2019 at 4:23 AM Christoph Hellwig wrote: > > On Mon, Jun 17, 2019 at 01:52:27PM -0700, Dan Williams wrote: > > The infrastructure to mock core libnvdimm routines for unit testing > > purposes is prone to bitrot relative to refactoring of that core. > > A

[PATCH v10 12/13] libnvdimm/pfn: Fix fsdax-mode namespace info-block zero-fields

2019-06-18 Thread Dan Williams
So if someone decides to backport "libnvdimm/pfn: Stop padding pmem namespaces to section alignment" (which is not tagged for stable), make sure this pre-requisite is flagged. Fixes: 32ab0a3f5170 ("libnvdimm, pmem: 'struct page' for pmem") Cc: Signed-off-by: Dan

[PATCH v10 09/13] mm/sparsemem: Support sub-section hotplug

2019-06-18 Thread Dan Williams
27; before arch_add_memory() in the add_memory() sequence. [1]: https://lore.kernel.org/r/155000671719.348031.2347363160141119237.st...@dwillia2-desk3.amr.corp.intel.com Cc: Michal Hocko Cc: Vlastimil Babka Cc: Logan Gunthorpe Cc: Oscar Salvador Cc: Pavel Tatashin Signed-off-by: Dan Williams

[PATCH v10 06/13] mm/hotplug: Kill is_dev_zone() usage in __remove_pages()

2019-06-18 Thread Dan Williams
ildenbrand Reviewed-by: Oscar Salvador Signed-off-by: Dan Williams --- mm/memory_hotplug.c |7 ++- 1 file changed, 2 insertions(+), 5 deletions(-) diff --git a/mm/memory_hotplug.c b/mm/memory_hotplug.c index 647859a1d119..4b882c57781a 100644 --- a/mm/memory_hotplug.c +++ b/mm/memory_hotplug.c

[PATCH v10 08/13] mm/sparsemem: Prepare for sub-section ranges

2019-06-18 Thread Dan Williams
intended functional changes. Cc: Michal Hocko Cc: Vlastimil Babka Cc: Logan Gunthorpe Cc: Oscar Salvador Reviewed-by: Pavel Tatashin Signed-off-by: Dan Williams --- include/linux/memory_hotplug.h |5 +- mm/memory_hotplug.c| 114 +--- mm/sparse.c

[PATCH v10 10/13] mm: Document ZONE_DEVICE memory-model implications

2019-06-18 Thread Dan Williams
Explain the general mechanisms of 'ZONE_DEVICE' pages and list the users of 'devm_memremap_pages()'. Cc: Jonathan Corbet Reported-by: Mike Rapoport Signed-off-by: Dan Williams --- Documentation/vm/memory-model.rst | 39 + 1 file ch

[PATCH v10 13/13] libnvdimm/pfn: Stop padding pmem namespaces to section alignment

2019-06-18 Thread Dan Williams
Now that the mm core supports section-unaligned hotplug of ZONE_DEVICE memory, we no longer need to add padding at pfn/dax device creation time. The kernel will still honor padding established by older kernels. Reported-by: Jeff Moyer Signed-off-by: Dan Williams --- drivers/nvdimm/pfn.h

[PATCH v10 11/13] mm/devm_memremap_pages: Enable sub-section remap

2019-06-18 Thread Dan Williams
parate remap attempts do not collide within a sub-section (2MB on x86). Cc: Michal Hocko Cc: Toshi Kani Cc: Jérôme Glisse Cc: Logan Gunthorpe Cc: Oscar Salvador Cc: Pavel Tatashin Signed-off-by: Dan Williams --- kernel/memremap.c | 61 +

[PATCH v10 07/13] mm: Kill is_dev_zone() helper

2019-06-18 Thread Dan Williams
ned-off-by: Dan Williams --- include/linux/mmzone.h | 12 mm/page_alloc.c|2 +- 2 files changed, 1 insertion(+), 13 deletions(-) diff --git a/include/linux/mmzone.h b/include/linux/mmzone.h index c4e8843e283c..e976faf57292 100644 --- a/include/linux/mmzone.h +++ b/inc

[PATCH v10 04/13] mm/hotplug: Prepare shrink_{zone, pgdat}_span for sub-section removal

2019-06-18 Thread Dan Williams
(), can toggle. Cc: Michal Hocko Cc: Vlastimil Babka Cc: Logan Gunthorpe Reviewed-by: Pavel Tatashin Reviewed-by: Oscar Salvador Signed-off-by: Dan Williams --- mm/memory_hotplug.c | 29 - 1 file changed, 8 insertions(+), 21 deletions(-) diff --git a/mm

[PATCH v10 05/13] mm/sparsemem: Convert kmalloc_section_memmap() to populate_section_memmap()

2019-06-18 Thread Dan Williams
are added to clarify which memmap allocation paths are sub-section capable. Cc: Michal Hocko Cc: David Hildenbrand Cc: Logan Gunthorpe Cc: Oscar Salvador Reviewed-by: Pavel Tatashin Signed-off-by: Dan Williams --- arch/x86/mm/init_64.c |4 +++- include/linux/mm.h|4 ++-- mm

[PATCH v10 02/13] mm/sparsemem: Introduce a SECTION_IS_EARLY flag

2019-06-18 Thread Dan Williams
raditional expectation that pfn_valid() returns true for all early sections. Link: https://lore.kernel.org/lkml/1560366952-10660-1-git-send-email-...@lca.pw/ Reported-by: Qian Cai Cc: Michal Hocko Cc: Logan Gunthorpe Cc: David Hildenbrand Cc: Oscar Salvador Cc: Pavel Tatashin Signed-off-by: Da

[PATCH v10 00/13] mm: Sub-section memory hotplug support

2019-06-18 Thread Dan Williams
esk3.amr.corp.intel.com [3]: https://github.com/pmem/ndctl/issues/76 [4]: https://git.kernel.org/pub/scm/linux/kernel/git/djbw/nvdimm.git/log/?h=subsection-v10 [5]: https://github.com/pmem/ndctl/commit/7c59b4867e1c --- Dan Williams (13): mm/sparsemem: Introduce struct mem_section_usage

[PATCH v10 03/13] mm/sparsemem: Add helpers track active portions of a section at boot

2019-06-18 Thread Dan Williams
ed-by: Qian Cai Tested-by: Jane Chu Signed-off-by: Dan Williams --- include/linux/mmzone.h | 33 - mm/page_alloc.c| 10 -- mm/sparse.c| 35 +++ 3 files changed, 75 insertions(+), 3 deletions(-) diff

[PATCH v10 01/13] mm/sparsemem: Introduce struct mem_section_usage

2019-06-18 Thread Dan Williams
mremap_pages() users. Beyond the fixups to teach existing paths how to retrieve the 'usemap' from a section, and updates to usemap allocation path, there are no expected behavior changes. Cc: Michal Hocko Cc: Vlastimil Babka Cc: Logan Gunthorpe Cc: Pavel Tatashin Reviewed-by: Oscar

Re: [PATCH v9 03/12] mm/hotplug: Prepare shrink_{zone, pgdat}_span for sub-section removal

2019-06-18 Thread Dan Williams
On Mon, Jun 17, 2019 at 6:42 PM Wei Yang wrote: > > On Wed, Jun 05, 2019 at 02:58:04PM -0700, Dan Williams wrote: > >Sub-section hotplug support reduces the unit of operation of hotplug > >from section-sized-units (PAGES_PER_SECTION) to sub-section-sized units > >(PAGE

Re: [PATCH v9 02/12] mm/sparsemem: Add helpers track active portions of a section at boot

2019-06-18 Thread Dan Williams
On Mon, Jun 17, 2019 at 3:32 PM Dan Williams wrote: > > On Mon, Jun 17, 2019 at 3:22 PM Wei Yang wrote: > > > > On Wed, Jun 05, 2019 at 02:57:59PM -0700, Dan Williams wrote: > > >Prepare for hot{plug,remove} of sub-ranges of a section by tracking a > > >

Re: [PATCH v9 01/12] mm/sparsemem: Introduce struct mem_section_usage

2019-06-18 Thread Dan Williams
On Sun, Jun 16, 2019 at 6:11 AM Wei Yang wrote: > > On Wed, Jun 05, 2019 at 02:57:54PM -0700, Dan Williams wrote: > >Towards enabling memory hotplug to track partial population of a > >section, introduce 'struct mem_section_usage'. > > > >A pointer

Re: [PATCH 0/3] resource: find_next_iomem_res() improvements

2019-06-18 Thread Dan Williams
On Tue, Jun 18, 2019 at 10:42 AM Nadav Amit wrote: > > > On Jun 17, 2019, at 11:44 PM, Dan Williams wrote: > > > > On Wed, Jun 12, 2019 at 9:59 PM Nadav Amit wrote: > >> Running some microbenchmarks on dax keeps showing find_next_iomem_res() > >> as a pl

Re: [PATCH v2 00/17] net: introduce Qualcomm IPA driver

2019-06-18 Thread Dan Williams
On Tue, 2019-06-18 at 10:20 -0500, Alex Elder wrote: > On 6/17/19 7:25 AM, Johannes Berg wrote: > > On Mon, 2019-06-17 at 13:42 +0200, Johannes Berg wrote: > > > > > But anyway, as I alluded to above, I had something like this in > > > mind: > > > > I forgot to state this here, but this was *heav

Re: [PATCH 0/3] resource: find_next_iomem_res() improvements

2019-06-17 Thread Dan Williams
On Wed, Jun 12, 2019 at 9:59 PM Nadav Amit wrote: > > Running some microbenchmarks on dax keeps showing find_next_iomem_res() > as a place in which significant amount of time is spent. It appears that > in order to determine the cacheability that is required for the PTE, > lookup_memtype() is call

Re: [PATCH v9 02/12] mm/sparsemem: Add helpers track active portions of a section at boot

2019-06-17 Thread Dan Williams
On Mon, Jun 17, 2019 at 3:22 PM Wei Yang wrote: > > On Wed, Jun 05, 2019 at 02:57:59PM -0700, Dan Williams wrote: > >Prepare for hot{plug,remove} of sub-ranges of a section by tracking a > >sub-section active bitmask, each bit representing a PMD_SIZE span of the > >archi

Re: [PATCH 08/25] memremap: move dev_pagemap callbacks into a separate structure

2019-06-17 Thread Dan Williams
On Mon, Jun 17, 2019 at 12:59 PM Christoph Hellwig wrote: > > On Mon, Jun 17, 2019 at 10:51:35AM -0700, Dan Williams wrote: > > > - struct dev_pagemap *pgmap = _pgmap; > > > > Whoops, needed to keep this line to avoid: > > > > tools/testing/nv

[PATCH] libnvdimm: Enable unit test infrastructure compile checks

2019-06-17 Thread Dan Williams
catch unit test build regressions. Cc: Jérôme Glisse Cc: Jason Gunthorpe Reported-by: Christoph Hellwig Signed-off-by: Dan Williams --- drivers/nvdimm/Kconfig | 11 +++ drivers/nvdimm/Makefile |4 2 files changed, 15 insertions(+) diff --git a/drivers/nvdimm/Kconfig b

Re: [PATCH 10/25] memremap: lift the devmap_enable manipulation into devm_memremap_pages

2019-06-17 Thread Dan Williams
On Mon, Jun 17, 2019 at 5:28 AM Christoph Hellwig wrote: > > Just check if there is a ->page_free operation set and take care of the > static key enable, as well as the put using device managed resources. > Also check that a ->page_free is provided for the pgmaps types that > require it, and check

Re: [PATCH -next] mm/hotplug: skip bad PFNs from pfn_to_online_page()

2019-06-17 Thread Dan Williams
On Sat, Jun 15, 2019 at 8:50 PM Aneesh Kumar K.V wrote: > > Dan Williams writes: > > > On Fri, Jun 14, 2019 at 9:18 AM Aneesh Kumar K.V > > wrote: > >> > >> On 6/14/19 9:05 PM, Oscar Salvador wrote: > >> > On Fri, Jun 14, 2019 at 02:28:40PM +

Re: [PATCH -next] mm/hotplug: skip bad PFNs from pfn_to_online_page()

2019-06-16 Thread Dan Williams
On Fri, Jun 14, 2019 at 1:43 PM Qian Cai wrote: > > On Fri, 2019-06-14 at 12:48 -0700, Dan Williams wrote: > > On Fri, Jun 14, 2019 at 12:40 PM Qian Cai wrote: > > > > > > On Fri, 2019-06-14 at 11:57 -0700, Dan Williams wrote: > > > > On Fri, Jun 14, 20

Re: [PATCH -next] mm/hotplug: skip bad PFNs from pfn_to_online_page()

2019-06-14 Thread Dan Williams
On Fri, Jun 14, 2019 at 12:40 PM Qian Cai wrote: > > On Fri, 2019-06-14 at 11:57 -0700, Dan Williams wrote: > > On Fri, Jun 14, 2019 at 11:03 AM Dan Williams > > wrote: > > > > > > On Fri, Jun 14, 2019 at 7:59 AM Qian Cai wrote: > > > > > &g

Re: [PATCH -next] mm/hotplug: skip bad PFNs from pfn_to_online_page()

2019-06-14 Thread Dan Williams
On Fri, Jun 14, 2019 at 11:03 AM Dan Williams wrote: > > On Fri, Jun 14, 2019 at 7:59 AM Qian Cai wrote: > > > > On Fri, 2019-06-14 at 14:28 +0530, Aneesh Kumar K.V wrote: > > > Qian Cai writes: > > > > > > > > > > 1) offline i

Re: [PATCH -next] mm/hotplug: skip bad PFNs from pfn_to_online_page()

2019-06-14 Thread Dan Williams
On Fri, Jun 14, 2019 at 7:59 AM Qian Cai wrote: > > On Fri, 2019-06-14 at 14:28 +0530, Aneesh Kumar K.V wrote: > > Qian Cai writes: > > > > > > > 1) offline is busted [1]. It looks like test_pages_in_a_zone() missed the > > > same > > > pfn_section_valid() check. > > > > > > 2) powerpc booting is

Re: [PATCH -next] mm/hotplug: skip bad PFNs from pfn_to_online_page()

2019-06-14 Thread Dan Williams
On Fri, Jun 14, 2019 at 10:09 AM Jeff Moyer wrote: > > "Aneesh Kumar K.V" writes: > > > On 6/14/19 10:06 PM, Dan Williams wrote: > >> On Fri, Jun 14, 2019 at 9:26 AM Aneesh Kumar K.V > >> wrote: > > > >>> Why not let the arch > &g

Re: [PATCH -next] mm/hotplug: skip bad PFNs from pfn_to_online_page()

2019-06-14 Thread Dan Williams
On Fri, Jun 14, 2019 at 9:26 AM Aneesh Kumar K.V wrote: > > On 6/14/19 9:52 PM, Dan Williams wrote: > > On Fri, Jun 14, 2019 at 9:18 AM Aneesh Kumar K.V > > wrote: > >> > >> On 6/14/19 9:05 PM, Oscar Salvador wrote: > >>> On Fri, Jun 14,

<    7   8   9   10   11   12   13   14   15   16   >