scsi: ibmvfc: ibmvscsi: ibmvscsi_tgt: constify vio_device_id
vio_device_id are not supposed to change at runtime. All functions working with vio_device_id provided by <asm/vio.h> work with const vio_device_id. So mark the non-const structs as const. Signed-off-by: Arvind Yadav <arvind.yadav.cs@gmail.com> Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com>
This commit is contained in:
committed by
Martin K. Petersen
parent
35c0506f27
commit
e4df3eaa6e
@@ -4925,7 +4925,7 @@ static unsigned long ibmvfc_get_desired_dma(struct vio_dev *vdev)
|
|||||||
return pool_dma + ((512 * 1024) * driver_template.cmd_per_lun);
|
return pool_dma + ((512 * 1024) * driver_template.cmd_per_lun);
|
||||||
}
|
}
|
||||||
|
|
||||||
static struct vio_device_id ibmvfc_device_table[] = {
|
static const struct vio_device_id ibmvfc_device_table[] = {
|
||||||
{"fcp", "IBM,vfc-client"},
|
{"fcp", "IBM,vfc-client"},
|
||||||
{ "", "" }
|
{ "", "" }
|
||||||
};
|
};
|
||||||
|
|||||||
@@ -2330,7 +2330,7 @@ static int ibmvscsi_resume(struct device *dev)
|
|||||||
* ibmvscsi_device_table: Used by vio.c to match devices in the device tree we
|
* ibmvscsi_device_table: Used by vio.c to match devices in the device tree we
|
||||||
* support.
|
* support.
|
||||||
*/
|
*/
|
||||||
static struct vio_device_id ibmvscsi_device_table[] = {
|
static const struct vio_device_id ibmvscsi_device_table[] = {
|
||||||
{"vscsi", "IBM,v-scsi"},
|
{"vscsi", "IBM,v-scsi"},
|
||||||
{ "", "" }
|
{ "", "" }
|
||||||
};
|
};
|
||||||
|
|||||||
@@ -4086,7 +4086,7 @@ static struct class ibmvscsis_class = {
|
|||||||
.dev_groups = ibmvscsis_dev_groups,
|
.dev_groups = ibmvscsis_dev_groups,
|
||||||
};
|
};
|
||||||
|
|
||||||
static struct vio_device_id ibmvscsis_device_table[] = {
|
static const struct vio_device_id ibmvscsis_device_table[] = {
|
||||||
{ "v-scsi-host", "IBM,v-scsi-host" },
|
{ "v-scsi-host", "IBM,v-scsi-host" },
|
||||||
{ "", "" }
|
{ "", "" }
|
||||||
};
|
};
|
||||||
|
|||||||
Reference in New Issue
Block a user