linuxppc-dev.lists.ozlabs.org archive mirror
 help / color / mirror / Atom feed
From: "Naveen N. Rao" <naveen.n.rao@linux.vnet.ibm.com>
To: Michael Ellerman <mpe@ellerman.id.au>
Cc: Anton Blanchard <anton@samba.org>, linuxppc-dev@lists.ozlabs.org
Subject: Re: [PATCH] selftests/powerpc: add test to verify rfi flush across a system call
Date: Mon, 21 May 2018 20:40:55 +0530	[thread overview]
Message-ID: <1526914785.dnc989oa1u.naveen@linux.ibm.com> (raw)
In-Reply-To: <877eo3nle3.fsf@concordia.ellerman.id.au>

Michael Ellerman wrote:
> "Naveen N. Rao" <naveen.n.rao@linux.vnet.ibm.com> writes:
>=20
>> diff --git a/tools/testing/selftests/powerpc/utils.c b/tools/testing/sel=
ftests/powerpc/utils.c
>> index d46916867a6f..c6b1d20ed3ba 100644
>> --- a/tools/testing/selftests/powerpc/utils.c
>> +++ b/tools/testing/selftests/powerpc/utils.c
>> @@ -104,3 +111,149 @@ int pick_online_cpu(void)
>>  	printf("No cpus in affinity mask?!\n");
>>  	return -1;
>>  }
> ...
>> +
>> +static void sigill_handler(int signr, siginfo_t *info, void *unused)
>> +{
>> +	static int warned =3D 0;
>> +	ucontext_t *ctx =3D (ucontext_t *)unused;
>> +	unsigned int *pc =3D (unsigned int *)ctx->uc_mcontext.gp_regs[PT_NIP];
>=20
> The above doesn't work on 32-bit, and this code is sometimes built 32-bit=
.
>=20
> For an example of how to handle 32 and 64-bit, see eg:
>=20
>   tools/testing/selftests/powerpc/primitives/load_unaligned_zeropad.c

Thanks. I'll post a v2 that addresses the 32-bit build issue.

- Naveen

=

      reply	other threads:[~2018-05-21 15:11 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2018-04-06 16:55 [PATCH] selftests/powerpc: add test to verify rfi flush across a system call Naveen N. Rao
2018-05-17  1:03 ` Michael Ellerman
2018-05-21 15:10   ` Naveen N. Rao [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=1526914785.dnc989oa1u.naveen@linux.ibm.com \
    --to=naveen.n.rao@linux.vnet.ibm.com \
    --cc=anton@samba.org \
    --cc=linuxppc-dev@lists.ozlabs.org \
    --cc=mpe@ellerman.id.au \
    /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;
as well as URLs for NNTP newsgroup(s).