Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux
1
fork

Configure Feed

Select the types of activity you want to include in your feed.

fix s2io regression

* wrong argument passed to pci_unmap_single() on failure
exit paths
* leak in the same area

Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>

authored by

Al Viro and committed by
Linus Torvalds
3e847423 c73d8347

+6 -3
+6 -3
drivers/net/s2io.c
··· 2430 2430 (rxdp3->Buffer1_ptr == DMA_ERROR_CODE)) { 2431 2431 pci_unmap_single 2432 2432 (nic->pdev, 2433 - (dma_addr_t)skb->data, 2433 + (dma_addr_t)rxdp3->Buffer2_ptr, 2434 2434 dev->mtu + 4, 2435 2435 PCI_DMA_FROMDEVICE); 2436 2436 goto pci_map_failed; ··· 6211 6211 if( (rxdp3->Buffer0_ptr == 0) || 6212 6212 (rxdp3->Buffer0_ptr == DMA_ERROR_CODE)) { 6213 6213 pci_unmap_single (sp->pdev, 6214 - (dma_addr_t)(*skb)->data, 6214 + (dma_addr_t)rxdp3->Buffer2_ptr, 6215 6215 dev->mtu + 4, PCI_DMA_FROMDEVICE); 6216 6216 goto memalloc_failed; 6217 6217 } ··· 6224 6224 if( (rxdp3->Buffer1_ptr == 0) || 6225 6225 (rxdp3->Buffer1_ptr == DMA_ERROR_CODE)) { 6226 6226 pci_unmap_single (sp->pdev, 6227 - (dma_addr_t)(*skb)->data, 6227 + (dma_addr_t)rxdp3->Buffer0_ptr, 6228 + BUF0_LEN, PCI_DMA_FROMDEVICE); 6229 + pci_unmap_single (sp->pdev, 6230 + (dma_addr_t)rxdp3->Buffer2_ptr, 6228 6231 dev->mtu + 4, PCI_DMA_FROMDEVICE); 6229 6232 goto memalloc_failed; 6230 6233 }