]> www.infradead.org Git - users/jedix/linux-maple.git/commit
bnx2: Fix bug in bnx2_free_tx_skbs().
authorMichael Chan <mchan@broadcom.com>
Tue, 10 Jul 2012 10:04:40 +0000 (10:04 +0000)
committerJoe Jin <joe.jin@oracle.com>
Tue, 28 Aug 2012 07:23:14 +0000 (15:23 +0800)
commit904ba459f9638dcc5798c74da2ddcaf4dcec58ea
tree1a01205026fa26cd2ce2f30c00cbe6d7f39b53a2
parent052a95e64f42ecd6500d0cdf361d2fe95d7c3e61
bnx2: Fix bug in bnx2_free_tx_skbs().

In rare cases, bnx2x_free_tx_skbs() can unmap the wrong DMA address
when it gets to the last entry of the tx ring.  We were not using
the proper macro to skip the last entry when advancing the tx index.

Reported-by: Zongyun Lai <zlai@vmware.com>
Reviewed-by: Jeffrey Huang <huangjw@broadcom.com>
(cherry picked from commit c1f5163de417dab01fa9daaf09a74bbb19303f3c)
Signed-off-by: Michael Chan <mchan@broadcom.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Signed-off-by: Joe Jin <joe.jin@oracle.com>
drivers/net/bnx2.c