On 05.08.21 02:39, Chen, Hongzhan wrote: > > >> -----Original Message----- >> From: Jan Kiszka <jan.kis...@siemens.com> >> Sent: Wednesday, August 4, 2021 6:20 PM >> To: Chen, Hongzhan <hongzhan.c...@intel.com>; xenomai@xenomai.org >> Subject: Re: [PATCH 2/2] testsuite/smokey: net_client: skip late packet >> error in vm mode >> >> On 04.08.21 04:47, Hongzhan Chen via Xenomai wrote: >>> In vm mode, skip late packet error in functional test to avoid >>> test failure. >>> >>> Signed-off-by: Hongzhan Chen <hongzhan.c...@intel.com> >>> >>> diff --git a/testsuite/smokey/net_common/client.c >>> b/testsuite/smokey/net_common/client.c >>> index d13d72918..752ea55ed 100644 >>> --- a/testsuite/smokey/net_common/client.c >>> +++ b/testsuite/smokey/net_common/client.c >>> @@ -204,7 +204,7 @@ static int smokey_net_client_loop(struct >>> smokey_net_client *client) >>> } while (err != -ETIMEDOUT); >>> } >>> >>> - if (glost || glate) >>> + if (glost || (!smokey_on_vm && glate)) >>> fprintf(stderr, "RTnet %s test failed", client->name); >>> if (glost) { >>> if (glost == limit) >>> @@ -214,11 +214,11 @@ static int smokey_net_client_loop(struct >>> smokey_net_client *client) >>> fprintf(stderr, ", %Lu packets lost (%g %%)", >>> glost, 100.0 * glost / limit); >>> } >>> - if (glate) >>> + if (!smokey_on_vm && glate) >>> fprintf(stderr, ", %Lu overruns", glate); >> >> I think we can keep this report, just not mark the test failed in case >> of smokey_on_vm. > > But this string printed out here looks like ugly in case of smokey_on_vm., > do we need to change something ? > How about : > > if (!smokey_on_vm && glate) > fprintf(stderr, "there is %Lu overruns", glate); > else if (glate) > fprintf(stderr, ", %Lu overruns", glate); >
Hmm, what is the difference? Jan -- Siemens AG, T RDA IOT Corporate Competence Center Embedded Linux