Re: [GIT PULL] Block fixes for 4.14-rc2

2017-09-22 Thread Linus Torvalds
On Fri, Sep 22, 2017 at 9:32 AM, Jens Axboe wrote: > Hi Linus, > > A round of fixes for this series. This pull request contains: No, Jens. This isn't fixes. This is new code that does new things, or cleanups, or other random things mixed up with some fixes. Stop this fuckery

[PATCH v3 2/6] block: Convert RQF_PREEMPT into REQ_PREEMPT

2017-09-22 Thread Bart Van Assche
This patch does not change any functionality but makes the REQ_PREEMPT flag available to blk_get_request(). A later patch will add code to blk_get_request() that checks the REQ_PREEMPT flag. Note: the IDE sense_rq request is allocated statically so there is no blk_get_request() call that

[PATCH v3 3/6] block: Add the QUEUE_FLAG_PREEMPT_ONLY request queue flag

2017-09-22 Thread Bart Van Assche
This flag will be used in the next patch to let the block layer core know whether or not a SCSI request queue has been quiesced. A quiesced SCSI queue namely only processes RQF_PREEMPT requests. Signed-off-by: Bart Van Assche Cc: Ming Lei Cc:

[PATCH v3 1/6] md: Make md resync and reshape threads freezable

2017-09-22 Thread Bart Van Assche
Some people use the md driver on laptops and use the suspend and resume functionality. Since it is essential that submitting of new I/O requests stops before device quiescing starts, make the md resync and reshape threads freezable. Signed-off-by: Bart Van Assche Cc:

[PATCH v3 6/6] scsi-mq: Reduce suspend latency

2017-09-22 Thread Bart Van Assche
Avoid that it can take 200 ms too long to wait for requests to finish. Note: blk_mq_freeze_queue() uses a wait queue to wait for ongoing requests to finish. Signed-off-by: Bart Van Assche Cc: Martin K. Petersen Cc: Ming Lei

[PATCH v3 5/6] block: Make SCSI device suspend and resume work reliably

2017-09-22 Thread Bart Van Assche
It is essential during suspend and resume that neither the filesystem state nor the filesystem metadata in RAM changes. This is why while the hibernation image is being written or restored that SCSI devices are quiesced. The SCSI core quiesces devices through scsi_device_quiesce() and

[PATCH v3 0/6] Make SCSI device suspend and resume work reliably

2017-09-22 Thread Bart Van Assche
Hello Jens, It is known that during the resume following a hibernate sometimes the system hangs instead of coming up properly. This patch series fixes this problem. This patch series is an alternative for Ming Lei's "[PATCH V5 0/10] block/scsi: safe SCSI quiescing" patch series. The advantages of

[PATCH v3 4/6] scsi: Set QUEUE_FLAG_PREEMPT_ONLY while quiesced

2017-09-22 Thread Bart Van Assche
Make the quiesce state visible to the block layer for the next patch in this series. Signed-off-by: Bart Van Assche Cc: Martin K. Petersen Cc: Ming Lei Cc: Christoph Hellwig Cc: Hannes Reinecke

[GIT PULL] Block fixes for 4.14-rc2

2017-09-22 Thread Jens Axboe
Hi Linus, A round of fixes for this series. This pull request contains: - Two sets of NVMe pull requests from Christoph: - Fixes for the Fibre Channel host/target to fix spec compliance - Allow a zero keep alive timeout - Make the debug printk for broken SGLs

Re: [GIT PULL] another set of nvme fixes for 4.14-rc2

2017-09-22 Thread Jens Axboe
On 09/22/2017 11:55 AM, Christoph Hellwig wrote: > The fix for the target sqhdr fix is the critical one that we really want > before -rc2. But we've also accumulated a fair batch of small FC and > RDMA fixes as well. > > > The following changes since commit

[GIT PULL] another set of nvme fixes for 4.14-rc2

2017-09-22 Thread Christoph Hellwig
The fix for the target sqhdr fix is the critical one that we really want before -rc2. But we've also accumulated a fair batch of small FC and RDMA fixes as well. The following changes since commit cd9e0a08e4f6173f9d7a469cabd09938fc4f0e25: block: fix a crash caused by wrong API (2017-09-21

Re: [PATCH] dm-mpath: return DM_MAPIO_REQUEUE in case of rq allocation failure

2017-09-22 Thread Bart Van Assche
On Sat, 2017-09-23 at 01:44 +0800, Ming Lei wrote: > On Fri, Sep 22, 2017 at 03:06:16PM +, Bart Van Assche wrote: > > On Fri, 2017-09-22 at 09:35 +0800, Ming Lei wrote: > > > + /* > > > + * blk-mq's SCHED_RESTART can cover this requeue, so > > > + * we needn't to deal

Re: [PATCH] dm-mpath: return DM_MAPIO_REQUEUE in case of rq allocation failure

2017-09-22 Thread Ming Lei
On Fri, Sep 22, 2017 at 03:06:16PM +, Bart Van Assche wrote: > On Fri, 2017-09-22 at 09:35 +0800, Ming Lei wrote: > > + /* > > +* blk-mq's SCHED_RESTART can cover this requeue, so > > +* we needn't to deal with it by DELAY_REQUEUE. More > > +*

[PATCH v4] blk-mq: fix nr_requests wrong value when modify it from sysfs

2017-09-22 Thread weiping zhang
if blk-mq use "none" io scheduler, nr_request get a wrong value when input a number > tag_set->queue_depth. blk_mq_tag_update_depth will get the smaller one min(nr, set->queue_depth), and then q->nr_request get a wrong value. Reproduce: echo none > /sys/block/nvme0n1/queue/scheduler echo 100

Re: [PATCH] dm-mpath: return DM_MAPIO_REQUEUE in case of rq allocation failure

2017-09-22 Thread Bart Van Assche
On Fri, 2017-09-22 at 09:35 +0800, Ming Lei wrote: > + /* > + * blk-mq's SCHED_RESTART can cover this requeue, so > + * we needn't to deal with it by DELAY_REQUEUE. More > + * importantly, we have to return DM_MAPIO_REQUEUE > + * so

Re: [PATCH 9/9] nvme: implement multipath access to nvme subsystems

2017-09-22 Thread Keith Busch
On Mon, Sep 18, 2017 at 04:14:53PM -0700, Christoph Hellwig wrote: > +static void nvme_failover_req(struct request *req) > +{ > + struct nvme_ns *ns = req->q->queuedata; > + unsigned long flags; > + > + spin_lock_irqsave(>head->requeue_lock, flags); > +

Re: [PATCH V6 00/18] blk-throttle: add .low limit

2017-09-22 Thread Paolo Valente
> Il giorno 05 set 2017, alle ore 23:02, Shaohua Li ha > scritto: > > On Thu, Aug 31, 2017 at 09:24:23AM +0200, Paolo VALENTE wrote: >> >>> Il giorno 15 gen 2017, alle ore 04:42, Shaohua Li ha scritto: >>> >>> Hi, >>> >>> cgroup still lacks a good

Re: [PATCH V9 01/15] mmc: core: Remove unnecessary host claim

2017-09-22 Thread Linus Walleij
On Fri, Sep 22, 2017 at 2:36 PM, Adrian Hunter wrote: > Callers already have the host claimed, so remove the unnecessary > calls to mmc_claim_host() and mmc_release_host(). > > Signed-off-by: Adrian Hunter Good catch. Reviewed-by: Linus Walleij

Re: [PATCH V8 08/14] mmc: core: Add parameter use_blk_mq

2017-09-22 Thread Linus Walleij
On Fri, Sep 22, 2017 at 3:30 PM, Adrian Hunter wrote: > On 21/09/17 12:47, Ulf Hansson wrote: >> I asume the goal of adding this option is to enable us to move slowly >> forward. In general that might be a good idea, however for this >> particular case I am not sure. >>

Re: [PATCH V8 08/14] mmc: core: Add parameter use_blk_mq

2017-09-22 Thread Adrian Hunter
On 21/09/17 12:47, Ulf Hansson wrote: > On 13 September 2017 at 13:40, Adrian Hunter wrote: >> Until mmc has blk-mq support fully implemented and tested, add a >> parameter use_blk_mq, default to false unless config option MMC_MQ_DEFAULT >> is selected. >> >>

[PATCH V9 01/15] mmc: core: Remove unnecessary host claim

2017-09-22 Thread Adrian Hunter
Callers already have the host claimed, so remove the unnecessary calls to mmc_claim_host() and mmc_release_host(). Signed-off-by: Adrian Hunter --- drivers/mmc/core/mmc_ops.c | 5 + 1 file changed, 1 insertion(+), 4 deletions(-) diff --git

[PATCH V9 02/15] mmc: core: Introduce host claiming by context

2017-09-22 Thread Adrian Hunter
Currently the host can be claimed by a task. Change this so that the host can be claimed by a context that may or may not be a task. This provides for the host to be claimed by a block driver queue to support blk-mq, while maintaining compatibility with the existing use of mmc_claim_host().

[PATCH V9 03/15] mmc: core: Add support for handling CQE requests

2017-09-22 Thread Adrian Hunter
Add core support for handling CQE requests, including starting, completing and recovering. Signed-off-by: Adrian Hunter --- drivers/mmc/core/core.c | 163 +-- drivers/mmc/core/core.h | 4 ++ include/linux/mmc/host.h | 2

[PATCH V9 04/15] mmc: mmc: Enable Command Queuing

2017-09-22 Thread Adrian Hunter
Enable the Command Queue if the host controller supports a command queue engine. It is not compatible with Packed Commands, so make a note of that in the comment. Signed-off-by: Adrian Hunter --- drivers/mmc/core/mmc.c | 17 + 1 file changed, 17

[PATCH V9 05/15] mmc: mmc: Enable CQE's

2017-09-22 Thread Adrian Hunter
Enable or disable CQE when a card is added or removed respectively. Signed-off-by: Adrian Hunter --- drivers/mmc/core/bus.c | 7 +++ drivers/mmc/core/mmc.c | 12 2 files changed, 19 insertions(+) diff --git a/drivers/mmc/core/bus.c

[PATCH V9 06/15] mmc: block: Use local variables in mmc_blk_data_prep()

2017-09-22 Thread Adrian Hunter
Use local variables in mmc_blk_data_prep() in preparation for adding CQE support which doesn't use the output variables. Signed-off-by: Adrian Hunter --- drivers/mmc/core/block.c | 29 ++--- 1 file changed, 18 insertions(+), 11 deletions(-) diff

[PATCH V9 07/15] mmc: block: Prepare CQE data

2017-09-22 Thread Adrian Hunter
Enhance mmc_blk_data_prep() to support CQE requests. That means adding some things that for non-CQE requests would be encoded into the command arguments - such as the block address, reliable-write flag, and data tag flag. Also the request tag is needed to provide the command queue task id, and a

[PATCH V9 09/15] mmc: core: Add parameter use_blk_mq

2017-09-22 Thread Adrian Hunter
Until mmc has blk-mq support fully implemented and tested, add a parameter use_blk_mq, default to false unless config option MMC_MQ_DEFAULT is selected. Signed-off-by: Adrian Hunter --- drivers/mmc/Kconfig | 11 +++ drivers/mmc/core/core.c | 7 +++

[PATCH V9 08/15] mmc: block: Factor out mmc_setup_queue()

2017-09-22 Thread Adrian Hunter
Factor out some common code that will also be used with blk-mq. Signed-off-by: Adrian Hunter --- drivers/mmc/core/queue.c | 39 --- 1 file changed, 24 insertions(+), 15 deletions(-) diff --git a/drivers/mmc/core/queue.c

[PATCH V9 13/15] mmc: block: Add CQE and blk-mq support

2017-09-22 Thread Adrian Hunter
Add CQE support to the block driver, including: - optionally using DCMD for flush requests - "manually" issuing discard requests - issuing read / write requests to the CQE - supporting block-layer timeouts - handling recovery - supporting re-tuning CQE offers 25% - 50%

[PATCH V9 12/15] mmc: core: Export mmc_retune_hold_now() and mmc_retune_release()

2017-09-22 Thread Adrian Hunter
Export mmc_retune_hold_now() and mmc_retune_release() so they can be used by the block driver. Signed-off-by: Adrian Hunter --- drivers/mmc/core/host.c | 7 +-- drivers/mmc/core/host.h | 7 ++- 2 files changed, 7 insertions(+), 7 deletions(-) diff --git

[PATCH V9 11/15] mmc: core: Export mmc_start_request()

2017-09-22 Thread Adrian Hunter
Export mmc_start_request() so that the block driver can use it. Signed-off-by: Adrian Hunter --- drivers/mmc/core/core.c | 3 ++- drivers/mmc/core/core.h | 2 ++ 2 files changed, 4 insertions(+), 1 deletion(-) diff --git a/drivers/mmc/core/core.c

[PATCH V9 15/15] mmc: sdhci-pci: Add CQHCI support for Intel GLK

2017-09-22 Thread Adrian Hunter
Add CQHCI initialization and implement CQHCI operations for Intel GLK. Signed-off-by: Adrian Hunter --- drivers/mmc/host/Kconfig | 1 + drivers/mmc/host/sdhci-pci-core.c | 155 +- 2 files changed, 155 insertions(+), 1

[PATCH V9 00/15] mmc: Add Command Queue support

2017-09-22 Thread Adrian Hunter
Hi Here is V9 of the hardware command queue patches without the software command queue patches, now using blk-mq and now with blk-mq support for non-CQE I/O. HW CMDQ offers 25% - 50% better random multi-threaded I/O. I see a slight 2% drop in sequential read speed but no change to sequential

Re: [PATCH V8 01/14] mmc: core: Introduce host claiming by context

2017-09-22 Thread Linus Walleij
On Wed, Sep 13, 2017 at 1:40 PM, Adrian Hunter wrote: > Currently the host can be claimed by a task. Change this so that the host > can be claimed by a context that may or may not be a task. This provides > for the host to be claimed by a block driver queue to support

[Nbd] [PATCH] MAINTAINERS: update list for NBD

2017-09-22 Thread Wouter Verhelst
nbd-gene...@sourceforge.net becomes n...@other.debian.org, because sourceforge is just a spamtrap these days. Signed-off-by: Wouter Verhelst Reviewed-by: Josef Bacik --- MAINTAINERS | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/MAINTAINERS

Re: [PATCH 1/6] lightnvm: pblk: reuse pblk_gc_should_kick

2017-09-22 Thread Javier González
> On 22 Sep 2017, at 11.42, Rakesh Pandit wrote: > > On Fri, Sep 22, 2017 at 10:40:57AM +0200, Javier González wrote: >>> On 21 Sep 2017, at 13.25, Rakesh Pandit wrote: >>> >>> This is a trivial change which reuses pblk_gc_should_kick instead of >>> repeating it again in

Re: [PATCH 3/6] lightnvm: pblk: fix message if L2P MAP is in device

2017-09-22 Thread Javier González
Sure. Matias: Can you fix this when picking it up? Javier > On 22 Sep 2017, at 11.44, Rakesh Pandit wrote: > > On Fri, Sep 22, 2017 at 10:52:19AM +0200, Javier González wrote: >>> On 21 Sep 2017, at 13.26, Rakesh Pandit wrote: >>> >>> This usually

Re: [PATCH] Support for secure erase functionality

2017-09-22 Thread Máté Horváth
Dear Johannes Thumshirn, > How can this work with CoW filesystems? Because we are a layer below filesystems, that depends on the actual implementation. If the discards are issued to the right sectors on the drive, we write into those sectors. >> Built against torvalds/linux > > This should go

Re: [PATCH 1/2 v6] mmc: block: Convert RPMB to a character device

2017-09-22 Thread Ulf Hansson
On 20 September 2017 at 10:02, Linus Walleij wrote: > The RPMB partition on the eMMC devices is a special area used > for storing cryptographically safe information signed by a > special secret key. To write and read records from this special > area, authentication is

Re: [PATCH 2/2 v6] mmc: block: Delete mmc_access_rpmb()

2017-09-22 Thread Ulf Hansson
On 20 September 2017 at 10:02, Linus Walleij wrote: > This function is used by the block layer queue to bail out of > requests if the current request is towards an RPMB > "block device". > > This was done to avoid boot time scanning of this "block > device" which was

Re: [PATCH 3/6] lightnvm: pblk: fix message if L2P MAP is in device

2017-09-22 Thread Rakesh Pandit
On Fri, Sep 22, 2017 at 10:52:19AM +0200, Javier González wrote: > > On 21 Sep 2017, at 13.26, Rakesh Pandit wrote: > > > > This usually happens if we are developing with qemu and ll2pmode has > > default value. Even in that case message seems wrong. > > > > Signed-off-by:

Re: [PATCH 1/6] lightnvm: pblk: reuse pblk_gc_should_kick

2017-09-22 Thread Rakesh Pandit
On Fri, Sep 22, 2017 at 10:40:57AM +0200, Javier González wrote: > > On 21 Sep 2017, at 13.25, Rakesh Pandit wrote: > > > > This is a trivial change which reuses pblk_gc_should_kick instead of > > repeating it again in pblk_rl_free_lines_inc. > > > > Signed-off-by: Rakesh Pandit

Re: [PATCH 5/6] lightnvm: pblk: print incompatible line version correctly

2017-09-22 Thread Javier González
> On 21 Sep 2017, at 13.28, Rakesh Pandit wrote: > > Correct it by coverting little endian to cpu endian and also define a > macro for line version so that maintenance is easy. > > Signed-off-by: Rakesh Pandit > --- > drivers/lightnvm/pblk-core.c | 2

Re: [PATCH 4/6] lightnvm: pblk: improve error message if down_timeout fails

2017-09-22 Thread Javier González
> On 21 Sep 2017, at 13.27, Rakesh Pandit wrote: > > The two pr_err messages are useless as they don't even differentiate > error code. > > Signed-off-by: Rakesh Pandit > --- > drivers/lightnvm/pblk-core.c | 12 ++-- > 1 file changed, 2

Re: [PATCH 3/6] lightnvm: pblk: fix message if L2P MAP is in device

2017-09-22 Thread Javier González
> On 21 Sep 2017, at 13.26, Rakesh Pandit wrote: > > This usually happens if we are developing with qemu and ll2pmode has > default value. Even in that case message seems wrong. > > Signed-off-by: Rakesh Pandit > --- > drivers/lightnvm/pblk-init.c | 2 +-

Re: [PATCH 2/6] lightnvm: pblk: protect line bitmap while submitting meta io

2017-09-22 Thread Javier González
> On 21 Sep 2017, at 13.26, Rakesh Pandit wrote: > > It seems pblk_dealloc_page would race against pblk_alloc_pages for > line bitmap for sector allocation. The chances are very low but might > as well protect the bitmap properly. It's not even in fast path. > >

Re: [PATCH 1/6] lightnvm: pblk: reuse pblk_gc_should_kick

2017-09-22 Thread Javier González
> On 21 Sep 2017, at 13.25, Rakesh Pandit wrote: > > This is a trivial change which reuses pblk_gc_should_kick instead of > repeating it again in pblk_rl_free_lines_inc. > > Signed-off-by: Rakesh Pandit > --- > drivers/lightnvm/pblk-core.c | 1 + >

Oops on the system startup in the function part_in_flight()

2017-09-22 Thread Krzysztof Kolasa
Hi all, This error stops my system (daily build, linux-next) : - Sep 21 22:09:00 krzysiek-asus1 kernel: [   31.189584] BUG: unable to handle kernel NULL pointer dereference at 00f8 Sep 21 22:09:00 krzysiek-asus1 kernel: [   31.189592] IP: part_in_flight+0x5/0x60 Sep 21