Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 271137
b: refs/heads/master
c: dc55b82
h: refs/heads/master
i:
  271135: e7c3fd2
v: v3
  • Loading branch information
Dan Carpenter authored and James Bottomley committed Oct 20, 2011
1 parent 38b8aca commit c30ed49
Show file tree
Hide file tree
Showing 2 changed files with 5 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: d15fdd348313c64438a99d1324ba2eccdcf1e7e6
refs/heads/master: dc55b8274daddffefc34026ed7924138c8c5df17
7 changes: 4 additions & 3 deletions trunk/drivers/scsi/aacraid/linit.c
Original file line number Diff line number Diff line change
Expand Up @@ -894,16 +894,17 @@ static ssize_t aac_show_serial_number(struct device *device,
int len = 0;

if (le32_to_cpu(dev->adapter_info.serial[0]) != 0xBAD0)
len = snprintf(buf, PAGE_SIZE, "%06X\n",
len = snprintf(buf, 16, "%06X\n",
le32_to_cpu(dev->adapter_info.serial[0]));
if (len &&
!memcmp(&dev->supplement_adapter_info.MfgPcbaSerialNo[
sizeof(dev->supplement_adapter_info.MfgPcbaSerialNo)-len],
buf, len-1))
len = snprintf(buf, PAGE_SIZE, "%.*s\n",
len = snprintf(buf, 16, "%.*s\n",
(int)sizeof(dev->supplement_adapter_info.MfgPcbaSerialNo),
dev->supplement_adapter_info.MfgPcbaSerialNo);
return len;

return min(len, 16);
}

static ssize_t aac_show_max_channel(struct device *device,
Expand Down

0 comments on commit c30ed49

Please sign in to comment.