Skip to content

Commit

Permalink
target/file: Bump FD_MAX_SECTORS to 2048 to handle 1M sized I/Os
Browse files Browse the repository at this point in the history
This patch bumps the default FILEIO backend FD_MAX_SECTORS value from
1024 -> 2048 in order to allow block_size=512 to handle 1M sized I/Os.

The current default rejects I/Os larger than 512K in sbc_parse_cdb():

[12015.915146] SCSI OP 2ah with too big sectors 1347 exceeds backend
hw_max_sectors: 1024
[12015.977744] SCSI OP 2ah with too big sectors 2048 exceeds backend
hw_max_sectors: 1024

This issue is present in >= v3.5 based kernels, introduced after the
removal of se_task logic.

Reported-by: Viljami Ilola <azmulx@netikka.fi>
Cc: <stable@vger.kernel.org>
Signed-off-by: Nicholas Bellinger <nab@linux-iscsi.org>
  • Loading branch information
Nicholas Bellinger committed Mar 20, 2013
1 parent 72c7753 commit f002a24
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion drivers/target/target_core_file.h
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
#define FD_DEVICE_QUEUE_DEPTH 32
#define FD_MAX_DEVICE_QUEUE_DEPTH 128
#define FD_BLOCKSIZE 512
#define FD_MAX_SECTORS 1024
#define FD_MAX_SECTORS 2048

#define RRF_EMULATE_CDB 0x01
#define RRF_GOT_LBA 0x02
Expand Down

0 comments on commit f002a24

Please sign in to comment.