All of lore.kernel.org
 help / color / mirror / Atom feed
From: Damien Le Moal <damien.lemoal@hgst.com>
To: Jens Axboe <axboe@kernel.dk>
Cc: <linux-block@vger.kernel.org>, <linux-scsi@vger.kernel.org>,
	Christoph Hellwig <hch@lst.de>,
	"Martin K . Petersen" <martin.petersen@oracle.com>,
	Hannes Reinecke <hare@suse.de>, Hannes Reinecke <hare@suse.com>,
	Damien Le Moal <damien.lemoal@hgst.com>
Subject: [PATCH v2 3/7] block: update chunk_sectors in blk_stack_limits()
Date: Mon, 26 Sep 2016 20:14:39 +0900	[thread overview]
Message-ID: <1474888483-29762-4-git-send-email-damien.lemoal@hgst.com> (raw)
In-Reply-To: <1474888483-29762-1-git-send-email-damien.lemoal@hgst.com>

From: Hannes Reinecke <hare@suse.de>

Signed-off-by: Hannes Reinecke <hare@suse.com>
Signed-off-by: Damien Le Moal <damien.lemoal@hgst.com>
---
 block/blk-settings.c | 4 ++++
 1 file changed, 4 insertions(+)

diff --git a/block/blk-settings.c b/block/blk-settings.c
index b1d5b7f..55369a6 100644
--- a/block/blk-settings.c
+++ b/block/blk-settings.c
@@ -631,6 +631,10 @@ int blk_stack_limits(struct queue_limits *t, struct queue_limits *b,
 			t->discard_granularity;
 	}
 
+	if (b->chunk_sectors)
+		t->chunk_sectors = min_not_zero(t->chunk_sectors,
+						b->chunk_sectors);
+
 	return ret;
 }
 EXPORT_SYMBOL(blk_stack_limits);
-- 
2.7.4

Western Digital Corporation (and its subsidiaries) E-mail Confidentiality Notice & Disclaimer:

This e-mail and any files transmitted with it may contain confidential or legally privileged information of WDC and/or its affiliates, and are intended solely for the use of the individual or entity to which they are addressed. If you are not the intended recipient, any disclosure, copying, distribution or any action taken or omitted to be taken in reliance on it, is prohibited. If you have received this e-mail in error, please notify the sender immediately and delete the e-mail in its entirety from your system.

WARNING: multiple messages have this Message-ID (diff)
From: Damien Le Moal <damien.lemoal@hgst.com>
To: Jens Axboe <axboe@kernel.dk>
Cc: linux-block@vger.kernel.org, linux-scsi@vger.kernel.org,
	Christoph Hellwig <hch@lst.de>,
	"Martin K . Petersen" <martin.petersen@oracle.com>,
	Hannes Reinecke <hare@suse.de>, Hannes Reinecke <hare@suse.com>,
	Damien Le Moal <damien.lemoal@hgst.com>
Subject: [PATCH v2 3/7] block: update chunk_sectors in blk_stack_limits()
Date: Mon, 26 Sep 2016 20:14:39 +0900	[thread overview]
Message-ID: <1474888483-29762-4-git-send-email-damien.lemoal@hgst.com> (raw)
In-Reply-To: <1474888483-29762-1-git-send-email-damien.lemoal@hgst.com>

From: Hannes Reinecke <hare@suse.de>

Signed-off-by: Hannes Reinecke <hare@suse.com>
Signed-off-by: Damien Le Moal <damien.lemoal@hgst.com>
---
 block/blk-settings.c | 4 ++++
 1 file changed, 4 insertions(+)

diff --git a/block/blk-settings.c b/block/blk-settings.c
index b1d5b7f..55369a6 100644
--- a/block/blk-settings.c
+++ b/block/blk-settings.c
@@ -631,6 +631,10 @@ int blk_stack_limits(struct queue_limits *t, struct queue_limits *b,
 			t->discard_granularity;
 	}
 
+	if (b->chunk_sectors)
+		t->chunk_sectors = min_not_zero(t->chunk_sectors,
+						b->chunk_sectors);
+
 	return ret;
 }
 EXPORT_SYMBOL(blk_stack_limits);
-- 
2.7.4


  parent reply	other threads:[~2016-09-26 11:14 UTC|newest]

Thread overview: 28+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2016-09-26 11:14 [PATCH v2 0/7] ZBC / Zoned block device support Damien Le Moal
2016-09-26 11:14 ` Damien Le Moal
2016-09-26 11:14 ` [PATCH v2 1/7] block: Add 'zoned' queue limit Damien Le Moal
2016-09-26 11:14   ` Damien Le Moal
2016-09-27 21:09   ` Shaun Tancheff
2016-09-26 11:14 ` [PATCH v2 2/7] blk-sysfs: Add 'chunk_sectors' to sysfs attributes Damien Le Moal
2016-09-26 11:14   ` Damien Le Moal
2016-09-27 21:10   ` Shaun Tancheff
2016-09-26 11:14 ` Damien Le Moal [this message]
2016-09-26 11:14   ` [PATCH v2 3/7] block: update chunk_sectors in blk_stack_limits() Damien Le Moal
2016-09-27 21:12   ` Shaun Tancheff
2016-09-26 11:14 ` [PATCH v2 4/7] block: Define zoned block device operations Damien Le Moal
2016-09-26 11:14   ` Damien Le Moal
2016-09-26 11:14 ` [PATCH v2 5/7] block: Implement support for zoned block devices Damien Le Moal
2016-09-26 11:14   ` Damien Le Moal
2016-09-27 18:51   ` [PATCH v3 " Shaun Tancheff
2016-09-26 11:14 ` [PATCH v2 6/7] sd: Implement support for ZBC devices Damien Le Moal
2016-09-26 11:14   ` Damien Le Moal
2016-09-27 21:08   ` Shaun Tancheff
2016-09-26 11:14 ` [PATCH v2 7/7] blk-zoned: implement ioctls Damien Le Moal
2016-09-26 11:14   ` Damien Le Moal
2016-09-26 16:37   ` Christoph Hellwig
2016-09-26 23:12     ` Shaun Tancheff
2016-09-27 18:24       ` Christoph Hellwig
2016-09-26 23:30     ` Damien Le Moal
2016-09-26 23:30       ` Damien Le Moal
2016-09-26 23:58       ` Shaun Tancheff
2016-09-26 23:58         ` Shaun Tancheff

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=1474888483-29762-4-git-send-email-damien.lemoal@hgst.com \
    --to=damien.lemoal@hgst.com \
    --cc=axboe@kernel.dk \
    --cc=hare@suse.com \
    --cc=hare@suse.de \
    --cc=hch@lst.de \
    --cc=linux-block@vger.kernel.org \
    --cc=linux-scsi@vger.kernel.org \
    --cc=martin.petersen@oracle.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.