[S2IO]: Fixed memory leak when MSI-X vector allocation fails
authorSreenivasa Honnur <sreenivasa.honnur@neterion.com>
Wed, 14 Nov 2007 09:41:06 +0000 (01:41 -0800)
committerDavid S. Miller <davem@davemloft.net>
Wed, 14 Nov 2007 09:41:06 +0000 (01:41 -0800)
commit18b2b7bd09811779309592a10080fe9ffb93144d
tree12d3b9b5ece4a93a477755f9c1878f72db9cb559
parent8cbdeec637c1ce87bf329c5c19a9964e36bdf9fb
[S2IO]: Fixed memory leak when MSI-X vector allocation fails

- Fixed memory leak by freeing MSI-X local entry memories when vector allocation
fails in s2io_add_isr.
- Added two utility functions remove_msix_isr and remove_inta_isr to eliminate
code duplication.
- Incorporated following review comments from Jeff
        - Removed redundant stats->mem_freed and synchronize_irq call
        - do_rem_msix_isr is renamed as remove_msix_isr
        - do_rem_inta_isr is renamed as remove_inta_isr

Signed-off-by: Sreenivasa Honnur <sreenivasa.honnur@neterion.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
drivers/net/s2io.c