Commit 33a9401e authored by James Bottomley's avatar James Bottomley Committed by Greg Kroah-Hartman

scsi: use short driver name for per-driver cmd slab caches

commit 884ffee0 upstream.

hostt->name might contain space, so use the ->proc_name short name instead
when creating per-driver command slabs.
Signed-off-by: default avatarJames Bottomley <JBottomley@Parallels.com>
Reported-by: default avatarpoma <pomidorabelisima@gmail.com>
Tested-by: default avatarpoma <pomidorabelisima@gmail.com>
Reviewed-by: default avatarVladimir Davydov <vdavydov@parallels.com>
Reviewed-by: default avatarMartin K. Petersen <martin.petersen@oracle.com>
Signed-off-by: default avatarChristoph Hellwig <hch@lst.de>
Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@linuxfoundation.org>
parent fe86f9f8
...@@ -368,8 +368,8 @@ scsi_alloc_host_cmd_pool(struct Scsi_Host *shost) ...@@ -368,8 +368,8 @@ scsi_alloc_host_cmd_pool(struct Scsi_Host *shost)
if (!pool) if (!pool)
return NULL; return NULL;
pool->cmd_name = kasprintf(GFP_KERNEL, "%s_cmd", hostt->name); pool->cmd_name = kasprintf(GFP_KERNEL, "%s_cmd", hostt->proc_name);
pool->sense_name = kasprintf(GFP_KERNEL, "%s_sense", hostt->name); pool->sense_name = kasprintf(GFP_KERNEL, "%s_sense", hostt->proc_name);
if (!pool->cmd_name || !pool->sense_name) { if (!pool->cmd_name || !pool->sense_name) {
scsi_free_host_cmd_pool(pool); scsi_free_host_cmd_pool(pool);
return NULL; return NULL;
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment