Commit 212a502676c308ead964a024e081529ad3f8d94c
Committed by
Jens Axboe
1 parent
723590ed52
Exists in
master
and in
7 other branches
cciss: memory leak in cciss_init_one()
commit 22bece00dc1f28dd3374c55e464c9f02eb642876 (cciss: fix regression firmware not displayed in procfs) added a small memory leak in cciss_init_one() Signed-off-by: Eric Dumazet <eric.dumazet@gmail.com> Signed-off-by: Jens Axboe <jens.axboe@oracle.com>
Showing 1 changed file with 2 additions and 2 deletions Side-by-side Diff
drivers/block/cciss.c
... | ... | @@ -3889,7 +3889,7 @@ |
3889 | 3889 | int j = 0; |
3890 | 3890 | int rc; |
3891 | 3891 | int dac, return_code; |
3892 | - InquiryData_struct *inq_buff = NULL; | |
3892 | + InquiryData_struct *inq_buff; | |
3893 | 3893 | |
3894 | 3894 | if (reset_devices) { |
3895 | 3895 | /* Reset the controller with a PCI power-cycle */ |
... | ... | @@ -4029,6 +4029,7 @@ |
4029 | 4029 | printk(KERN_WARNING "cciss: unable to determine firmware" |
4030 | 4030 | " version of controller\n"); |
4031 | 4031 | } |
4032 | + kfree(inq_buff); | |
4032 | 4033 | |
4033 | 4034 | cciss_procinit(i); |
4034 | 4035 | |
... | ... | @@ -4045,7 +4046,6 @@ |
4045 | 4046 | return 1; |
4046 | 4047 | |
4047 | 4048 | clean4: |
4048 | - kfree(inq_buff); | |
4049 | 4049 | kfree(hba[i]->cmd_pool_bits); |
4050 | 4050 | if (hba[i]->cmd_pool) |
4051 | 4051 | pci_free_consistent(hba[i]->pdev, |