Switch zram to use the nicer bio accounting helpers, and as part of that
ensure each bio is counted as a single I/O request.
Signed-off-by: Christoph Hellwig
Reviewed-by: Konstantin Khlebnikov
---
drivers/block/zram/zram_drv.c | 24 ++--
1 file changed, 10 insertions(+), 14
Remove these now unused functions.
Signed-off-by: Christoph Hellwig
Reviewed-by: Konstantin Khlebnikov
---
block/bio.c | 39 ---
include/linux/bio.h | 6 --
2 files changed, 45 deletions(-)
diff --git a/block/bio.c b/block/bio.c
index
Switch bcache to use the nicer bio accounting helpers, and call the
routines where we also sample the start time to give coherent accounting
results.
Signed-off-by: Christoph Hellwig
Reviewed-by: Konstantin Khlebnikov
Acked-by: Coly Li
---
drivers/md/bcache/request.c | 18
From: Konstantin Khlebnikov
Also rename blk_account_io_merge() into blk_account_io_merge_request() to
distinguish it from merging request and bio.
Signed-off-by: Konstantin Khlebnikov
[hch: rebased]
Signed-off-by: Christoph Hellwig
---
block/blk-merge.c | 12 +---
1 file changed, 5
]
Signed-off-by: Christoph Hellwig
---
block/genhd.c | 11 ---
include/linux/part_stat.h | 4 ++--
2 files changed, 10 insertions(+), 5 deletions(-)
diff --git a/block/genhd.c b/block/genhd.c
index 3e7df0a3e6bb0..1a76593276644 100644
--- a/block/genhd.c
+++ b/block/genhd.c
All callers are in blk-core.c, so move update_io_ticks over.
Signed-off-by: Christoph Hellwig
Reviewed-by: Konstantin Khlebnikov
---
block/bio.c | 16
block/blk-core.c | 15 +++
block/blk.h | 1 -
3 files changed, 15 insertions(+), 17 deletions(-)
diff
percpu variables have a perfectly fine working stub implementation
for UP kernels, so use that.
Signed-off-by: Christoph Hellwig
Reviewed-by: Konstantin Khlebnikov
---
block/blk.h | 2 +-
block/genhd.c | 12 +++--
block/partitions/core.c | 5 ++--
include
Hi Jens,
they series contains various improvement for block I/O accounting. The
first bunch of patches switch the bio based drivers to better accounting
helpers compared to the current mess. The end contains a fix and various
performanc improvements. Most of this comes from a series Konstantin
Switch rsxx to use the nicer bio accounting helpers.
Signed-off-by: Christoph Hellwig
Reviewed-by: Konstantin Khlebnikov
---
drivers/lightnvm/pblk-cache.c | 8 +++-
drivers/lightnvm/pblk-read.c | 11 ---
2 files changed, 7 insertions(+), 12 deletions(-)
diff --git a/drivers
From: Konstantin Khlebnikov
Most architectures have fast path to access percpu for current cpu.
The required preempt_disable() is provided by part_stat_lock().
Signed-off-by: Konstantin Khlebnikov
[hch: rebased]
Signed-off-by: Christoph Hellwig
---
include/linux/part_stat.h | 2 +-
1 file
Switch dm to use the nicer bio accounting helpers.
Signed-off-by: Christoph Hellwig
Reviewed-by: Konstantin Khlebnikov
---
drivers/nvdimm/blk.c | 6 --
drivers/nvdimm/btt.c | 6 --
drivers/nvdimm/nd.h | 19 ---
drivers/nvdimm/pmem.c | 6 --
4 files changed
Switch dm to use the nicer bio accounting helpers.
Signed-off-by: Christoph Hellwig
Reviewed-by: Konstantin Khlebnikov
---
drivers/md/dm.c | 9 ++---
1 file changed, 2 insertions(+), 7 deletions(-)
diff --git a/drivers/md/dm.c b/drivers/md/dm.c
index f215b86664484..3f39fa1ac756e 100644
We only need the stats lock (aka preempt_disable()) for updating the
states, not for looking up or dropping the hd_struct reference.
Signed-off-by: Christoph Hellwig
Reviewed-by: Konstantin Khlebnikov
---
block/blk-core.c | 5 +++--
block/blk-merge.c | 3 ++-
2 files changed, 5 insertions
Instead of setting up the queuedata as well just use one private data
field.
Signed-off-by: Christoph Hellwig
---
drivers/block/umem.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/drivers/block/umem.c b/drivers/block/umem.c
index 1e2aa5ae27963c..5498f1cf36b3fe 100644
Now that submit_bio_noacct has a decent blk-mq fast path there is no
more need for this bypass.
Signed-off-by: Christoph Hellwig
---
block/blk-core.c | 28
drivers/md/dm.c | 5 +
drivers/nvme/host/multipath.c | 2 +-
include/linux
Instead of setting up the queuedata as well just use one private data
field.
Signed-off-by: Christoph Hellwig
---
arch/m68k/emu/nfblock.c | 3 +--
1 file changed, 1 insertion(+), 2 deletions(-)
diff --git a/arch/m68k/emu/nfblock.c b/arch/m68k/emu/nfblock.c
index c3a630440512e9..87e8b1700acd28
Instead of setting up the queuedata as well just use one private data
field.
Signed-off-by: Christoph Hellwig
---
drivers/block/null_blk_main.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/block/null_blk_main.c b/drivers/block/null_blk_main.c
index 82259242b9b5c9
The variable is only used once, so just open code the bio_sector()
there.
Signed-off-by: Christoph Hellwig
---
block/blk-core.c | 3 +--
1 file changed, 1 insertion(+), 2 deletions(-)
diff --git a/block/blk-core.c b/block/blk-core.c
index 37435d0d433564..28f60985dc75cc 100644
--- a/block/blk
Instead of setting up the queuedata as well just use one private data
field.
Signed-off-by: Christoph Hellwig
---
drivers/block/drbd/drbd_main.c | 1 -
drivers/block/drbd/drbd_req.c | 2 +-
2 files changed, 1 insertion(+), 2 deletions(-)
diff --git a/drivers/block/drbd/drbd_main.c b/drivers
generic_make_request has always been very confusingly misnamed, so rename
it to submit_bio_noacct to make it clear that it is submit_bio minus
accounting and a few checks.
Signed-off-by: Christoph Hellwig
---
Documentation/block/biodoc.rst| 2 +-
.../fault-injection/fault
derived pretty trivially from the bio.
Signed-off-by: Christoph Hellwig
---
Documentation/block/biodoc.rst| 2 +-
.../block/writeback_cache_control.rst | 2 +-
arch/m68k/emu/nfblock.c | 5 +-
arch/xtensa/platforms/iss/simdisk.c | 5
For blk-mq drivers bios can only be inserted for the same queue. So
bypass the complicated sorting logic in __submit_bio_noacct with
a blk-mq simpler submission helper.
Signed-off-by: Christoph Hellwig
---
block/blk-core.c | 50 +---
1 file changed
Instead of setting up the queuedata as well just use one private data
field.
Signed-off-by: Christoph Hellwig
---
drivers/block/zram/zram_drv.c | 3 +--
1 file changed, 1 insertion(+), 2 deletions(-)
diff --git a/drivers/block/zram/zram_drv.c b/drivers/block/zram/zram_drv.c
index
Instead of setting up the queuedata as well just use one private data
field.
Signed-off-by: Christoph Hellwig
---
drivers/block/ps3vram.c | 3 +--
1 file changed, 1 insertion(+), 2 deletions(-)
diff --git a/drivers/block/ps3vram.c b/drivers/block/ps3vram.c
index 821d4d8b1d763e..5a1d1d137c7248
The queue can be trivially derived from the bio, so pass one less
argument.
Signed-off-by: Christoph Hellwig
---
block/blk-merge.c | 21 ++---
block/blk-mq.c| 2 +-
block/blk.h | 3 +--
drivers/block/drbd/drbd_req.c | 2
Instead of setting up the queuedata as well just use one private data
field.
Signed-off-by: Christoph Hellwig
---
drivers/md/dm.c | 3 +--
1 file changed, 1 insertion(+), 2 deletions(-)
diff --git a/drivers/md/dm.c b/drivers/md/dm.c
index e44473fe0f4873..c8d91f271c272e 100644
--- a/drivers/md
The "generic_make_request: " prefix has no value, and will soon become
stale.
Signed-off-by: Christoph Hellwig
---
block/blk-core.c | 3 +--
1 file changed, 1 insertion(+), 2 deletions(-)
diff --git a/block/blk-core.c b/block/blk-core.c
index 76cfd5709f66cd..95dca74534ff73 100644
-
Split out a __submit_bio_noacct helper for the actual de-recursion
algorithm, and simplify the loop by using a continue when we can't
enter the queue for a bio.
Signed-off-by: Christoph Hellwig
---
block/blk-core.c | 131 +--
1 file change
All registers disks must have a valid queue pointer, so don't bother to
log a warning for that case.
Signed-off-by: Christoph Hellwig
---
block/blk-core.c | 12 +---
1 file changed, 1 insertion(+), 11 deletions(-)
diff --git a/block/blk-core.c b/block/blk-core.c
index 95dca7453
Nothing in bcache actually uses the ->queuedata field.
Signed-off-by: Christoph Hellwig
---
drivers/md/bcache/super.c | 1 -
1 file changed, 1 deletion(-)
diff --git a/drivers/md/bcache/super.c b/drivers/md/bcache/super.c
index 2014016f9a60d3..21aa168113d30b 100644
--- a/drivers/md/bca
Hi Jens,
this series moves the make_request_fn method into block_device_operations
with the much more descriptive ->submit_bio name. It then also gives
generic_make_request a more descriptive name, and further optimize the
path to issue to blk-mq, removing the need for the direct_make_request
byp
Instead of setting up the queuedata as well just use one private data
field.
Signed-off-by: Christoph Hellwig
---
drivers/block/rsxx/dev.c | 5 +
1 file changed, 1 insertion(+), 4 deletions(-)
diff --git a/drivers/block/rsxx/dev.c b/drivers/block/rsxx/dev.c
index 3ba07ab30c84f5
All bios can get remapped if submitted to partitions. No need to
comment on that.
Signed-off-by: Christoph Hellwig
---
fs/buffer.c | 5 -
1 file changed, 5 deletions(-)
diff --git a/fs/buffer.c b/fs/buffer.c
index 64fe82ec65ff1f..2725ebbcfdc246 100644
--- a/fs/buffer.c
+++ b/fs/buffer.c
Instead of setting up the queuedata as well just use one private data
field.
Signed-off-by: Christoph Hellwig
---
arch/xtensa/platforms/iss/simdisk.c | 4 +---
1 file changed, 1 insertion(+), 3 deletions(-)
diff --git a/arch/xtensa/platforms/iss/simdisk.c
b/arch/xtensa/platforms/iss/simdisk.c
On Tue, Jun 30, 2020 at 09:43:31AM -0600, Jens Axboe wrote:
> On 6/30/20 7:57 AM, Jens Axboe wrote:
> > On 6/29/20 1:39 PM, Christoph Hellwig wrote:
> >> Hi Jens,
> >>
> >> this series moves the make_request_fn method into block_device_operations
> >>
All bios can get remapped if submitted to partitions. No need to
comment on that.
Signed-off-by: Christoph Hellwig
---
fs/buffer.c | 5 -
1 file changed, 5 deletions(-)
diff --git a/fs/buffer.c b/fs/buffer.c
index 64fe82ec65ff1f..2725ebbcfdc246 100644
--- a/fs/buffer.c
+++ b/fs/buffer.c
The "generic_make_request: " prefix has no value, and will soon become
stale.
Signed-off-by: Christoph Hellwig
---
block/blk-core.c | 3 +--
1 file changed, 1 insertion(+), 2 deletions(-)
diff --git a/block/blk-core.c b/block/blk-core.c
index 76cfd5709f66cd..95dca74534ff73 100644
-
generic_make_request has always been very confusingly misnamed, so rename
it to submit_bio_noacct to make it clear that it is submit_bio minus
accounting and a few checks.
Signed-off-by: Christoph Hellwig
---
Documentation/block/biodoc.rst| 2 +-
.../fault-injection/fault
Instead of setting up the queuedata as well just use one private data
field.
Signed-off-by: Christoph Hellwig
---
drivers/md/dm.c | 3 +--
1 file changed, 1 insertion(+), 2 deletions(-)
diff --git a/drivers/md/dm.c b/drivers/md/dm.c
index e44473fe0f4873..c8d91f271c272e 100644
--- a/drivers/md
Instead of setting up the queuedata as well just use one private data
field.
Signed-off-by: Christoph Hellwig
---
drivers/block/null_blk_main.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/block/null_blk_main.c b/drivers/block/null_blk_main.c
index 82259242b9b5c9
Nothing in bcache actually uses the ->queuedata field.
Signed-off-by: Christoph Hellwig
---
drivers/md/bcache/super.c | 1 -
1 file changed, 1 deletion(-)
diff --git a/drivers/md/bcache/super.c b/drivers/md/bcache/super.c
index 2014016f9a60d3..21aa168113d30b 100644
--- a/drivers/md/bca
Split out a __submit_bio_noacct helper for the actual de-recursion
algorithm, and simplify the loop by using a continue when we can't
enter the queue for a bio.
Signed-off-by: Christoph Hellwig
---
block/blk-core.c | 143 +--
1 file change
Instead of setting up the queuedata as well just use one private data
field.
Signed-off-by: Christoph Hellwig
---
drivers/block/zram/zram_drv.c | 3 +--
1 file changed, 1 insertion(+), 2 deletions(-)
diff --git a/drivers/block/zram/zram_drv.c b/drivers/block/zram/zram_drv.c
index
The variable is only used once, so just open code the bio_sector()
there.
Signed-off-by: Christoph Hellwig
---
block/blk-core.c | 3 +--
1 file changed, 1 insertion(+), 2 deletions(-)
diff --git a/block/blk-core.c b/block/blk-core.c
index 37435d0d433564..28f60985dc75cc 100644
--- a/block/blk
For blk-mq drivers bios can only be inserted for the same queue. So
bypass the complicated sorting logic in __submit_bio_noacct with
a blk-mq simpler submission helper.
Signed-off-by: Christoph Hellwig
---
block/blk-core.c | 30 ++
1 file changed, 30 insertions
Hi Jens,
this series moves the make_request_fn method into block_device_operations
with the much more descriptive ->submit_bio name. It then also gives
generic_make_request a more descriptive name, and further optimize the
path to issue to blk-mq, removing the need for the direct_make_request
byp
Instead of setting up the queuedata as well just use one private data
field.
Signed-off-by: Christoph Hellwig
---
drivers/block/umem.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/drivers/block/umem.c b/drivers/block/umem.c
index 1e2aa5ae27963c..5498f1cf36b3fe 100644
All registers disks must have a valid queue pointer, so don't bother to
log a warning for that case.
Signed-off-by: Christoph Hellwig
---
block/blk-core.c | 12 +---
1 file changed, 1 insertion(+), 11 deletions(-)
diff --git a/block/blk-core.c b/block/blk-core.c
index 95dca7453
derived pretty trivially from the bio.
Signed-off-by: Christoph Hellwig
---
Documentation/block/biodoc.rst| 2 +-
.../block/writeback_cache_control.rst | 2 +-
arch/m68k/emu/nfblock.c | 5 +-
arch/xtensa/platforms/iss/simdisk.c | 5
Instead of setting up the queuedata as well just use one private data
field.
Signed-off-by: Christoph Hellwig
---
drivers/block/drbd/drbd_main.c | 1 -
drivers/block/drbd/drbd_req.c | 2 +-
2 files changed, 1 insertion(+), 2 deletions(-)
diff --git a/drivers/block/drbd/drbd_main.c b/drivers
Now that submit_bio_noacct has a decent blk-mq fast path there is no
more need for this bypass.
Signed-off-by: Christoph Hellwig
---
block/blk-core.c | 28
drivers/md/dm.c | 5 +
drivers/nvme/host/multipath.c | 2 +-
include/linux
The queue can be trivially derived from the bio, so pass one less
argument.
Signed-off-by: Christoph Hellwig
---
block/blk-merge.c | 21 ++---
block/blk-mq.c| 2 +-
block/blk.h | 3 +--
drivers/block/drbd/drbd_req.c | 2
Instead of setting up the queuedata as well just use one private data
field.
Signed-off-by: Christoph Hellwig
---
arch/xtensa/platforms/iss/simdisk.c | 4 +---
1 file changed, 1 insertion(+), 3 deletions(-)
diff --git a/arch/xtensa/platforms/iss/simdisk.c
b/arch/xtensa/platforms/iss/simdisk.c
Instead of setting up the queuedata as well just use one private data
field.
Signed-off-by: Christoph Hellwig
Reviewed-by: Geert Uytterhoeven
Acked-by: Geert Uytterhoeven
---
arch/m68k/emu/nfblock.c | 3 +--
1 file changed, 1 insertion(+), 2 deletions(-)
diff --git a/arch/m68k/emu/nfblock.c
Instead of setting up the queuedata as well just use one private data
field.
Signed-off-by: Christoph Hellwig
---
drivers/block/ps3vram.c | 3 +--
1 file changed, 1 insertion(+), 2 deletions(-)
diff --git a/drivers/block/ps3vram.c b/drivers/block/ps3vram.c
index 821d4d8b1d763e..5a1d1d137c7248
Instead of setting up the queuedata as well just use one private data
field.
Signed-off-by: Christoph Hellwig
---
drivers/block/rsxx/dev.c | 5 +
1 file changed, 1 insertion(+), 4 deletions(-)
diff --git a/drivers/block/rsxx/dev.c b/drivers/block/rsxx/dev.c
index 3ba07ab30c84f5
On Thu, Jul 02, 2020 at 10:10:10AM -0400, Qian Cai wrote:
> On Mon, Jun 29, 2020 at 09:39:45PM +0200, Christoph Hellwig wrote:
> > Split out a __submit_bio_noacct helper for the actual de-recursion
> > algorithm, and simplify the loop by using a continue when we can't
> >
On Mon, Jul 06, 2020 at 06:59:32PM -0700, Dan Williams wrote:
> The runtime firmware activation capability of Intel NVDIMM devices
> requires memory transactions to be disabled for 100s of microseconds.
> This timeout is large enough to cause in-flight DMA to fail and other
> application detectable
serts.
Otherwise looks good:
Reviewed-by: Christoph Hellwig
___
Linux-nvdimm mailing list -- linux-nvdimm@lists.01.org
To unsubscribe send an email to linux-nvdimm-le...@lists.01.org
pty line after the VM_BUG_ON_PGFLAGS assert to
keep the function readable? Maybe also add a comment on the assert,
as it isn't totally obvious.
Otherwise looks good:
Reviewed-by: Christoph Hellwig
___
Linux-nvdimm mailing list -- linux-nvdimm@lists.01.org
> @@ -269,20 +263,17 @@ iomap_readpage_actor(struct inode *inode, loff_t pos,
> loff_t length, void *data,
> if (ctx->bio && bio_end_sector(ctx->bio) == sector)
> is_contig = true;
>
> -
> /*
> - * If we start a new segment we need to increase the read count, and w
re involved.
Looks good (module the field naming as comment on the previous patch):
Reviewed-by: Christoph Hellwig
___
Linux-nvdimm mailing list -- linux-nvdimm@lists.01.org
To unsubscribe send an email to linux-nvdimm-le...@lists.01.org
On Tue, Aug 25, 2020 at 03:23:55PM -0700, Darrick J. Wong wrote:
> Sorry for my ultra-slow response to this. The u64 length seems ok to me
> (or uint64_t, I don't care all /that/ much), but using loff_t as a
> return type bothers me because I see that and think that this function
> is returning a
ver wants to support a page size larger than 2GB.
>
> Signed-off-by: Matthew Wilcox (Oracle)
Looks good:
Reviewed-by: Christoph Hellwig
___
Linux-nvdimm mailing list -- linux-nvdimm@lists.01.org
To unsubscribe send an email to linux-nvdimm-le...@lists.01.org
unlock_native_capacity is never called from check_disk_change(), and
while revalidate_disk can be called from it, it can also be called
from two other places at the moment.
Signed-off-by: Christoph Hellwig
---
Documentation/filesystems/locking.rst | 3 ---
1 file changed, 3 deletions(-)
diff
Hi Jens,
this series removes the revalidate_disk() function, which has been a
really odd duck in the last years. The prime reason why most people
use it is because it propagates a size change from the gendisk to
the block_device structure. But it also calls into the rather ill
defined ->revalida
_size helper that just performs the update of the
block device size from the gendisk one, and switch all drivers that do
not implement ->revalidate_disk to use the new helper instead of
revalidate_disk()
Signed-off-by: Christoph Hellwig
---
drivers/block/rbd.c | 2 +-
drivers/block/r
Replace bd_invalidate with a new BDEV_NEED_PART_SCAN flag in a bd_flags
variable to better describe the condition.
Signed-off-by: Christoph Hellwig
---
block/genhd.c | 2 +-
drivers/block/nbd.c | 8
fs/block_dev.c| 10 +-
include/linux
bd_invalidated event. revalidate_disk() on the other hand
is mostly used to propagate a size update from the gendisk to the block
device, which is entirely unrelated.
Signed-off-by: Christoph Hellwig
---
fs/block_dev.c | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)
diff --git a/fs
Instead of calling revalidate_disk just do the work directly by
calling sd_revalidate_disk, and revalidate_disk_size where needed.
Signed-off-by: Christoph Hellwig
---
drivers/scsi/sd.c | 6 --
1 file changed, 4 insertions(+), 2 deletions(-)
diff --git a/drivers/scsi/sd.c b/drivers/scsi
Remove the now unused helper.
Signed-off-by: Christoph Hellwig
---
drivers/md/md.h | 2 +-
fs/block_dev.c| 19 ---
include/linux/genhd.h | 1 -
3 files changed, 1 insertion(+), 21 deletions(-)
diff --git a/drivers/md/md.h b/drivers/md/md.h
index d9c4e6b7e9398d
called from the open code when first
opening the device. Which is of course totally pointless as we have
a valid size since the initial scan, and will get an updated view
through the asynchronous notifiation everytime the size changes.
Signed-off-by: Christoph Hellwig
---
drivers/nvme/host/core.
remove the revalidate_disk methods given that
it can only be triggered from add_disk, which is right before the
manual calls.
Signed-off-by: Christoph Hellwig
---
drivers/nvdimm/blk.c | 3 +--
drivers/nvdimm/btt.c | 3 +--
drivers/nvdimm/bus.c | 9 +++--
drivers/nvdimm/nd.h | 2 +-
drivers
Only virtio_blk and xen-blkfront set the revalidate argument to true,
and both do not implement the ->revalidate_disk method. So switch
to the helper that just updates the size instead.
Signed-off-by: Christoph Hellwig
---
block/genhd.c | 7 +++
include/linux/genhd.h | 4 ++--
> +static bool
> +xfs_is_write_fault(
> + struct vm_fault *vmf)
> +{
> + return vmf->flags & FAULT_FLAG_WRITE && vmf->vma->vm_flags & VM_SHARED;
> +}
This function does not look xfs specific at all. Why isn't it it in
fs.h? While we're at it the name sounds rather generic, and th
nvolved.
>
> Signed-off-by: Matthew Wilcox (Oracle)
Looks good,
Reviewed-by: Christoph Hellwig
___
Linux-nvdimm mailing list -- linux-nvdimm@lists.01.org
To unsubscribe send an email to linux-nvdimm-le...@lists.01.org
more than 4kB
> per page. Add a few debugging assertions.
>
> Signed-off-by: Matthew Wilcox (Oracle)
> Reviewed-by: Dave Chinner
Looks good,
Reviewed-by: Christoph Hellwig
___
Linux-nvdimm mailing list -- linux-nvdimm@lists.01.org
To uns
ally take
> advantage of it if there's a larger contiguous area.
Looks good,
Reviewed-by: Christoph Hellwig
___
Linux-nvdimm mailing list -- linux-nvdimm@lists.01.org
To unsubscribe send an email to linux-nvdimm-le...@lists.01.org
On Fri, Dec 15, 2017 at 06:04:37PM -0800, Dan Williams wrote:
> On Fri, Dec 15, 2017 at 6:09 AM, Christoph Hellwig wrote:
> > We can just pass this on instead of having to do a radix tree lookup
> > without proper locking 2 levels into the callchain.
> >
> > Signed-of
On Sun, Dec 17, 2017 at 09:34:11AM -0800, Dan Williams wrote:
> This is not racy, we'll catch the error on insert, and I think the
> extra debug information is useful for debugging a broken memory map or
> alignment math.
We can check for -ЕEXIST and print the warning, but it's a weird pattern
for
On Sun, Dec 17, 2017 at 10:51:56AM -0800, Dan Williams wrote:
> On Fri, Dec 15, 2017 at 6:09 AM, Christoph Hellwig wrote:
> > From: Logan Gunthorpe
> >
> > This new interface is similar to how struct device (and many others)
> > work. The caller initializes a '
Currently all calls to those functions are eliminated by the compiler when
CONFIG_ZONE_DEVICE is not set, but this soon won't be the case.
Signed-off-by: Christoph Hellwig
Reviewed-by: Dan Williams
---
include/linux/memremap.h | 18 ++
1 file changed, 14 insertions(
Only x86_64 and sh export this symbol, and it is not used by any
modular code.
Signed-off-by: Christoph Hellwig
Reviewed-by: Dan Williams
---
arch/sh/mm/init.c | 1 -
arch/x86/mm/init_64.c | 1 -
2 files changed, 2 deletions(-)
diff --git a/arch/sh/mm/init.c b/arch/sh/mm/init.c
index
This function isn't used by any modules, and is only to be called
from core MM code. This includes the calls for the add_pages wrapper
that might be inlined.
Signed-off-by: Christoph Hellwig
Reviewed-by: Dan Williams
---
mm/memory_hotplug.c | 1 -
1 file changed, 1 deletion(-)
diff --
Hi all,
this series started with two patches from Logan that now are in the
middle of the series to kill the memremap-internal pgmap structure
and to redo the dev_memreamp_pages interface to be better suitable
for future PCI P2P uses. I reviewed them and noticed that there
isn't really any good r
We can just pass this on instead of having to do a radix tree lookup
without proper locking 2 levels into the callchain.
Signed-off-by: Christoph Hellwig
---
arch/ia64/mm/init.c| 5 +++--
arch/powerpc/mm/mem.c | 5 +++--
arch/s390/mm/init.c| 5 +++--
arch/sh
Pass the vmem_altmap two levels down instead of needing a lookup.
Signed-off-by: Christoph Hellwig
Reviewed-by: Dan Williams
---
arch/ia64/mm/init.c| 9 +
include/linux/memory_hotplug.h | 2 +-
include/linux/mm.h | 4 ++--
kernel/memremap.c | 2
We can just pass this on instead of having to do a radix tree lookup
without proper locking 2 levels into the callchain.
Signed-off-by: Christoph Hellwig
Reviewed-by: Dan Williams
---
arch/ia64/mm/init.c| 4 ++--
arch/powerpc/mm/mem.c | 6 ++
arch/s390/mm/init.c
We can just pass this on instead of having to do a radix tree lookup
without proper locking a few levels into the callchain.
Signed-off-by: Christoph Hellwig
Reviewed-by: Dan Williams
---
arch/arm64/mm/mmu.c| 6 --
arch/ia64/mm/discontig.c | 3 ++-
arch/powerpc/mm
We can just pass this on instead of having to do a radix tree lookup
without proper locking a few levels into the callchain.
Signed-off-by: Christoph Hellwig
Reviewed-by: Dan Williams
---
arch/arm64/mm/mmu.c| 3 +-
arch/ia64/mm/discontig.c | 3 +-
arch/powerpc/mm/init_64.c
This is a pretty big function, which should be out of line in general,
and a no-op stub if CONFIG_ZONE_DEVICЕ is not set.
Signed-off-by: Christoph Hellwig
Reviewed-by: Logan Gunthorpe
Reviewed-by: Dan Williams
---
include/linux/memremap.h | 39 ---
kernel
There is only one caller of the trivial function find_dev_pagemap left,
so just merge it into the caller.
Signed-off-by: Christoph Hellwig
Reviewed-by: Dan Williams
---
kernel/memremap.c | 10 +-
1 file changed, 1 insertion(+), 9 deletions(-)
diff --git a/kernel/memremap.c b/kernel
r a more generally useful
'devm_memeremap_pages' interface.
Signed-off-by: Logan Gunthorpe
Signed-off-by: Christoph Hellwig
Reviewed-by: Dan Williams
---
include/linux/memremap.h | 5 ++--
kernel/memremap.c| 68 ++--
mm/hmm.c
: Christoph Hellwig
Reviewed-by: Logan Gunthorpe
Reviewed-by: Dan Williams
---
kernel/memremap.c | 17 +
mm/gup.c | 7 +--
2 files changed, 14 insertions(+), 10 deletions(-)
diff --git a/kernel/memremap.c b/kernel/memremap.c
index 3df6cd4ffb40..891c77487a6a 100644
--- a
No functional changes, just untangling the call chain and document
why the altmap is passed around the hotplug code.
Signed-off-by: Christoph Hellwig
Reviewed-by: Logan Gunthorpe
Reviewed-by: Dan Williams
---
arch/powerpc/mm/init_64.c | 5 -
arch/x86/mm/init_64.c | 5 -
include
There is no clear separation between the two, so merge them.
Signed-off-by: Christoph Hellwig
Reviewed-by: Logan Gunthorpe
Reviewed-by: Dan Williams
---
mm/sparse-vmemmap.c | 45 -
1 file changed, 16 insertions(+), 29 deletions(-)
diff --git a/mm
this way application specific members can be stored in a containing
struct.
This will be used by the P2P infrastructure and HMM could probably
be cleaned up to use it as well (instead of having it's own, similar
'hmm_devmem_pages_create' function).
Signed-off-by: Logan Gunthorp
__radix_tree_insert already checks for duplicates and returns -EEXIST in
that case, so remove the duplicate (and racy) duplicates check.
Signed-off-by: Christoph Hellwig
Reviewed-by: Logan Gunthorpe
---
kernel/memremap.c | 11 ---
1 file changed, 11 deletions(-)
diff --git a/kernel
All callers are gone now.
Signed-off-by: Christoph Hellwig
Reviewed-by: Dan Williams
---
include/linux/memremap.h | 9 -
kernel/memremap.c| 26 --
2 files changed, 35 deletions(-)
diff --git a/include/linux/memremap.h b/include/linux/memremap.h
index
On Sat, Dec 23, 2017 at 04:56:06PM -0800, Dan Williams wrote:
> In support of removing the VM_MIXEDMAP indication from DAX VMAs,
> introduce pfn_t_special() for drivers to indicate that _PAGE_SPECIAL
> should be used for DAX ptes. This also helps identify drivers like
> dccssblk that only want to u
101 - 200 of 990 matches
Mail list logo