2016-03-09 16:35, Kulasek, TomaszX: > From: Thomas Monjalon [mailto:thomas.monjalon at 6wind.com] > > > +void > > > +rte_eth_count_unsent_packet_callback(struct rte_mbuf **pkts, uint16_t > > unsent, > > > + void *userdata); > > > > What about rte_eth_tx_buffer_default_callback as name? > > This function is used now as default to count silently dropped packets and > update error counter in tx_buffer structure. When I remove error counter and > set silent drop as default behavior, it's better to have two callbacks to > choice: > > 1) silently dropping packets (set as default) > 2) as defined above to dropping with counter. > > Maybe better is to define two default callbacks while many applications can > still update it's internal error counter, > So IHMO these names are more descriptive: > > rte_eth_tx_buffer_drop_callback > rte_eth_tx_buffer_count_callback > > What you think?
I think you are right about the name. Are you sure providing a "count" callback is needed? Is it just to refactor the examples?