From: Keith Busch Date: Wed, 10 Feb 2016 23:52:47 +0000 (-0700) Subject: block: Initialize max_dev_sectors to 0 X-Git-Tag: v4.1.12-92~105^2 X-Git-Url: https://www.infradead.org/git/?a=commitdiff_plain;h=f1f97765cdaeb36e8d8e279605ad856101b4ac76;p=users%2Fjedix%2Flinux-maple.git block: Initialize max_dev_sectors to 0 Orabug: 23615929 (commit 5f009d3f8e6685fe8c6215082c1696a08b411220 of upstream) The new queue limit is not used by the majority of block drivers, and should be initialized to 0 for the driver's requested settings to be used. Signed-off-by: Keith Busch Acked-by: Martin K. Petersen Reviewed-by: Sagi Grimberg Reviewed-by: Christoph Hellwig Signed-off-by: Jens Axboe Signed-off-by: Joe Jin --- diff --git a/block/blk-settings.c b/block/blk-settings.c index dc2e66e32b66..43f6eda76856 100644 --- a/block/blk-settings.c +++ b/block/blk-settings.c @@ -112,8 +112,8 @@ void blk_set_default_limits(struct queue_limits *lim) lim->max_integrity_segments = 0; lim->seg_boundary_mask = BLK_SEG_BOUNDARY_MASK; lim->max_segment_size = BLK_MAX_SEGMENT_SIZE; - lim->max_sectors = lim->max_dev_sectors = lim->max_hw_sectors = - BLK_SAFE_MAX_SECTORS; + lim->max_sectors = lim->max_hw_sectors = BLK_SAFE_MAX_SECTORS; + lim->max_dev_sectors = 0; lim->chunk_sectors = 0; lim->max_write_same_sectors = 0; lim->max_discard_sectors = 0;