LGTM, makes the code more readable. Acked-by: Antonio Fischetti <antonio.fische...@intel.com>
> -----Original Message----- > From: ovs-dev-boun...@openvswitch.org [mailto:ovs-dev-boun...@openvswitch.org] > On Behalf Of Kevin Traynor > Sent: Friday, October 20, 2017 11:37 AM > To: Darrell Ball <db...@vmware.com>; d...@openvswitch.org; > i.maxim...@samsung.com; Stokes, Ian <ian.sto...@intel.com> > Subject: Re: [ovs-dev] [PATCH 1/3] dpif-netdev: Rename rxq_interval. > > Ping again. This is a simple variable rename that was requested. > > On 09/22/2017 08:22 PM, Darrell Ball wrote: > > Are there any other comments? > > > > > > > > On 8/30/17, 10:49 AM, "Darrell Ball" <db...@vmware.com> wrote: > > > > Thanks Kevin > > > > Naming is hard. > > The name looks a bit more intuitive and matches closely with the > description previously added. > > > > Darrell > > > > On 8/30/17, 10:45 AM, "Kevin Traynor" <ktray...@redhat.com> wrote: > > > > rxq_interval was added before there was other #defines > > and code related to rxq intervals. > > > > Rename to rxq_next_cycles_store in order to make it more intuitive. > > > > Reported-by: Ilya Maximets <i.maxim...@samsung.com> > > Signed-off-by: Kevin Traynor <ktray...@redhat.com> > > --- > > lib/dpif-netdev.c | 8 ++++---- > > 1 file changed, 4 insertions(+), 4 deletions(-) > > > > diff --git a/lib/dpif-netdev.c b/lib/dpif-netdev.c > > index 071ec14..55d5656 100644 > > --- a/lib/dpif-netdev.c > > +++ b/lib/dpif-netdev.c > > @@ -576,5 +576,5 @@ struct dp_netdev_pmd_thread { > > /* End of the next time interval for which processing cycles > > are stored for each polled rxq. */ > > - long long int rxq_interval; > > + long long int rxq_next_cycle_store; > > > > /* Statistics. */ > > @@ -4507,5 +4507,5 @@ dp_netdev_configure_pmd(struct > dp_netdev_pmd_thread *pmd, struct dp_netdev *dp, > > cmap_init(&pmd->classifiers); > > pmd->next_optimization = time_msec() + > DPCLS_OPTIMIZATION_INTERVAL; > > - pmd->rxq_interval = time_msec() + PMD_RXQ_INTERVAL_LEN; > > + pmd->rxq_next_cycle_store = time_msec() + PMD_RXQ_INTERVAL_LEN; > > hmap_init(&pmd->poll_list); > > hmap_init(&pmd->tx_ports); > > @@ -5951,5 +5951,5 @@ dp_netdev_pmd_try_optimize(struct > dp_netdev_pmd_thread *pmd, > > long long int now = time_msec(); > > > > - if (now > pmd->rxq_interval) { > > + if (now > pmd->rxq_next_cycle_store) { > > /* Get the cycles that were used to process each queue and > store. */ > > for (unsigned i = 0; i < poll_cnt; i++) { > > @@ -5961,5 +5961,5 @@ dp_netdev_pmd_try_optimize(struct > dp_netdev_pmd_thread *pmd, > > } > > /* Start new measuring interval */ > > - pmd->rxq_interval = now + PMD_RXQ_INTERVAL_LEN; > > + pmd->rxq_next_cycle_store = now + PMD_RXQ_INTERVAL_LEN; > > } > > > > -- > > 1.8.3.1 > > > > > > > > > > > > _______________________________________________ > dev mailing list > d...@openvswitch.org > https://mail.openvswitch.org/mailman/listinfo/ovs-dev _______________________________________________ dev mailing list d...@openvswitch.org https://mail.openvswitch.org/mailman/listinfo/ovs-dev