public inbox for ltp@lists.linux.it
 help / color / mirror / Atom feed
From: Richard Palethorpe <rpalethorpe@suse.de>
To: Cyril Hrubis <chrubis@suse.cz>
Cc: ltp@lists.linux.it
Subject: Re: [LTP] [PATCH v4] Refactor pidns30 test using new LTP API
Date: Tue, 14 Feb 2023 12:27:50 +0000	[thread overview]
Message-ID: <87sff8mnua.fsf@suse.de> (raw)
In-Reply-To: <Y+t5bm5dn/BzKnYj@yuki>

Hello,

Cyril Hrubis <chrubis@suse.cz> writes:

> Hi!
>> >> +static void run(void)
>> >>   {
>> >> -	int status;
>> >> -	char buf[5];
>> >> -	pid_t cpid;
>> >> +	const struct tst_clone_args args = { CLONE_NEWPID, SIGCHLD };
>> >>   
>> >> -	setup();
>> >> +	remove_mqueue(mqd);
>> >> +	received = 0;
>> > I wonder if we really need to clear the flag here, as far as I can see
>> > we only modify that variable in the child process and that shouldn't
>> > propagate to parent, unless we pass CLONE_VM of course.
>> Flag reset has been added to be 100% sure we are receiving the signal on 
>> -i > 1.
>
> My point was that the variable is only changed in the child process,
> that means that this change will never make it back to the parent since
> the whole VM is copy-on-write...

Indeed, I shouldn't have merged that.

>
> -- 
> Cyril Hrubis
> chrubis@suse.cz


-- 
Thank you,
Richard.

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

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

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-02-08  9:11 [LTP] [PATCH v4] Refactor pidns30 test using new LTP API Andrea Cervesato via ltp
2023-02-10 13:16 ` Cyril Hrubis
2023-02-10 14:18   ` Andrea Cervesato via ltp
2023-02-14  9:47     ` Richard Palethorpe
2023-02-14 12:17       ` Andrea Cervesato via ltp
2023-02-14 12:07     ` Cyril Hrubis
2023-02-14 12:27       ` Richard Palethorpe [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=87sff8mnua.fsf@suse.de \
    --to=rpalethorpe@suse.de \
    --cc=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