linux-arm-kernel.lists.infradead.org archive mirror
 help / color / mirror / Atom feed
From: linux@arm.linux.org.uk (Russell King - ARM Linux)
To: linux-arm-kernel@lists.infradead.org
Subject: [PATCH] ARM: kprobes: Eliminate test code's use of BX instruction on ARMv4 CPUs
Date: Mon, 19 Jan 2015 17:27:50 +0000	[thread overview]
Message-ID: <20150119172750.GC26493@n2100.arm.linux.org.uk> (raw)
In-Reply-To: <1421687930.4201.21.camel@linaro.org>

On Mon, Jan 19, 2015 at 05:18:50PM +0000, Jon Medhurst (Tixy) wrote:
> diff --git a/arch/arm/probes/kprobes/test-arm.c b/arch/arm/probes/kprobes/test-arm.c
> index e72b07e..5c6e37e 100644
> --- a/arch/arm/probes/kprobes/test-arm.c
> +++ b/arch/arm/probes/kprobes/test-arm.c
> @@ -215,9 +215,11 @@ void kprobe_arm_test_cases(void)
>  	TEST_UNSUPPORTED("msr	cpsr_f, lr")
>  	TEST_UNSUPPORTED("msr	spsr, r0")
>  
> +#if (__LINUX_ARM_ARCH__ >= 5) || defined(CONFIG_CPU_32v4T)
>  	TEST_BF_R("bx	r",0,2f,"")
>  	TEST_BB_R("bx	r",7,2f,"")
>  	TEST_BF_R("bxeq	r",14,2f,"")
> +#endif

Unnecessary ()... and this isn't correct.  With a multi-platform kernel, we
can end up with CONFIG_CPU_32v4 and CONFIG_CPU_32v4T both set.

I think:

#if __LINUX_ARM_ARCH__ >= 5 || \
    (__LINUX_ARM_ARCH__ == 4 && !defined(CONFIG_CPU_32v4))

would cover it.

-- 
FTTC broadband for 0.8mile line: currently at 10.5Mbps down 400kbps up
according to speedtest.net.

  reply	other threads:[~2015-01-19 17:27 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2015-01-19 17:18 [PATCH] ARM: kprobes: Eliminate test code's use of BX instruction on ARMv4 CPUs Jon Medhurst (Tixy)
2015-01-19 17:27 ` Russell King - ARM Linux [this message]
2015-01-19 18:19   ` Jon Medhurst (Tixy)

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=20150119172750.GC26493@n2100.arm.linux.org.uk \
    --to=linux@arm.linux.org.uk \
    --cc=linux-arm-kernel@lists.infradead.org \
    /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).