mirror of
https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git
synced 2024-10-02 15:18:19 +00:00
target/rd: Set ramdisk as non rotational device
Since a RAM backend device is not really a rotational device, we set it as is_nonrot=1 which will be forwarded in VPD page 0xb1 (block device characteristics) response. Signed-off-by: Sagi Grimberg <sagig@mellanox.com> Signed-off-by: Nicholas Bellinger <nab@linux-iscsi.org>
This commit is contained in:
parent
3aa3c67b26
commit
5dacbfc934
1 changed files with 1 additions and 0 deletions
|
@ -333,6 +333,7 @@ static int rd_configure_device(struct se_device *dev)
|
||||||
dev->dev_attrib.hw_block_size = RD_BLOCKSIZE;
|
dev->dev_attrib.hw_block_size = RD_BLOCKSIZE;
|
||||||
dev->dev_attrib.hw_max_sectors = UINT_MAX;
|
dev->dev_attrib.hw_max_sectors = UINT_MAX;
|
||||||
dev->dev_attrib.hw_queue_depth = RD_MAX_DEVICE_QUEUE_DEPTH;
|
dev->dev_attrib.hw_queue_depth = RD_MAX_DEVICE_QUEUE_DEPTH;
|
||||||
|
dev->dev_attrib.is_nonrot = 1;
|
||||||
|
|
||||||
rd_dev->rd_dev_id = rd_host->rd_host_dev_id_count++;
|
rd_dev->rd_dev_id = rd_host->rd_host_dev_id_count++;
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue