public inbox for ltp@lists.linux.it
 help / color / mirror / Atom feed
From: Leo Liang <ycliang@andestech.com>
To: Petr Vorel <pvorel@suse.cz>
Cc: ltp@lists.linux.it
Subject: Re: [LTP] [v2 2/2] lib/tst_pid.c: Increase PIDS_RESERVED to avoid fork failure.
Date: Tue, 14 Feb 2023 14:14:17 +0000	[thread overview]
Message-ID: <Y+uXOX+EA/hOFsh4@ubuntu01> (raw)
In-Reply-To: <Y+uOimkvJ76Q8diX@pevik>

Hi Petr,

On Tue, Feb 14, 2023 at 02:37:14PM +0100, Petr Vorel wrote:
> Hi Leo,
> 
> > After Adjusting how we count used pid, we increase
> > the number of PIDS_RESERVED to void fork failure.
> nit: in this case I'd actually keep changes in single commit
> (otherwise first commit alone would break tests),
> 

That makes sense!
Then we could probably drop this v2 patch
and stay with the v1?

Best regards,
Leo

> Kind regards,
> Petr
> 
> > Suggested-by: Petr Vorel <pvorel@suse.cz>
> > Signed-off-by: Leo Yu-Chi Liang <ycliang@andestech.com>
> > Reviewed-by: Petr Vorel <pvorel@suse.cz>
> > ---
> > Changes v1 -> v2
> > * Split into two patches
> > ---
> >  lib/tst_pid.c | 2 +-
> >  1 file changed, 1 insertion(+), 1 deletion(-)
> 
> > diff --git a/lib/tst_pid.c b/lib/tst_pid.c
> > index a282f8cc9..7582e4828 100644
> > --- a/lib/tst_pid.c
> > +++ b/lib/tst_pid.c
> > @@ -36,7 +36,7 @@
> >  #define CGROUPS_V1_SLICE_FMT "/sys/fs/cgroup/pids/user.slice/user-%d.slice/pids.max"
> >  #define CGROUPS_V2_SLICE_FMT "/sys/fs/cgroup/user.slice/user-%d.slice/pids.max"
> >  /* Leave some available processes for the OS */
> > -#define PIDS_RESERVE 50
> > +#define PIDS_RESERVE 200
> 
> >  pid_t tst_get_unused_pid_(void (*cleanup_fn) (void))
> >  {

-- 
Mailing list info: https://lists.linux.it/listinfo/ltp

      parent reply	other threads:[~2023-02-14 14:14 UTC|newest]

Thread overview: 12+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-02-14 12:25 [LTP] [v2 1/2] lib/tst_pid.c: Count used pid by traversing /proc Leo Yu-Chi Liang
2023-02-14 12:25 ` [LTP] [v2 2/2] lib/tst_pid.c: Increase PIDS_RESERVED to avoid fork failure Leo Yu-Chi Liang
2023-02-14 13:37   ` Petr Vorel
2023-02-14 13:43     ` Cyril Hrubis
2023-02-14 14:17       ` Leo Liang
2023-02-14 14:26         ` Cyril Hrubis
2023-02-14 15:09           ` Cyril Hrubis
2023-02-16  5:40             ` Leo Liang
2023-02-16  8:46               ` Cyril Hrubis
2023-02-16 14:52                 ` Leo Liang
2023-02-16 22:59                   ` Petr Vorel
2023-02-14 14:14     ` Leo Liang [this message]

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=Y+uXOX+EA/hOFsh4@ubuntu01 \
    --to=ycliang@andestech.com \
    --cc=ltp@lists.linux.it \
    --cc=pvorel@suse.cz \
    /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