diff options
Diffstat (limited to 'drivers/scsi/ibmvscsi/ibmvscsi.c')
-rw-r--r-- | drivers/scsi/ibmvscsi/ibmvscsi.c | 28 |
1 files changed, 15 insertions, 13 deletions
diff --git a/drivers/scsi/ibmvscsi/ibmvscsi.c b/drivers/scsi/ibmvscsi/ibmvscsi.c index ea8e01f49cba..63f32f843e75 100644 --- a/drivers/scsi/ibmvscsi/ibmvscsi.c +++ b/drivers/scsi/ibmvscsi/ibmvscsi.c @@ -454,7 +454,7 @@ static int initialize_event_pool(struct event_pool *pool, pool->iu_storage = dma_alloc_coherent(hostdata->dev, pool->size * sizeof(*pool->iu_storage), - &pool->iu_token, 0); + &pool->iu_token, GFP_KERNEL); if (!pool->iu_storage) { kfree(pool->events); return -ENOMEM; @@ -1039,9 +1039,9 @@ static inline u16 lun_from_dev(struct scsi_device *dev) * @cmnd: struct scsi_cmnd to be executed * @done: Callback function to be called when cmd is completed */ -static int ibmvscsi_queuecommand_lck(struct scsi_cmnd *cmnd, - void (*done) (struct scsi_cmnd *)) +static int ibmvscsi_queuecommand_lck(struct scsi_cmnd *cmnd) { + void (*done)(struct scsi_cmnd *) = scsi_done; struct srp_cmd *srp_cmd; struct srp_event_struct *evt_struct; struct srp_indirect_buf *indirect; @@ -2065,18 +2065,20 @@ static int ibmvscsi_host_reset(struct Scsi_Host *shost, int reset_type) return 0; } -static struct device_attribute *ibmvscsi_attrs[] = { - &ibmvscsi_host_vhost_loc, - &ibmvscsi_host_vhost_name, - &ibmvscsi_host_srp_version, - &ibmvscsi_host_partition_name, - &ibmvscsi_host_partition_number, - &ibmvscsi_host_mad_version, - &ibmvscsi_host_os_type, - &ibmvscsi_host_config, +static struct attribute *ibmvscsi_host_attrs[] = { + &ibmvscsi_host_vhost_loc.attr, + &ibmvscsi_host_vhost_name.attr, + &ibmvscsi_host_srp_version.attr, + &ibmvscsi_host_partition_name.attr, + &ibmvscsi_host_partition_number.attr, + &ibmvscsi_host_mad_version.attr, + &ibmvscsi_host_os_type.attr, + &ibmvscsi_host_config.attr, NULL }; +ATTRIBUTE_GROUPS(ibmvscsi_host); + /* ------------------------------------------------------------ * SCSI driver registration */ @@ -2096,7 +2098,7 @@ static struct scsi_host_template driver_template = { .can_queue = IBMVSCSI_MAX_REQUESTS_DEFAULT, .this_id = -1, .sg_tablesize = SG_ALL, - .shost_attrs = ibmvscsi_attrs, + .shost_groups = ibmvscsi_host_groups, }; /** |