Skip to content

Commit 37c918e

Browse files
hreineckemartinkpetersen
authored andcommitted
scsi: sg: Increase number of devices
Larger setups may need to allocate more than 32k sg devices, so increase the number of devices to the full range of minor device numbers. Signed-off-by: Hannes Reinecke <[email protected]> Signed-off-by: Martin Wilck <[email protected]> Link: https://lore.kernel.org/r/[email protected] Acked-by: Douglas Gilbert <[email protected]> Reviewed-by: Christoph Hellwig <[email protected]> Reviewed-by: Ming Lei <[email protected]> Reviewed-by: Bart Van Assche <[email protected]> Signed-off-by: Martin K. Petersen <[email protected]>
1 parent 9077fb2 commit 37c918e

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

drivers/scsi/sg.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -71,7 +71,7 @@ static int sg_proc_init(void);
7171

7272
#define SG_ALLOW_DIO_DEF 0
7373

74-
#define SG_MAX_DEVS 32768
74+
#define SG_MAX_DEVS (1 << MINORBITS)
7575

7676
/* SG_MAX_CDB_SIZE should be 260 (spc4r37 section 3.1.30) however the type
7777
* of sg_io_hdr::cmd_len can only represent 255. All SCSI commands greater

0 commit comments

Comments
 (0)