[dpdk-dev] [PATCH] testpmd: Fix wrong message in testpmd

Qiu, Michael michael.qiu at intel.com
Tue Jul 28 20:44:20 CEST 2015


On 2015/7/8 2:04, Richardson, Bruce wrote:
> On Wed, Jul 08, 2015 at 07:16:21AM +0000, Qiu, Michael wrote:

[.../...]

>>>  		port = &ports[pi];
>>>  		if (rte_atomic16_cmpset(&(port->port_status),
>>> +			RTE_PORT_CLOSED, RTE_PORT_CLOSED) == 1) {
>>> +			printf("Port %d is already closed\n", pi);
>>> +			continue;
>>> +		}
>>> +
>>> +		if (rte_atomic16_cmpset(&(port->port_status),
>>>  			RTE_PORT_STOPPED, RTE_PORT_HANDLING) == 0) {
>>>  			printf("Port %d is now not stopped\n", pi);
>>>  			continue;
> I know it's not part of your change, but "Now not stopped" doesn't really seem
> right to me. What is the message actually trying to report?

It is just make sure the port is in stopped state. So it will check if
it is not in RTE_PORT_STOPPED stat or fail to set to RTE_PORT_HANDLING,
it will report as "now not stopped"


Thanks,
Michael
>
> /Bruce



More information about the dev mailing list