diff options
author | Hannes Reinecke <hare@suse.de> | 2014-06-25 09:27:38 -0400 |
---|---|---|
committer | Christoph Hellwig <hch@lst.de> | 2014-07-17 16:07:38 -0400 |
commit | 1abf635d2f3332641570e1913e317073834a055f (patch) | |
tree | a895c63f34c4465c95ea82c3d561115f1ff21626 /drivers/scsi | |
parent | b4210b810e5040f10a30ba56de6c3faab5c49345 (diff) |
scsi: use 64-bit value for 'max_luns'
Now that we're using 64-bit LUNs internally we need to increase
the size of max_luns to 64 bits, too.
Signed-off-by: Hannes Reinecke <hare@suse.de>
Reviewed-by: Christoph Hellwig <hch@infradead.org>
Reviewed-by: Ewan Milne <emilne@redhat.com>
Signed-off-by: Christoph Hellwig <hch@lst.de>
Diffstat (limited to 'drivers/scsi')
-rw-r--r-- | drivers/scsi/advansys.c | 2 | ||||
-rw-r--r-- | drivers/scsi/cxgbi/libcxgbi.c | 2 | ||||
-rw-r--r-- | drivers/scsi/cxgbi/libcxgbi.h | 2 | ||||
-rw-r--r-- | drivers/scsi/dc395x.c | 2 | ||||
-rw-r--r-- | drivers/scsi/eata.c | 2 | ||||
-rw-r--r-- | drivers/scsi/ibmvscsi/ibmvfc.c | 4 | ||||
-rw-r--r-- | drivers/scsi/lpfc/lpfc_attr.c | 10 | ||||
-rw-r--r-- | drivers/scsi/megaraid.c | 2 | ||||
-rw-r--r-- | drivers/scsi/mpt3sas/mpt3sas_scsih.c | 4 | ||||
-rw-r--r-- | drivers/scsi/qla2xxx/qla_gbl.h | 2 | ||||
-rw-r--r-- | drivers/scsi/qla2xxx/qla_os.c | 6 | ||||
-rw-r--r-- | drivers/scsi/scsi_scan.c | 6 |
12 files changed, 26 insertions, 18 deletions
diff --git a/drivers/scsi/advansys.c b/drivers/scsi/advansys.c index d8145888e66a..e716d0aef194 100644 --- a/drivers/scsi/advansys.c +++ b/drivers/scsi/advansys.c | |||
@@ -3345,7 +3345,7 @@ static void asc_prt_driver_conf(struct seq_file *m, struct Scsi_Host *shost) | |||
3345 | shost->host_no); | 3345 | shost->host_no); |
3346 | 3346 | ||
3347 | seq_printf(m, | 3347 | seq_printf(m, |
3348 | " host_busy %u, max_id %u, max_lun %u, max_channel %u\n", | 3348 | " host_busy %u, max_id %u, max_lun %llu, max_channel %u\n", |
3349 | shost->host_busy, shost->max_id, | 3349 | shost->host_busy, shost->max_id, |
3350 | shost->max_lun, shost->max_channel); | 3350 | shost->max_lun, shost->max_channel); |
3351 | 3351 | ||
diff --git a/drivers/scsi/cxgbi/libcxgbi.c b/drivers/scsi/cxgbi/libcxgbi.c index b44c1cff3114..dc812069046c 100644 --- a/drivers/scsi/cxgbi/libcxgbi.c +++ b/drivers/scsi/cxgbi/libcxgbi.c | |||
@@ -245,7 +245,7 @@ void cxgbi_hbas_remove(struct cxgbi_device *cdev) | |||
245 | } | 245 | } |
246 | EXPORT_SYMBOL_GPL(cxgbi_hbas_remove); | 246 | EXPORT_SYMBOL_GPL(cxgbi_hbas_remove); |
247 | 247 | ||
248 | int cxgbi_hbas_add(struct cxgbi_device *cdev, unsigned int max_lun, | 248 | int cxgbi_hbas_add(struct cxgbi_device *cdev, u64 max_lun, |
249 | unsigned int max_id, struct scsi_host_template *sht, | 249 | unsigned int max_id, struct scsi_host_template *sht, |
250 | struct scsi_transport_template *stt) | 250 | struct scsi_transport_template *stt) |
251 | { | 251 | { |
diff --git a/drivers/scsi/cxgbi/libcxgbi.h b/drivers/scsi/cxgbi/libcxgbi.h index 8135f04671af..538d7a64e138 100644 --- a/drivers/scsi/cxgbi/libcxgbi.h +++ b/drivers/scsi/cxgbi/libcxgbi.h | |||
@@ -692,7 +692,7 @@ struct cxgbi_device *cxgbi_device_register(unsigned int, unsigned int); | |||
692 | void cxgbi_device_unregister(struct cxgbi_device *); | 692 | void cxgbi_device_unregister(struct cxgbi_device *); |
693 | void cxgbi_device_unregister_all(unsigned int flag); | 693 | void cxgbi_device_unregister_all(unsigned int flag); |
694 | struct cxgbi_device *cxgbi_device_find_by_lldev(void *); | 694 | struct cxgbi_device *cxgbi_device_find_by_lldev(void *); |
695 | int cxgbi_hbas_add(struct cxgbi_device *, unsigned int, unsigned int, | 695 | int cxgbi_hbas_add(struct cxgbi_device *, u64, unsigned int, |
696 | struct scsi_host_template *, | 696 | struct scsi_host_template *, |
697 | struct scsi_transport_template *); | 697 | struct scsi_transport_template *); |
698 | void cxgbi_hbas_remove(struct cxgbi_device *); | 698 | void cxgbi_hbas_remove(struct cxgbi_device *); |
diff --git a/drivers/scsi/dc395x.c b/drivers/scsi/dc395x.c index dff461f2338e..0c6be0a17f53 100644 --- a/drivers/scsi/dc395x.c +++ b/drivers/scsi/dc395x.c | |||
@@ -4638,7 +4638,7 @@ static int dc395x_show_info(struct seq_file *m, struct Scsi_Host *host) | |||
4638 | SPRINTF("irq_level 0x%04x, ", acb->irq_level); | 4638 | SPRINTF("irq_level 0x%04x, ", acb->irq_level); |
4639 | SPRINTF(" SelTimeout %ims\n", (1638 * acb->sel_timeout) / 1000); | 4639 | SPRINTF(" SelTimeout %ims\n", (1638 * acb->sel_timeout) / 1000); |
4640 | 4640 | ||
4641 | SPRINTF("MaxID %i, MaxLUN %i, ", host->max_id, host->max_lun); | 4641 | SPRINTF("MaxID %i, MaxLUN %llu, ", host->max_id, host->max_lun); |
4642 | SPRINTF("AdapterID %i\n", host->this_id); | 4642 | SPRINTF("AdapterID %i\n", host->this_id); |
4643 | 4643 | ||
4644 | SPRINTF("tag_max_num %i", acb->tag_max_num); | 4644 | SPRINTF("tag_max_num %i", acb->tag_max_num); |
diff --git a/drivers/scsi/eata.c b/drivers/scsi/eata.c index 0f27ac19cf01..03372cff38f3 100644 --- a/drivers/scsi/eata.c +++ b/drivers/scsi/eata.c | |||
@@ -1399,7 +1399,7 @@ static int port_detect(unsigned long port_base, unsigned int j, | |||
1399 | 1399 | ||
1400 | if (shost->max_id > 8 || shost->max_lun > 8) | 1400 | if (shost->max_id > 8 || shost->max_lun > 8) |
1401 | printk | 1401 | printk |
1402 | ("%s: wide SCSI support enabled, max_id %u, max_lun %u.\n", | 1402 | ("%s: wide SCSI support enabled, max_id %u, max_lun %llu.\n", |
1403 | ha->board_name, shost->max_id, shost->max_lun); | 1403 | ha->board_name, shost->max_id, shost->max_lun); |
1404 | 1404 | ||
1405 | for (i = 0; i <= shost->max_channel; i++) | 1405 | for (i = 0; i <= shost->max_channel; i++) |
diff --git a/drivers/scsi/ibmvscsi/ibmvfc.c b/drivers/scsi/ibmvscsi/ibmvfc.c index 8dd47689d584..6eb47b683569 100644 --- a/drivers/scsi/ibmvscsi/ibmvfc.c +++ b/drivers/scsi/ibmvscsi/ibmvfc.c | |||
@@ -46,7 +46,7 @@ | |||
46 | 46 | ||
47 | static unsigned int init_timeout = IBMVFC_INIT_TIMEOUT; | 47 | static unsigned int init_timeout = IBMVFC_INIT_TIMEOUT; |
48 | static unsigned int default_timeout = IBMVFC_DEFAULT_TIMEOUT; | 48 | static unsigned int default_timeout = IBMVFC_DEFAULT_TIMEOUT; |
49 | static unsigned int max_lun = IBMVFC_MAX_LUN; | 49 | static u64 max_lun = IBMVFC_MAX_LUN; |
50 | static unsigned int max_targets = IBMVFC_MAX_TARGETS; | 50 | static unsigned int max_targets = IBMVFC_MAX_TARGETS; |
51 | static unsigned int max_requests = IBMVFC_MAX_REQUESTS_DEFAULT; | 51 | static unsigned int max_requests = IBMVFC_MAX_REQUESTS_DEFAULT; |
52 | static unsigned int disc_threads = IBMVFC_MAX_DISC_THREADS; | 52 | static unsigned int disc_threads = IBMVFC_MAX_DISC_THREADS; |
@@ -71,7 +71,7 @@ MODULE_PARM_DESC(default_timeout, | |||
71 | module_param_named(max_requests, max_requests, uint, S_IRUGO); | 71 | module_param_named(max_requests, max_requests, uint, S_IRUGO); |
72 | MODULE_PARM_DESC(max_requests, "Maximum requests for this adapter. " | 72 | MODULE_PARM_DESC(max_requests, "Maximum requests for this adapter. " |
73 | "[Default=" __stringify(IBMVFC_MAX_REQUESTS_DEFAULT) "]"); | 73 | "[Default=" __stringify(IBMVFC_MAX_REQUESTS_DEFAULT) "]"); |
74 | module_param_named(max_lun, max_lun, uint, S_IRUGO); | 74 | module_param_named(max_lun, max_lun, ullong, S_IRUGO); |
75 | MODULE_PARM_DESC(max_lun, "Maximum allowed LUN. " | 75 | MODULE_PARM_DESC(max_lun, "Maximum allowed LUN. " |
76 | "[Default=" __stringify(IBMVFC_MAX_LUN) "]"); | 76 | "[Default=" __stringify(IBMVFC_MAX_LUN) "]"); |
77 | module_param_named(max_targets, max_targets, uint, S_IRUGO); | 77 | module_param_named(max_targets, max_targets, uint, S_IRUGO); |
diff --git a/drivers/scsi/lpfc/lpfc_attr.c b/drivers/scsi/lpfc/lpfc_attr.c index 1d7a5c34ee8c..6eed9e76a166 100644 --- a/drivers/scsi/lpfc/lpfc_attr.c +++ b/drivers/scsi/lpfc/lpfc_attr.c | |||
@@ -1998,6 +1998,14 @@ lpfc_vport_param_show(name)\ | |||
1998 | lpfc_vport_param_init(name, defval, minval, maxval)\ | 1998 | lpfc_vport_param_init(name, defval, minval, maxval)\ |
1999 | static DEVICE_ATTR(lpfc_##name, S_IRUGO , lpfc_##name##_show, NULL) | 1999 | static DEVICE_ATTR(lpfc_##name, S_IRUGO , lpfc_##name##_show, NULL) |
2000 | 2000 | ||
2001 | #define LPFC_VPORT_ULL_ATTR_R(name, defval, minval, maxval, desc) \ | ||
2002 | static uint64_t lpfc_##name = defval;\ | ||
2003 | module_param(lpfc_##name, ullong, S_IRUGO);\ | ||
2004 | MODULE_PARM_DESC(lpfc_##name, desc);\ | ||
2005 | lpfc_vport_param_show(name)\ | ||
2006 | lpfc_vport_param_init(name, defval, minval, maxval)\ | ||
2007 | static DEVICE_ATTR(lpfc_##name, S_IRUGO , lpfc_##name##_show, NULL) | ||
2008 | |||
2001 | #define LPFC_VPORT_ATTR_RW(name, defval, minval, maxval, desc) \ | 2009 | #define LPFC_VPORT_ATTR_RW(name, defval, minval, maxval, desc) \ |
2002 | static uint lpfc_##name = defval;\ | 2010 | static uint lpfc_##name = defval;\ |
2003 | module_param(lpfc_##name, uint, S_IRUGO);\ | 2011 | module_param(lpfc_##name, uint, S_IRUGO);\ |
@@ -4596,7 +4604,7 @@ LPFC_VPORT_ATTR(discovery_threads, 32, 1, 64, "Maximum number of ELS commands " | |||
4596 | # Value range is [0,65535]. Default value is 255. | 4604 | # Value range is [0,65535]. Default value is 255. |
4597 | # NOTE: The SCSI layer might probe all allowed LUN on some old targets. | 4605 | # NOTE: The SCSI layer might probe all allowed LUN on some old targets. |
4598 | */ | 4606 | */ |
4599 | LPFC_VPORT_ATTR_R(max_luns, 255, 0, 65535, "Maximum allowed LUN ID"); | 4607 | LPFC_VPORT_ULL_ATTR_R(max_luns, 255, 0, 65535, "Maximum allowed LUN ID"); |
4600 | 4608 | ||
4601 | /* | 4609 | /* |
4602 | # lpfc_poll_tmo: .Milliseconds driver will wait between polling FCP ring. | 4610 | # lpfc_poll_tmo: .Milliseconds driver will wait between polling FCP ring. |
diff --git a/drivers/scsi/megaraid.c b/drivers/scsi/megaraid.c index 6bb2b52646b4..ac5d94cfd52f 100644 --- a/drivers/scsi/megaraid.c +++ b/drivers/scsi/megaraid.c | |||
@@ -1860,7 +1860,7 @@ megaraid_info(struct Scsi_Host *host) | |||
1860 | "LSI Logic MegaRAID %s %d commands %d targs %d chans %d luns", | 1860 | "LSI Logic MegaRAID %s %d commands %d targs %d chans %d luns", |
1861 | adapter->fw_version, adapter->product_info.max_commands, | 1861 | adapter->fw_version, adapter->product_info.max_commands, |
1862 | adapter->host->max_id, adapter->host->max_channel, | 1862 | adapter->host->max_id, adapter->host->max_channel, |
1863 | adapter->host->max_lun); | 1863 | (u32)adapter->host->max_lun); |
1864 | return buffer; | 1864 | return buffer; |
1865 | } | 1865 | } |
1866 | 1866 | ||
diff --git a/drivers/scsi/mpt3sas/mpt3sas_scsih.c b/drivers/scsi/mpt3sas/mpt3sas_scsih.c index 18e713db1d32..0274ac3c533b 100644 --- a/drivers/scsi/mpt3sas/mpt3sas_scsih.c +++ b/drivers/scsi/mpt3sas/mpt3sas_scsih.c | |||
@@ -112,8 +112,8 @@ MODULE_PARM_DESC(missing_delay, " device missing delay , io missing delay"); | |||
112 | 112 | ||
113 | /* scsi-mid layer global parmeter is max_report_luns, which is 511 */ | 113 | /* scsi-mid layer global parmeter is max_report_luns, which is 511 */ |
114 | #define MPT3SAS_MAX_LUN (16895) | 114 | #define MPT3SAS_MAX_LUN (16895) |
115 | static int max_lun = MPT3SAS_MAX_LUN; | 115 | static u64 max_lun = MPT3SAS_MAX_LUN; |
116 | module_param(max_lun, int, 0); | 116 | module_param(max_lun, ullong, 0); |
117 | MODULE_PARM_DESC(max_lun, " max lun, default=16895 "); | 117 | MODULE_PARM_DESC(max_lun, " max lun, default=16895 "); |
118 | 118 | ||
119 | 119 | ||
diff --git a/drivers/scsi/qla2xxx/qla_gbl.h b/drivers/scsi/qla2xxx/qla_gbl.h index 9ef0781b12da..d646540db3ac 100644 --- a/drivers/scsi/qla2xxx/qla_gbl.h +++ b/drivers/scsi/qla2xxx/qla_gbl.h | |||
@@ -113,7 +113,7 @@ extern int ql2xenabledif; | |||
113 | extern int ql2xenablehba_err_chk; | 113 | extern int ql2xenablehba_err_chk; |
114 | extern int ql2xtargetreset; | 114 | extern int ql2xtargetreset; |
115 | extern int ql2xdontresethba; | 115 | extern int ql2xdontresethba; |
116 | extern unsigned int ql2xmaxlun; | 116 | extern uint64_t ql2xmaxlun; |
117 | extern int ql2xmdcapmask; | 117 | extern int ql2xmdcapmask; |
118 | extern int ql2xmdenable; | 118 | extern int ql2xmdenable; |
119 | 119 | ||
diff --git a/drivers/scsi/qla2xxx/qla_os.c b/drivers/scsi/qla2xxx/qla_os.c index b22c75305b44..be9698d920c2 100644 --- a/drivers/scsi/qla2xxx/qla_os.c +++ b/drivers/scsi/qla2xxx/qla_os.c | |||
@@ -202,8 +202,8 @@ MODULE_PARM_DESC(ql2xdontresethba, | |||
202 | " 0 (Default) -- Reset on failure.\n" | 202 | " 0 (Default) -- Reset on failure.\n" |
203 | " 1 -- Do not reset on failure.\n"); | 203 | " 1 -- Do not reset on failure.\n"); |
204 | 204 | ||
205 | uint ql2xmaxlun = MAX_LUNS; | 205 | uint64_t ql2xmaxlun = MAX_LUNS; |
206 | module_param(ql2xmaxlun, uint, S_IRUGO); | 206 | module_param(ql2xmaxlun, ullong, S_IRUGO); |
207 | MODULE_PARM_DESC(ql2xmaxlun, | 207 | MODULE_PARM_DESC(ql2xmaxlun, |
208 | "Defines the maximum LU number to register with the SCSI " | 208 | "Defines the maximum LU number to register with the SCSI " |
209 | "midlayer. Default is 65535."); | 209 | "midlayer. Default is 65535."); |
@@ -2676,7 +2676,7 @@ qla2x00_probe_one(struct pci_dev *pdev, const struct pci_device_id *id) | |||
2676 | ql_dbg(ql_dbg_init, base_vha, 0x0033, | 2676 | ql_dbg(ql_dbg_init, base_vha, 0x0033, |
2677 | "max_id=%d this_id=%d " | 2677 | "max_id=%d this_id=%d " |
2678 | "cmd_per_len=%d unique_id=%d max_cmd_len=%d max_channel=%d " | 2678 | "cmd_per_len=%d unique_id=%d max_cmd_len=%d max_channel=%d " |
2679 | "max_lun=%d transportt=%p, vendor_id=%llu.\n", host->max_id, | 2679 | "max_lun=%llu transportt=%p, vendor_id=%llu.\n", host->max_id, |
2680 | host->this_id, host->cmd_per_lun, host->unique_id, | 2680 | host->this_id, host->cmd_per_lun, host->unique_id, |
2681 | host->max_cmd_len, host->max_channel, host->max_lun, | 2681 | host->max_cmd_len, host->max_channel, host->max_lun, |
2682 | host->transportt, sht->vendor_id); | 2682 | host->transportt, sht->vendor_id); |
diff --git a/drivers/scsi/scsi_scan.c b/drivers/scsi/scsi_scan.c index 1a71547832f3..fa57a046f025 100644 --- a/drivers/scsi/scsi_scan.c +++ b/drivers/scsi/scsi_scan.c | |||
@@ -81,11 +81,11 @@ static const char *scsi_null_device_strs = "nullnullnullnull"; | |||
81 | 81 | ||
82 | #define MAX_SCSI_LUNS 512 | 82 | #define MAX_SCSI_LUNS 512 |
83 | 83 | ||
84 | static unsigned int max_scsi_luns = MAX_SCSI_LUNS; | 84 | static u64 max_scsi_luns = MAX_SCSI_LUNS; |
85 | 85 | ||
86 | module_param_named(max_luns, max_scsi_luns, uint, S_IRUGO|S_IWUSR); | 86 | module_param_named(max_luns, max_scsi_luns, ullong, S_IRUGO|S_IWUSR); |
87 | MODULE_PARM_DESC(max_luns, | 87 | MODULE_PARM_DESC(max_luns, |
88 | "last scsi LUN (should be between 1 and 2^32-1)"); | 88 | "last scsi LUN (should be between 1 and 2^64-1)"); |
89 | 89 | ||
90 | #ifdef CONFIG_SCSI_SCAN_ASYNC | 90 | #ifdef CONFIG_SCSI_SCAN_ASYNC |
91 | #define SCSI_SCAN_TYPE_DEFAULT "async" | 91 | #define SCSI_SCAN_TYPE_DEFAULT "async" |