[ovs-dev] [PATCH] dpif-netdev: Remove unnecessary resets on new rxqs.

Kevin Traynor ktraynor at redhat.com
Sun Nov 12 11:26:06 UTC 2017


On 11/10/2017 11:42 PM, Gregory Rose wrote:
> On 11/10/2017 11:42 PM, Kevin Traynor wrote:
>> 38259bd7eb21 added a memset for the dp_netdev_rxq of new rxq's
>> to remove a valgrind warning. Since it is all set to 0, we can
>> remove explicit reset of some fields.
>>
>> Signed-off-by: Kevin Traynor <ktraynor at redhat.com>
>> ---
>>   lib/dpif-netdev.c | 7 -------
>>   1 file changed, 7 deletions(-)
>>
>> diff --git a/lib/dpif-netdev.c b/lib/dpif-netdev.c
>> index d9e2912..8830c41 100644
>> --- a/lib/dpif-netdev.c
>> +++ b/lib/dpif-netdev.c
>> @@ -3315,11 +3315,4 @@ port_reconfigure(struct dp_netdev_port *port)
>>           port->rxqs[i].port = port;
>>   -        if (new_queue) {
>> -            dp_netdev_rxq_set_cycles(&port->rxqs[i],
>> RXQ_CYCLES_PROC_CURR, 0);
>> -            dp_netdev_rxq_set_cycles(&port->rxqs[i],
>> RXQ_CYCLES_PROC_HIST, 0);
>> -            for (unsigned j = 0; j < PMD_RXQ_INTERVAL_MAX; j++) {
>> -                dp_netdev_rxq_set_intrvl_cycles(&port->rxqs[i], 0);
>> -            }
>> -        }
>>           err = netdev_rxq_open(netdev, &port->rxqs[i].rx, i);
>>           if (err) {
> 
> Looks good but should it have a "fixes" tag for the patch that did the
> memset?
> 

Thanks for reviewing Greg. I didn't think it should be a fixes, as I
viewed this as an optimization/cleanup of already existing code that is
possible because of the memset patch. I can try to make commit message a
bit more explicit if that's not coming across.

Kevin.

> Thanks,
> 
> - Greg



More information about the dev mailing list