Subject: Re: [PATCH] fs_enet: Adjust BDs after tx error

From: Martin Roth <[email-masked]>
Date: Tue, 24 Nov 2015 00:08:54 -0700 (MST)

Hi,

I have reviewed the code and in my opinion the  line 

                     last_tx_bd = fep->tx_bd_base + (fpi->tx_ring *
sizeof(cbd_t)); 

should be replaced with
              
                     last_tx_bd = fep->tx_bd_base + ((fpi->tx_ring-1) *
sizeof(cbd_t));  

In  the original code  the last_tx_bd  points to location after the last
base descriptor end.
In the code fix that I propose, the  last_tx_bd points to the last
descriptor.  

Am I missing something ?

Thanks,
Martin  

--
View this message in context: http://linuxppc.10917.n7.nabble.com/PATCH-fs-enet-Adjust-BDs-after-tx-error-tp37529p101274.html
Sent from the linuxppc-dev mailing list archive at Nabble.com.