Hi Declan, Do you confirm we should merge the Robert's patch in rc3?
2014-06-30 18:29, Robert Sanford: > I see a potential problem with bond_ethdev_rx_burst( ). > We could receive more packets than the caller asked for, and overrun the > caller's rte_mbuf * array. > The fix could be something like this: > > --- a/lib/librte_pmd_bond/rte_eth_bond_pmd.c > +++ b/lib/librte_pmd_bond/rte_eth_bond_pmd.c > @@ -73,13 +73,15 @@ bond_ethdev_rx_burst(void *queue, struct rte_mbuf > **bufs, uint16_t nb_pkts) > case BONDING_MODE_ROUND_ROBIN: > case BONDING_MODE_BROADCAST: > case BONDING_MODE_BALANCE: > - for (i = 0; i < internals->active_slave_count; i++) { > + for (i = 0; i < internals->active_slave_count && nb_pkts; > i++) { > /* Offset of pointer to *bufs increases as packets > are received > * from other slaves */ > num_rx_slave = > rte_eth_rx_burst(internals->active_slaves[i], > bd_rx_q->queue_id, bufs + > num_rx_total, nb_pkts); > - if (num_rx_slave) > + if (num_rx_slave) { > num_rx_total += num_rx_slave; > + nb_pkts -= num_rx_slave; > + } > } > break; > case BONDING_MODE_ACTIVE_BACKUP: