[dpdk-dev] [PATCH v6] app/pdump: add pudmp exits with primary support
Burakov, Anatoly
anatoly.burakov at intel.com
Thu May 2 11:12:55 CEST 2019
On 02-May-19 9:32 AM, Suanming.Mou wrote:
>
> On 2019/5/2 16:04, Varghese, Vipin wrote:
>> Hi Suanming,
>>
>> snipped
>>> /* true if x is a power of 2 */
>>> #define POWEROF2(x) ((((x)-1) & (x)) == 0) @@ -413,6 +416,18 @@ struct
>> Can we use ` RTE_IS_POWER_OF_2(n) ' instead of ` POWEROF2`?
>
> I'm sorry, but that line is not add by this patch this time.
>
> Maybe another commit is more suitable to fix the previous code.
Yes, if there are issues with the code that aren't directly related to
the patch and aren't touched by it, they should be addressed as a
separate patch.
>
>>
>>> parse_val { }
>>>
>>> static void
>>> +monitor_primary(void *arg __rte_unused) {
>>> + if (quit_signal)
>>> + return;
>>> +
>>> + if (rte_eal_primary_proc_alive(NULL))
>>> + rte_eal_alarm_set(MONITOR_INTERVAL, monitor_primary,
>>> NULL);
>>> + else
>>> + quit_signal = 1;
>>> +}
>> This is suggestion, why not omit else part with
>>
>> `
>> if (rte_eal_primary_proc_alive(NULL)) {
>> rte_eal_alarm_set(MONITOR_INTERVAL, monitor_primary,NULL);
>> return;
>> }
>> `
> Thanks for the suggestion. It's OK for me. If there's one more vote, I
> will do it.
No preference. Either way works, so i'd keep it as is.
--
Thanks,
Anatoly
More information about the dev
mailing list