aboutsummaryrefslogtreecommitdiffstats
path: root/arch/ia64/sn
diff options
context:
space:
mode:
authorJulia Lawall <julia@diku.dk>2008-09-10 07:57:19 -0400
committerTony Luck <tony.luck@intel.com>2008-09-10 13:49:36 -0400
commit6bf6a1a49377c32a02939ec835553703994f3e41 (patch)
tree631f1c0a0421976b60e9eb619e72a28b81f17d87 /arch/ia64/sn
parent47633cf0d60bde5581d039ac1283ef4377a6e782 (diff)
[IA64] arch/ia64/sn/pci/tioca_provider.c: introduce missing kfree
Error handling code following a kmalloc should free the allocated data. Signed-off-by: Julia Lawall <julia@diku.dk> Signed-off-by: Tony Luck <tony.luck@intel.com>
Diffstat (limited to 'arch/ia64/sn')
-rw-r--r--arch/ia64/sn/pci/tioca_provider.c4
1 files changed, 3 insertions, 1 deletions
diff --git a/arch/ia64/sn/pci/tioca_provider.c b/arch/ia64/sn/pci/tioca_provider.c
index 529462c01570..79165122501c 100644
--- a/arch/ia64/sn/pci/tioca_provider.c
+++ b/arch/ia64/sn/pci/tioca_provider.c
@@ -420,8 +420,10 @@ tioca_dma_mapped(struct pci_dev *pdev, u64 paddr, size_t req_size)
420 entry = find_next_zero_bit(map, mapsize, last_entry); 420 entry = find_next_zero_bit(map, mapsize, last_entry);
421 } 421 }
422 422
423 if (entry > mapsize) 423 if (entry > mapsize) {
424 kfree(ca_dmamap);
424 goto map_return; 425 goto map_return;
426 }
425 427
426 for (i = 0; i < entries; i++) 428 for (i = 0; i < entries; i++)
427 set_bit(entry + i, map); 429 set_bit(entry + i, map);