All of lore.kernel.org
 help / color / mirror / Atom feed
From: Michael Ellerman <mpe@ellerman.id.au>
To: "Naveen N. Rao" <naveen.n.rao@linux.vnet.ibm.com>
Cc: Breno Leitao <leitao@debian.org>, linuxppc-dev@lists.ozlabs.org
Subject: Re: [PATCH] powerpc/xmon: Exclude all of xmon/ from ftrace
Date: Tue, 15 Aug 2017 20:04:27 +1000	[thread overview]
Message-ID: <87y3qltadw.fsf@concordia.ellerman.id.au> (raw)
In-Reply-To: <87wp6emj5w.fsf@concordia.ellerman.id.au>

Michael Ellerman <mpe@ellerman.id.au> writes:

> "Naveen N. Rao" <naveen.n.rao@linux.vnet.ibm.com> writes:
>
>> diff --git a/arch/powerpc/xmon/Makefile b/arch/powerpc/xmon/Makefile
>> index 0b2f771593eb..5f95af64cb8f 100644
>> --- a/arch/powerpc/xmon/Makefile
>> +++ b/arch/powerpc/xmon/Makefile
>> @@ -7,6 +7,19 @@ UBSAN_SANITIZE := n
>>  
>>  ccflags-$(CONFIG_PPC64) := $(NO_MINIMAL_TOC)
>>  
>> +ifdef CONFIG_FUNCTION_TRACER
>> +CFLAGS_REMOVE_xmon.o	= -mno-sched-epilog $(CC_FLAGS_FTRACE)
>> +CFLAGS_REMOVE_nonstdio.o = -mno-sched-epilog $(CC_FLAGS_FTRACE)
>> +ifdef CONFIG_XMON_DISASSEMBLY
>> +CFLAGS_REMOVE_ppc-dis.o	= -mno-sched-epilog $(CC_FLAGS_FTRACE)
>> +CFLAGS_REMOVE_ppc-opc.o	= -mno-sched-epilog $(CC_FLAGS_FTRACE)
>> +ifdef CONFIG_SPU_BASE
>> +CFLAGS_REMOVE_spu-dis.o	= -mno-sched-epilog $(CC_FLAGS_FTRACE)
>> +CFLAGS_REMOVE_spu-opc.o	= -mno-sched-epilog $(CC_FLAGS_FTRACE)
>> +endif
>> +endif
>> +endif
>
> Urk.
>
> We want to disable it for everything in the directory, so can you do
> something like:
>
>   ORIG_CFLAGS := $(KBUILD_CFLAGS)
>   KBUILD_CFLAGS = $(subst $(CC_FLAGS_FTRACE),,$(ORIG_CFLAGS))

Yes:

  # Disable ftrace for the entire directory
  ORIG_CFLAGS := $(KBUILD_CFLAGS)
  KBUILD_CFLAGS = $(subst -mno-sched-epilog,,$(subst $(CC_FLAGS_FTRACE),,$(ORIG_CFLAGS)))

Seems to work.

cheers

  reply	other threads:[~2017-08-15 10:04 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2017-08-02 18:25 [PATCH] powerpc/xmon: Exclude all of xmon/ from ftrace Naveen N. Rao
2017-08-08 10:46 ` Michael Ellerman
2017-08-15 10:04   ` Michael Ellerman [this message]
2017-08-16 14:13     ` Naveen N. Rao
2017-08-17 12:54       ` Michael Ellerman
2017-08-16 12:29 ` Michael Ellerman

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=87y3qltadw.fsf@concordia.ellerman.id.au \
    --to=mpe@ellerman.id.au \
    --cc=leitao@debian.org \
    --cc=linuxppc-dev@lists.ozlabs.org \
    --cc=naveen.n.rao@linux.vnet.ibm.com \
    /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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.