public inbox for ltp@lists.linux.it
 help / color / mirror / Atom feed
From: Cyril Hrubis <chrubis@suse.cz>
To: ltp@lists.linux.it
Subject: [LTP] [PATCH] kernel/numa: sleep 2s in test01 for waiting numastat updating
Date: Mon, 30 May 2016 13:55:55 +0200	[thread overview]
Message-ID: <20160530115554.GB6079@rei> (raw)
In-Reply-To: <CAAUgArBQ_D+wY+48YO6VYPWYM70hxr98YshcRRkXDYSoz2VZQg@mail.gmail.com>

Hi!
> Without this patch always get the below error with kernel 4.6.0:
> "ltpapicmd.c:193: Test #1: NUMA hit and localnode increase in node0 is
> less than expected"
> 
> numastat's "local_node" might take some to update even though we malloc
> the local memory for each node.
> 
> So this patch in targets to sleep for 2 seconds until "local_node" get
> updated.

I've seen this failure as well and also the test 3, test 5 and test 6
two of them have sleep 2s already, hence adding sleep 2 is not good
enough it only makes the race condition less probable.

What we should do instead is to get the new stastistic in loop with a
short (~0.1s) sleep util we get the expected value or until timeout has
been reached (~10s). And this should be done ideally as a function
called from each of the numa tests.

-- 
Cyril Hrubis
chrubis@suse.cz

  reply	other threads:[~2016-05-30 11:55 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2016-05-30  9:56 [LTP] [PATCH] kernel/numa: sleep 2s in test01 for waiting numastat updating Dong ZHu
2016-05-30 11:55 ` Cyril Hrubis [this message]
2016-05-31  1:08   ` Dong ZHu
2016-05-31 16:45     ` Cyril Hrubis
2016-07-05  1:22       ` Han Pingtian

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20160530115554.GB6079@rei \
    --to=chrubis@suse.cz \
    --cc=ltp@lists.linux.it \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox