From: Ron Mercer Date: Fri, 13 Feb 2009 00:37:32 +0000 (-0800) Subject: qlge: bugfix: Add missing put_page() call. X-Git-Tag: 2.1b_release~13757^2~139 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=f2603c2c571978497019a50c4df84c185ffef356;p=platform%2Fkernel%2Fkernel-mfld-blackbay.git qlge: bugfix: Add missing put_page() call. We put the page back if we can't get mapping for it. We don't want unmapped buffers on our receive buffer queue. Signed-off-by: Ron Mercer Signed-off-by: David S. Miller --- diff --git a/drivers/net/qlge/qlge_main.c b/drivers/net/qlge/qlge_main.c index 69f7d05..5b75fc9 100644 --- a/drivers/net/qlge/qlge_main.c +++ b/drivers/net/qlge/qlge_main.c @@ -907,6 +907,8 @@ static void ql_update_lbq(struct ql_adapter *qdev, struct rx_ring *rx_ring) 0, PAGE_SIZE, PCI_DMA_FROMDEVICE); if (pci_dma_mapping_error(qdev->pdev, map)) { + put_page(lbq_desc->p.lbq_page); + lbq_desc->p.lbq_page = NULL; QPRINTK(qdev, RX_STATUS, ERR, "PCI mapping failed.\n"); return;