Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 2089
b: refs/heads/master
c: cd8a383
h: refs/heads/master
i:
  2087: 46687ae
v: v3
  • Loading branch information
Andreas Herrmann authored and James Bottomley committed Jun 14, 2005
1 parent 5c8df0c commit e90f32c
Show file tree
Hide file tree
Showing 2 changed files with 13 additions and 4 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: 1db2c9c0931a53fe013db55fd2ff58859db31e8d
refs/heads/master: cd8a383ebc93f8ded9cefee53a337542c3aacad7
15 changes: 12 additions & 3 deletions trunk/drivers/s390/scsi/zfcp_aux.c
Original file line number Diff line number Diff line change
Expand Up @@ -218,13 +218,20 @@ zfcp_in_els_dbf_event(struct zfcp_adapter *adapter, const char *text,
* Parse "device=..." parameter string.
*/
static int __init
zfcp_device_setup(char *str)
zfcp_device_setup(char *devstr)
{
char *tmp;
char *tmp, *str;
size_t len;

if (!str)
if (!devstr)
return 0;

len = strlen(devstr) + 1;
str = (char *) kmalloc(len, GFP_KERNEL);
if (!str)
goto err_out;
memcpy(str, devstr, len);

tmp = strchr(str, ',');
if (!tmp)
goto err_out;
Expand All @@ -241,10 +248,12 @@ zfcp_device_setup(char *str)
zfcp_data.init_fcp_lun = simple_strtoull(tmp, &tmp, 0);
if (*tmp != '\0')
goto err_out;
kfree(str);
return 1;

err_out:
ZFCP_LOG_NORMAL("Parse error for device parameter string %s\n", str);
kfree(str);
return 0;
}

Expand Down

0 comments on commit e90f32c

Please sign in to comment.