Re: [RFC PATCH] blk-mq: fixup RESTART when queue becomes idle

2018-01-18 Thread Ming Lei
On Fri, Jan 19, 2018 at 05:09:46AM +, Bart Van Assche wrote: > On Fri, 2018-01-19 at 10:32 +0800, Ming Lei wrote: > > Now most of times both NVMe and SCSI won't return BLK_STS_RESOURCE, and > > it should be DM-only which returns STS_RESOURCE so often. > > That's wrong at least for SCSI. See al

Re: [RFC PATCH] blk-mq: fixup RESTART when queue becomes idle

2018-01-18 Thread Ming Lei
On Thu, Jan 18, 2018 at 09:02:45PM -0700, Jens Axboe wrote: > On 1/18/18 7:32 PM, Ming Lei wrote: > > On Thu, Jan 18, 2018 at 01:11:01PM -0700, Jens Axboe wrote: > >> On 1/18/18 11:47 AM, Bart Van Assche wrote: > This is all very tiresome. > >>> > >>> Yes, this is tiresome. It is very annoying

Re: [PATCH] dm rq: Avoid that request processing stalls sporadically

2018-01-18 Thread Ming Lei
On Thu, Jan 18, 2018 at 05:49:10PM -0700, Jens Axboe wrote: > On 1/18/18 5:35 PM, Ming Lei wrote: > > On Thu, Jan 18, 2018 at 05:24:29PM -0700, Jens Axboe wrote: > >> On 1/18/18 5:18 PM, Ming Lei wrote: > >>> On Fri, Jan 19, 2018 at 12:14:24AM +, Bart Van Assche wrote: > On Fri, 2018-01-19

Re: [PATCH v5 1/2] Return bytes transferred for partial direct I/O

2018-01-18 Thread Al Viro
On Thu, Jan 18, 2018 at 10:31:18PM -0800, Darrick J. Wong wrote: > On Fri, Jan 19, 2018 at 02:59:51PM +1100, Dave Chinner wrote: > > On Fri, Jan 19, 2018 at 02:13:53AM +, Al Viro wrote: > > > On Thu, Jan 18, 2018 at 06:57:40PM -0600, Goldwyn Rodrigues wrote: > > > > From: Goldwyn Rodrigues > >

Re: [PATCH v5 1/2] Return bytes transferred for partial direct I/O

2018-01-18 Thread Darrick J. Wong
On Fri, Jan 19, 2018 at 02:59:51PM +1100, Dave Chinner wrote: > On Fri, Jan 19, 2018 at 02:13:53AM +, Al Viro wrote: > > On Thu, Jan 18, 2018 at 06:57:40PM -0600, Goldwyn Rodrigues wrote: > > > From: Goldwyn Rodrigues > > > > > > In case direct I/O encounters an error midway, it returns the e

Re: [RFC PATCH] blk-mq: fixup RESTART when queue becomes idle

2018-01-18 Thread Bart Van Assche
On Fri, 2018-01-19 at 10:32 +0800, Ming Lei wrote: > Now most of times both NVMe and SCSI won't return BLK_STS_RESOURCE, and > it should be DM-only which returns STS_RESOURCE so often. That's wrong at least for SCSI. See also https://marc.info/?l=linux-block&m=151578329417076. Bart.

Re: [PATCH 2/2] xfs: remove assert to check bytes returned

2018-01-18 Thread Dave Chinner
On Fri, Jan 19, 2018 at 02:23:16AM -0200, Raphael Carvalho wrote: > On Fri, Jan 19, 2018 at 1:57 AM, Dave Chinner wrote: > > > > On Thu, Jan 18, 2018 at 06:57:41PM -0600, Goldwyn Rodrigues wrote: > > > From: Goldwyn Rodrigues > > > > > > Since we can return less than count in case of partial dire

Re: [PATCH 2/2] xfs: remove assert to check bytes returned

2018-01-18 Thread Raphael Carvalho
On Fri, Jan 19, 2018 at 1:57 AM, Dave Chinner wrote: > > On Thu, Jan 18, 2018 at 06:57:41PM -0600, Goldwyn Rodrigues wrote: > > From: Goldwyn Rodrigues > > > > Since we can return less than count in case of partial direct > > writes, remove the ASSERT. > > > > Signed-off-by: Goldwyn Rodrigues >

Re: [RFC PATCH] blk-mq: fixup RESTART when queue becomes idle

2018-01-18 Thread Jens Axboe
On 1/18/18 7:32 PM, Ming Lei wrote: > On Thu, Jan 18, 2018 at 01:11:01PM -0700, Jens Axboe wrote: >> On 1/18/18 11:47 AM, Bart Van Assche wrote: This is all very tiresome. >>> >>> Yes, this is tiresome. It is very annoying to me that others keep >>> introducing so many regressions in such impo

Re: [PATCH v5 1/2] Return bytes transferred for partial direct I/O

2018-01-18 Thread Dave Chinner
On Fri, Jan 19, 2018 at 02:13:53AM +, Al Viro wrote: > On Thu, Jan 18, 2018 at 06:57:40PM -0600, Goldwyn Rodrigues wrote: > > From: Goldwyn Rodrigues > > > > In case direct I/O encounters an error midway, it returns the error. > > Instead it should be returning the number of bytes transferred

Re: [PATCH v3 RESEND 2/2] blk-throttle: fix wrong initialization in case of dm device

2018-01-18 Thread Joseph Qi
Hi Mike, On 18/1/19 11:29, Mike Snitzer wrote: > On Thu, Jan 18 2018 at 10:09pm -0500, > Joseph Qi wrote: > >> From: Joseph Qi >> >> DM device sets QUEUE_FLAG_NONROT after the queue is registered. That is >> to mean, the previous initialization in blk_throtl_register_queue is >> wrong in this c

Re: [PATCH 2/2] xfs: remove assert to check bytes returned

2018-01-18 Thread Dave Chinner
On Thu, Jan 18, 2018 at 06:57:41PM -0600, Goldwyn Rodrigues wrote: > From: Goldwyn Rodrigues > > Since we can return less than count in case of partial direct > writes, remove the ASSERT. > > Signed-off-by: Goldwyn Rodrigues > --- > fs/xfs/xfs_file.c | 6 -- > 1 file changed, 6 deletions(-

Re: [PATCH v3 RESEND 2/2] blk-throttle: fix wrong initialization in case of dm device

2018-01-18 Thread Jens Axboe
On 1/18/18 8:29 PM, Mike Snitzer wrote: > On Thu, Jan 18 2018 at 10:09pm -0500, > Joseph Qi wrote: > >> From: Joseph Qi >> >> DM device sets QUEUE_FLAG_NONROT after the queue is registered. That is >> to mean, the previous initialization in blk_throtl_register_queue is >> wrong in this case. >>

Re: [PATCH v3 RESEND 2/2] blk-throttle: fix wrong initialization in case of dm device

2018-01-18 Thread Mike Snitzer
On Thu, Jan 18 2018 at 10:09pm -0500, Joseph Qi wrote: > From: Joseph Qi > > DM device sets QUEUE_FLAG_NONROT after the queue is registered. That is > to mean, the previous initialization in blk_throtl_register_queue is > wrong in this case. > Fix it by checking and then updating the info durin

[PATCH v3 RESEND 2/2] blk-throttle: fix wrong initialization in case of dm device

2018-01-18 Thread Joseph Qi
From: Joseph Qi DM device sets QUEUE_FLAG_NONROT after the queue is registered. That is to mean, the previous initialization in blk_throtl_register_queue is wrong in this case. Fix it by checking and then updating the info during root tg initialization as we don't have a better choice. Signed-of

Re: [PATCH 2/2] blk-mq: simplify queue mapping & schedule with each possisble CPU

2018-01-18 Thread jianchao.wang
Hi ming Sorry for delayed report this. On 01/17/2018 05:57 PM, Ming Lei wrote: > 2) hctx->next_cpu can become offline from online before __blk_mq_run_hw_queue > is run, there isn't warning, but once the IO is submitted to hardware, > after it is completed, how does the HBA/hw queue notify CPU sin

Re: [PATCH v3 RESEND 1/2] blk-throttle: track read and write request individually

2018-01-18 Thread Joseph Qi
Sure, I will resend it. Thanks. Joseph On 18/1/19 10:52, Jens Axboe wrote: > On 1/18/18 7:11 PM, Joseph Qi wrote: >> Hi Jens, >> Could you please pick the two pending patches for 4.16? >> They all have been reviewed by Shaohua. > > Sorry, I guess I forgot about this series. I picked up 1/2, > fo

Re: [PATCH v3 RESEND 1/2] blk-throttle: track read and write request individually

2018-01-18 Thread Jens Axboe
On 1/18/18 7:11 PM, Joseph Qi wrote: > Hi Jens, > Could you please pick the two pending patches for 4.16? > They all have been reviewed by Shaohua. Sorry, I guess I forgot about this series. I picked up 1/2, for some reason I don't have 2/2 and I can't find it on linux-block either. The thread onl

Re: [RFC PATCH] blk-mq: fixup RESTART when queue becomes idle

2018-01-18 Thread Ming Lei
On Thu, Jan 18, 2018 at 01:11:01PM -0700, Jens Axboe wrote: > On 1/18/18 11:47 AM, Bart Van Assche wrote: > >> This is all very tiresome. > > > > Yes, this is tiresome. It is very annoying to me that others keep > > introducing so many regressions in such important parts of the kernel. > > It is a

Re: [PATCH v5 1/2] Return bytes transferred for partial direct I/O

2018-01-18 Thread Al Viro
On Thu, Jan 18, 2018 at 06:57:40PM -0600, Goldwyn Rodrigues wrote: > From: Goldwyn Rodrigues > > In case direct I/O encounters an error midway, it returns the error. > Instead it should be returning the number of bytes transferred so far. > > Test case for filesystems (with ENOSPC): > 1. Create

Re: [PATCH v3 RESEND 1/2] blk-throttle: track read and write request individually

2018-01-18 Thread Joseph Qi
Hi Jens, Could you please pick the two pending patches for 4.16? They all have been reviewed by Shaohua. Thanks, Joseph On 18/1/8 20:05, Joseph Qi wrote: > A polite ping for the two pending patches... > > Thanks, > Joseph > > On 17/11/24 13:13, Jens Axboe wrote: >> On 11/23/2017 06:31 PM, Josep

[PATCH v5 1/2] Return bytes transferred for partial direct I/O

2018-01-18 Thread Goldwyn Rodrigues
From: Goldwyn Rodrigues In case direct I/O encounters an error midway, it returns the error. Instead it should be returning the number of bytes transferred so far. Test case for filesystems (with ENOSPC): 1. Create an almost full filesystem 2. Create a file, say /mnt/lastfile, until the filesyst

[PATCH 2/2] xfs: remove assert to check bytes returned

2018-01-18 Thread Goldwyn Rodrigues
From: Goldwyn Rodrigues Since we can return less than count in case of partial direct writes, remove the ASSERT. Signed-off-by: Goldwyn Rodrigues --- fs/xfs/xfs_file.c | 6 -- 1 file changed, 6 deletions(-) diff --git a/fs/xfs/xfs_file.c b/fs/xfs/xfs_file.c index 8601275cc5e6..8fc4dbf6691

Re: [PATCH] dm rq: Avoid that request processing stalls sporadically

2018-01-18 Thread Jens Axboe
On 1/18/18 5:35 PM, Ming Lei wrote: > On Thu, Jan 18, 2018 at 05:24:29PM -0700, Jens Axboe wrote: >> On 1/18/18 5:18 PM, Ming Lei wrote: >>> On Fri, Jan 19, 2018 at 12:14:24AM +, Bart Van Assche wrote: On Fri, 2018-01-19 at 08:11 +0800, Ming Lei wrote: > On Thu, Jan 18, 2018 at 08:37:0

Re: [PATCH] dm rq: Avoid that request processing stalls sporadically

2018-01-18 Thread Ming Lei
On Thu, Jan 18, 2018 at 05:24:29PM -0700, Jens Axboe wrote: > On 1/18/18 5:18 PM, Ming Lei wrote: > > On Fri, Jan 19, 2018 at 12:14:24AM +, Bart Van Assche wrote: > >> On Fri, 2018-01-19 at 08:11 +0800, Ming Lei wrote: > >>> On Thu, Jan 18, 2018 at 08:37:07AM -0800, Bart Van Assche wrote: > >>>

Re: dm rq: Avoid that request processing stalls sporadically

2018-01-18 Thread Bart Van Assche
On Fri, 2018-01-19 at 08:26 +0800, Ming Lei wrote: > No, this case won't return BLK_STS_RESOURCE. It's possible that my attempt to reverse engineer the latest blk-mq changes was wrong. But the queue stall is real and needs to be fixed. Bart.

Re: dm rq: Avoid that request processing stalls sporadically

2018-01-18 Thread Ming Lei
On Thu, Jan 18, 2018 at 05:13:53PM +, Bart Van Assche wrote: > On Thu, 2018-01-18 at 11:50 -0500, Mike Snitzer wrote: > > The issue you say it was originally intended to fix _should_ be > > addressed with this change: > > https://git.kernel.org/pub/scm/linux/kernel/git/device-mapper/linux-dm.gi

Re: [PATCH] dm rq: Avoid that request processing stalls sporadically

2018-01-18 Thread Jens Axboe
On 1/18/18 5:18 PM, Ming Lei wrote: > On Fri, Jan 19, 2018 at 12:14:24AM +, Bart Van Assche wrote: >> On Fri, 2018-01-19 at 08:11 +0800, Ming Lei wrote: >>> On Thu, Jan 18, 2018 at 08:37:07AM -0800, Bart Van Assche wrote: diff --git a/drivers/md/dm-rq.c b/drivers/md/dm-rq.c index f160

Re: [PATCH] dm rq: Avoid that request processing stalls sporadically

2018-01-18 Thread Bart Van Assche
On Fri, 2018-01-19 at 08:18 +0800, Ming Lei wrote: > On Fri, Jan 19, 2018 at 12:14:24AM +, Bart Van Assche wrote: > > On Fri, 2018-01-19 at 08:11 +0800, Ming Lei wrote: > > > On Thu, Jan 18, 2018 at 08:37:07AM -0800, Bart Van Assche wrote: > > > > diff --git a/drivers/md/dm-rq.c b/drivers/md/dm

Re: [PATCH] dm rq: Avoid that request processing stalls sporadically

2018-01-18 Thread Ming Lei
On Fri, Jan 19, 2018 at 12:14:24AM +, Bart Van Assche wrote: > On Fri, 2018-01-19 at 08:11 +0800, Ming Lei wrote: > > On Thu, Jan 18, 2018 at 08:37:07AM -0800, Bart Van Assche wrote: > > > diff --git a/drivers/md/dm-rq.c b/drivers/md/dm-rq.c > > > index f16096af879a..c59c59cfd2a5 100644 > > > -

Re: [PATCH] dm rq: Avoid that request processing stalls sporadically

2018-01-18 Thread Bart Van Assche
On Fri, 2018-01-19 at 08:11 +0800, Ming Lei wrote: > On Thu, Jan 18, 2018 at 08:37:07AM -0800, Bart Van Assche wrote: > > diff --git a/drivers/md/dm-rq.c b/drivers/md/dm-rq.c > > index f16096af879a..c59c59cfd2a5 100644 > > --- a/drivers/md/dm-rq.c > > +++ b/drivers/md/dm-rq.c > > @@ -761,6 +761,7 @

Re: [PATCH] dm rq: Avoid that request processing stalls sporadically

2018-01-18 Thread Ming Lei
On Thu, Jan 18, 2018 at 08:37:07AM -0800, Bart Van Assche wrote: > If the .queue_rq() implementation of a block driver returns > BLK_STS_RESOURCE then that block driver is responsible for > rerunning the queue once the condition that caused it to return > BLK_STS_RESOURCE has been cleared. The dm-m

Re: [RFC PATCH] blk-mq: fixup RESTART when queue becomes idle

2018-01-18 Thread Bart Van Assche
On Thu, 2018-01-18 at 15:39 -0700, Jens Axboe wrote: > When you do have a solid test case, please please submit a blktests > test case for it! This needs to be something we can regularly in > testing. Hello Jens, That sounds like a good idea to me. BTW, I think the reason why so far I can reprodu

Re: [RFC PATCH] blk-mq: fixup RESTART when queue becomes idle

2018-01-18 Thread Jens Axboe
On 1/18/18 3:35 PM, Laurence Oberman wrote: > On Thu, 2018-01-18 at 22:24 +, Bart Van Assche wrote: >> On Thu, 2018-01-18 at 17:18 -0500, Laurence Oberman wrote: >>> OK, I ran 5 at once of 5 separate mount points. >>> I am using 4k block sizes >>> Its solid consistent for me. No stalls no gaps.

Re: [RFC PATCH] blk-mq: fixup RESTART when queue becomes idle

2018-01-18 Thread Laurence Oberman
On Thu, 2018-01-18 at 22:24 +, Bart Van Assche wrote: > On Thu, 2018-01-18 at 17:18 -0500, Laurence Oberman wrote: > > OK, I ran 5 at once of 5 separate mount points. > > I am using 4k block sizes > > Its solid consistent for me. No stalls no gaps. > > Hi Laurence, > > That's great news and t

Re: [RFC PATCH] blk-mq: fixup RESTART when queue becomes idle

2018-01-18 Thread Bart Van Assche
On Thu, 2018-01-18 at 17:18 -0500, Laurence Oberman wrote: > OK, I ran 5 at once of 5 separate mount points. > I am using 4k block sizes > Its solid consistent for me. No stalls no gaps. Hi Laurence, That's great news and thank you for having shared this information but I think it should be menti

Re: [RFC PATCH] blk-mq: fixup RESTART when queue becomes idle

2018-01-18 Thread Bart Van Assche
On Thu, 2018-01-18 at 17:01 -0500, Mike Snitzer wrote: > And yet Laurence cannot reproduce any such lockups with your test... Hmm ... maybe I misunderstood Laurence but I don't think that Laurence has already succeeded at running an unmodified version of my tests. In one of the e-mails Laurence se

Re: [RFC PATCH] blk-mq: fixup RESTART when queue becomes idle

2018-01-18 Thread Laurence Oberman
On Thu, 2018-01-18 at 17:01 -0500, Mike Snitzer wrote: > On Thu, Jan 18 2018 at  4:39pm -0500, > Bart Van Assche wrote: > > > On Thu, 2018-01-18 at 16:23 -0500, Mike Snitzer wrote: > > > On Thu, Jan 18 2018 at  3:58P -0500, > > > Bart Van Assche wrote: > > > > > > > On Thu, 2018-01-18 at 15:48

Re: [RFC PATCH] blk-mq: fixup RESTART when queue becomes idle

2018-01-18 Thread Mike Snitzer
On Thu, Jan 18 2018 at 4:39pm -0500, Bart Van Assche wrote: > On Thu, 2018-01-18 at 16:23 -0500, Mike Snitzer wrote: > > On Thu, Jan 18 2018 at 3:58P -0500, > > Bart Van Assche wrote: > > > > > On Thu, 2018-01-18 at 15:48 -0500, Mike Snitzer wrote: > > > > For Bart's test the underlying scsi-

Re: [dm-devel] [RFC PATCH] blk-mq: fixup RESTART when queue becomes idle

2018-01-18 Thread Bart Van Assche
On Thu, 2018-01-18 at 16:23 -0500, Mike Snitzer wrote: > On Thu, Jan 18 2018 at 3:58P -0500, > Bart Van Assche wrote: > > > On Thu, 2018-01-18 at 15:48 -0500, Mike Snitzer wrote: > > > For Bart's test the underlying scsi-mq driver is what is regularly > > > hitting this case in __blk_mq_try_issu

Re: [RFC PATCH] blk-mq: fixup RESTART when queue becomes idle

2018-01-18 Thread Laurence Oberman
On Thu, 2018-01-18 at 16:23 -0500, Mike Snitzer wrote: > On Thu, Jan 18 2018 at  3:58P -0500, > Bart Van Assche wrote: > > > On Thu, 2018-01-18 at 15:48 -0500, Mike Snitzer wrote: > > > For Bart's test the underlying scsi-mq driver is what is > > > regularly > > > hitting this case in __blk_mq_tr

Re: [RFC PATCH] blk-mq: fixup RESTART when queue becomes idle

2018-01-18 Thread Mike Snitzer
On Thu, Jan 18 2018 at 3:58P -0500, Bart Van Assche wrote: > On Thu, 2018-01-18 at 15:48 -0500, Mike Snitzer wrote: > > For Bart's test the underlying scsi-mq driver is what is regularly > > hitting this case in __blk_mq_try_issue_directly(): > > > > if (blk_mq_hctx_stopped(hctx) || blk

Re: [RFC PATCH] blk-mq: fixup RESTART when queue becomes idle

2018-01-18 Thread Bart Van Assche
On Thu, 2018-01-18 at 15:48 -0500, Mike Snitzer wrote: > For Bart's test the underlying scsi-mq driver is what is regularly > hitting this case in __blk_mq_try_issue_directly(): > > if (blk_mq_hctx_stopped(hctx) || blk_queue_quiesced(q)) Hello Mike, That code path is not the code path th

Re: [RFC PATCH] blk-mq: fixup RESTART when queue becomes idle

2018-01-18 Thread Mike Snitzer
On Thu, Jan 18 2018 at 3:11pm -0500, Jens Axboe wrote: > On 1/18/18 11:47 AM, Bart Van Assche wrote: > >> This is all very tiresome. > > > > Yes, this is tiresome. It is very annoying to me that others keep > > introducing so many regressions in such important parts of the kernel. > > It is als

Re: [RFC PATCH] blk-mq: fixup RESTART when queue becomes idle

2018-01-18 Thread Jens Axboe
On 1/18/18 11:47 AM, Bart Van Assche wrote: >> This is all very tiresome. > > Yes, this is tiresome. It is very annoying to me that others keep > introducing so many regressions in such important parts of the kernel. > It is also annoying to me that I get blamed if I report a regression > instead

Re: [PATCH v3 0/2] block: enforce ioctl(BLKROSET) and set_disk_ro()

2018-01-18 Thread Jens Axboe
On 1/11/18 6:09 AM, Ilya Dryomov wrote: > Hello, > > I was doing some cleanup work on rbd BLKROSET handler and discovered > that we ignore partition rw/ro setting (hd_struct->policy) for pretty > much everything but straight writes. > > David (CCed) has blktests patches standing by. > > (Another

Re: [RFC] blk-throttle: export io_serviced_recursive, io_service_bytes_recursive

2018-01-18 Thread Jens Axboe
On 12/11/17 7:56 AM, weiping zhang wrote: > export these two interface for cgroup-v1. Applied, thanks. -- Jens Axboe

Re: [PATCH v2 0/3] Avoid that blk_{un,}register_queue() trigger lock inversion

2018-01-18 Thread Jens Axboe
On 1/17/18 12:48 PM, Bart Van Assche wrote: > Hello Jens, > > The three patches in this series are what I came up with after having > analyzed a lockdep complaint triggered by blk_unregister_queue(). Please > consider these patches for kernel v4.16. Thanks Bart, applied. -- Jens Axboe

Re: [RFC PATCH] blk-mq: fixup RESTART when queue becomes idle

2018-01-18 Thread Bart Van Assche
On Thu, 2018-01-18 at 13:30 -0500, Mike Snitzer wrote: > 1%!? Where are you getting that number? Ming has detailed more > significant performance gains than 1%.. and not just on lpfc (though you > keep seizing on lpfc because of the low queue_depth of 3). That's what I derived from the numbers y

Re: [RFC PATCH] blk-mq: fixup RESTART when queue becomes idle

2018-01-18 Thread Mike Snitzer
On Thu, Jan 18 2018 at 12:20pm -0500, Bart Van Assche wrote: > On Thu, 2018-01-18 at 12:03 -0500, Mike Snitzer wrote: > > On Thu, Jan 18 2018 at 11:50am -0500, > > Bart Van Assche wrote: > > > My comments about the above are as follows: > > > - It can take up to q->rq_timeout jiffies after a .qu

[GIT PULL] Two NVMe fixes for 4.15 final

2018-01-18 Thread Jens Axboe
Hi Linus, Two important fixes for the sgl support for nvme that is new in this series. Please pull. git://git.kernel.dk/linux-block.git for-linus Christoph Hellwig (1): nvme-pci: take sglist coalescing in dma_map_sg into

Re: [PATCH v5] Return bytes transferred for partial direct I/O

2018-01-18 Thread Darrick J. Wong
On Fri, Jan 05, 2018 at 06:15:55AM -0600, Goldwyn Rodrigues wrote: > > > On 01/04/2018 08:10 PM, Darrick J. Wong wrote: > > On Wed, Nov 22, 2017 at 06:29:01AM -0600, Goldwyn Rodrigues wrote: > >> From: Goldwyn Rodrigues > >> > >> In case direct I/O encounters an error midway, it returns the erro

Re: [RFC PATCH] blk-mq: fixup RESTART when queue becomes idle

2018-01-18 Thread Bart Van Assche
On Thu, 2018-01-18 at 12:03 -0500, Mike Snitzer wrote: > On Thu, Jan 18 2018 at 11:50am -0500, > Bart Van Assche wrote: > > My comments about the above are as follows: > > - It can take up to q->rq_timeout jiffies after a .queue_rq() > > implementation returned BLK_STS_RESOURCE before blk_mq_tim

Re: dm rq: Avoid that request processing stalls sporadically

2018-01-18 Thread Bart Van Assche
On Thu, 2018-01-18 at 11:50 -0500, Mike Snitzer wrote: > The issue you say it was originally intended to fix _should_ be > addressed with this change: > https://git.kernel.org/pub/scm/linux/kernel/git/device-mapper/linux-dm.git/commit/?h=dm-4.16&id=4dd6edd23e7ea971efddc303f9e67eb79e95808e Hello Mi

Re: [RFC PATCH] blk-mq: fixup RESTART when queue becomes idle

2018-01-18 Thread Mike Snitzer
On Thu, Jan 18 2018 at 11:50am -0500, Bart Van Assche wrote: > On 01/17/18 18:41, Ming Lei wrote: > >BLK_STS_RESOURCE can be returned from driver when any resource > >is running out of. And the resource may not be related with tags, > >such as kmalloc(GFP_ATOMIC), when queue is idle under this ki

Re: dm rq: Avoid that request processing stalls sporadically

2018-01-18 Thread Mike Snitzer
On Thu, Jan 18 2018 at 11:37am -0500, Bart Van Assche wrote: > If the .queue_rq() implementation of a block driver returns > BLK_STS_RESOURCE then that block driver is responsible for > rerunning the queue once the condition that caused it to return > BLK_STS_RESOURCE has been cleared. The dm-mpa

Re: [RFC PATCH] blk-mq: fixup RESTART when queue becomes idle

2018-01-18 Thread Bart Van Assche
On 01/17/18 18:41, Ming Lei wrote: BLK_STS_RESOURCE can be returned from driver when any resource is running out of. And the resource may not be related with tags, such as kmalloc(GFP_ATOMIC), when queue is idle under this kind of BLK_STS_RESOURCE, restart can't work any more, then IO hang may be

[PATCH] dm rq: Avoid that request processing stalls sporadically

2018-01-18 Thread Bart Van Assche
If the .queue_rq() implementation of a block driver returns BLK_STS_RESOURCE then that block driver is responsible for rerunning the queue once the condition that caused it to return BLK_STS_RESOURCE has been cleared. The dm-mpath driver tells the dm core to requeue a request if e.g. not enough mem

Re: [PATCH v2 3/3] block: Protect less code with sysfs_lock in blk_{un,}register_queue()

2018-01-18 Thread Christoph Hellwig
Looks good, Reviewed-by: Christoph Hellwig

Re: [PATCH v2 2/3] block: Document scheduler modification locking requirements

2018-01-18 Thread Christoph Hellwig
Looks fine, Reviewed-by: Christoph Hellwig

Re: [PATCH v2 1/3] block: Unexport elv_register_queue() and elv_unregister_queue()

2018-01-18 Thread Christoph Hellwig
Looks fine, Reviewed-by: Christoph Hellwig

Re: [RFC] blk-throttle: export io_serviced_recursive, io_service_bytes_recursive

2018-01-18 Thread weiping zhang
2017-12-11 23:17 GMT+08:00 Tejun Heo : > On Mon, Dec 11, 2017 at 10:56:25PM +0800, weiping zhang wrote: >> export these two interface for cgroup-v1. >> >> Signed-off-by: weiping zhang > > Acked-by: Tejun Heo > Hi Jens, Have you got time to check this patch ? Thanks > Thanks. > > -- > tejun

Re: [PATCH BUGFIX/IMPROVEMENT 0/2] block, bfq: two pending patches

2018-01-18 Thread Jens Axboe
On 1/13/18 4:05 AM, Paolo Valente wrote: > Hi Jens, > here are again the two pending patches you asked me to resend [1]. One > of them, fixing read-starvation problems, was accompanied by a cover > letter. I'm pasting the content of that cover letter below. > > The patch addresses (serious) starva

Re: [PATCH v3 0/2] block: enforce ioctl(BLKROSET) and set_disk_ro()

2018-01-18 Thread Ilya Dryomov
On Thu, Jan 11, 2018 at 2:09 PM, Ilya Dryomov wrote: > Hello, > > I was doing some cleanup work on rbd BLKROSET handler and discovered > that we ignore partition rw/ro setting (hd_struct->policy) for pretty > much everything but straight writes. > > David (CCed) has blktests patches standing by. >

Re: [PATCH BUGFIX/IMPROVEMENT 0/2] block, bfq: two pending patches

2018-01-18 Thread Paolo Valente
> Il giorno 13 gen 2018, alle ore 12:05, Paolo Valente > ha scritto: > > Hi Jens, > here are again the two pending patches you asked me to resend [1]. One > of them, fixing read-starvation problems, was accompanied by a cover > letter. I'm pasting the content of that cover letter below. > > T