Re: [PATCH V4 05/15] blk-throttle: add downgrade logic

2016-11-22 Thread Shaohua Li
On Tue, Nov 22, 2016 at 04:42:00PM -0500, Tejun Heo wrote: > Hello, > > On Tue, Nov 22, 2016 at 04:21:21PM -0500, Tejun Heo wrote: > > 1. A cgroup and its high and max limits don't have much to do with > >other cgroups and their limits. I don't get how the choice between > >high and max

Re: [PATCH V4 07/15] blk-throttle: make throtl_slice tunable

2016-11-22 Thread Shaohua Li
On Tue, Nov 22, 2016 at 04:27:15PM -0500, Tejun Heo wrote: > Hello, > > On Mon, Nov 14, 2016 at 02:22:14PM -0800, Shaohua Li wrote: > > throtl_slice is important for blk-throttling. A lot of stuffes depend on > > it, for example, throughput measurement. It has 100ms default value, > > which is

Re: [PATCH V4 03/15] blk-throttle: configure bps/iops limit for cgroup in high limit

2016-11-22 Thread Shaohua Li
On Tue, Nov 22, 2016 at 03:16:43PM -0500, Tejun Heo wrote: > On Mon, Nov 14, 2016 at 02:22:10PM -0800, Shaohua Li wrote: > > each queue will have a state machine. Initially queue is in LIMIT_HIGH > > state, which means all cgroups will be throttled according to their high > > limit. After all

Re: [PATCH V4 05/15] blk-throttle: add downgrade logic

2016-11-22 Thread Tejun Heo
Hello, On Tue, Nov 22, 2016 at 04:21:21PM -0500, Tejun Heo wrote: > 1. A cgroup and its high and max limits don't have much to do with >other cgroups and their limits. I don't get how the choice between >high and max limits can be a td-wide state. Ah, okay, this combines with idle

Re: [PATCH V4 07/15] blk-throttle: make throtl_slice tunable

2016-11-22 Thread Tejun Heo
Hello, On Mon, Nov 14, 2016 at 02:22:14PM -0800, Shaohua Li wrote: > throtl_slice is important for blk-throttling. A lot of stuffes depend on > it, for example, throughput measurement. It has 100ms default value, > which is not appropriate for all disks. For example, for SSD we might > use a

Re: [PATCH V4 05/15] blk-throttle: add downgrade logic

2016-11-22 Thread Tejun Heo
Hello, On Mon, Nov 14, 2016 at 02:22:12PM -0800, Shaohua Li wrote: > +static unsigned long tg_last_high_overflow_time(struct throtl_grp *tg) > +{ > + struct throtl_service_queue *parent_sq; > + struct throtl_grp *parent = tg; > + unsigned long ret = __tg_last_high_overflow_time(tg); >

[PATCH][V5] nbd: add multi-connection support

2016-11-22 Thread Josef Bacik
NBD can become contended on its single connection. We have to serialize all writes and we can only process one read response at a time. Fix this by allowing userspace to provide multiple connections to a single nbd device. This coupled with block-mq drastically increases performance in

[PATCH v2 1/2] blk-mq: Fix failed allocation path when mapping queues

2016-11-22 Thread Gabriel Krisman Bertazi
In blk_mq_map_swqueue, there is a memory optimization that frees the tags of a queue that has gone unmapped. Later, if that hctx is remapped after another topology change, the tags need to be reallocated. If this allocation fails, a simple WARN_ON triggers, but the block layer ends up with an

[PATCH v2 2/2] blk-mq: Avoid memory reclaim when remapping queues

2016-11-22 Thread Gabriel Krisman Bertazi
While stressing memory and IO at the same time we changed SMT settings, we were able to consistently trigger deadlocks in the mm system, which froze the entire machine. I think that under memory stress conditions, the large allocations performed by blk_mq_init_rq_map may trigger a reclaim, which

Re: [PATCH][V4] nbd: add multi-connection support

2016-11-22 Thread Wouter Verhelst
Hi Josef, [cc to nbd-general added] On Thu, Nov 17, 2016 at 03:27:30PM -0500, Josef Bacik wrote: > NBD can become contended on its single connection. We have to serialize all > writes and we can only process one read response at a time. Fix this by > allowing userspace to provide multiple

Re: [PATCH 00/12] block: cleanup direct access to bvec table

2016-11-22 Thread Jens Axboe
On 11/11/2016 05:05 AM, Ming Lei wrote: Hi, This patchset cleans up direct access to bvec table. The 1st patch passes bvec table to bio_init(), so that direct access to bvec table in bio initialization is avoided. For other patches, most of them uses bio_add_page() to replace hardcode style

Re: [PATCH 1/1] block_dev: Fixed direct I/O bio sector calculation

2016-11-22 Thread Jens Axboe
On 11/21/2016 11:38 PM, Damien Le Moal wrote: A direct I/O alignment must be always checked against the device blocks size, but the I/O offset (bio->bi_iter.bi_sector must always use 512B sector unit, and not the actual logical block size. Oops indeed, that's not great... Added for 4.10.