Linux-Next discussions
 help / color / mirror / Atom feed
From: Stephen Rothwell <sfr@canb.auug.org.au>
To: Michael Ellerman <mpe@ellerman.id.au>,
	Benjamin Herrenschmidt <benh@kernel.crashing.org>,
	PowerPC <linuxppc-dev@lists.ozlabs.org>
Cc: Linux-Next Mailing List <linux-next@vger.kernel.org>,
	Linux Kernel Mailing List <linux-kernel@vger.kernel.org>,
	"Naveen N. Rao" <naveen.n.rao@linux.vnet.ibm.com>
Subject: linux-next: manual merge of the powerpc tree with the powerpc-fixes tree
Date: Thu, 10 May 2018 10:17:03 +1000	[thread overview]
Message-ID: <20180510101703.57ffb774@canb.auug.org.au> (raw)

[-- Attachment #1: Type: text/plain, Size: 3631 bytes --]

Hi all,

Today's linux-next merge of the powerpc tree got a conflict in:

  arch/powerpc/include/asm/ftrace.h

between commit:

  edf6a2dfe388 ("powerpc/trace/syscalls: Update syscall name matching logic to account for ppc_ prefix")

from the powerpc-fixes tree and commit:

  c3e59d778403 ("powerpc64/ftrace: Rearrange #ifdef sections in ftrace.h")

from the powerpc tree.

I fixed it up (see below) and can carry the fix as necessary. This
is now fixed as far as linux-next is concerned, but any non trivial
conflicts should be mentioned to your upstream maintainer when your tree
is submitted for merging.  You may also want to consider cooperating
with the maintainer of the conflicting tree to minimise any particularly
complex conflicts.

Michael, I think the version in your merge branch is not quite right ...
-- 
Cheers,
Stephen Rothwell

diff --cc arch/powerpc/include/asm/ftrace.h
index b2dabd06659d,fc3a2203c566..000000000000
--- a/arch/powerpc/include/asm/ftrace.h
+++ b/arch/powerpc/include/asm/ftrace.h
@@@ -66,35 -62,39 +62,54 @@@ struct dyn_arch_ftrace 
  #ifdef CONFIG_DYNAMIC_FTRACE_WITH_REGS
  #define ARCH_SUPPORTS_FTRACE_OPS 1
  #endif
- #endif
+ #endif /* CONFIG_FUNCTION_TRACER */
  
- #if defined(CONFIG_FTRACE_SYSCALLS) && !defined(__ASSEMBLY__)
+ #ifndef __ASSEMBLY__
 -#if defined(CONFIG_FTRACE_SYSCALLS) && defined(PPC64_ELF_ABI_v1)
++#if defined(CONFIG_FTRACE_SYSCALLS)
 +/*
 + * Some syscall entry functions on powerpc start with "ppc_" (fork and clone,
 + * for instance) or ppc32_/ppc64_. We should also match the sys_ variant with
 + * those.
 + */
  #define ARCH_HAS_SYSCALL_MATCH_SYM_NAME
 +#ifdef PPC64_ELF_ABI_v1
  static inline bool arch_syscall_match_sym_name(const char *sym, const char *name)
  {
 -	/*
 -	 * Compare the symbol name with the system call name. Skip the .sys or .SyS
 -	 * prefix from the symbol name and the sys prefix from the system call name and
 -	 * just match the rest. This is only needed on ppc64 since symbol names on
 -	 * 32bit do not start with a period so the generic function will work.
 -	 */
 -	return !strcmp(sym + 4, name + 3);
 +	/* We need to skip past the initial dot, and the __se_sys alias */
 +	return !strcmp(sym + 1, name) ||
 +		(!strncmp(sym, ".__se_sys", 9) && !strcmp(sym + 6, name)) ||
 +		(!strncmp(sym, ".ppc_", 5) && !strcmp(sym + 5, name + 4)) ||
 +		(!strncmp(sym, ".ppc32_", 7) && !strcmp(sym + 7, name + 4)) ||
 +		(!strncmp(sym, ".ppc64_", 7) && !strcmp(sym + 7, name + 4));
  }
 -#endif /* CONFIG_FTRACE_SYSCALLS && PPC64_ELF_ABI_v1 */
 +#else
 +static inline bool arch_syscall_match_sym_name(const char *sym, const char *name)
 +{
 +	return !strcmp(sym, name) ||
 +		(!strncmp(sym, "__se_sys", 8) && !strcmp(sym + 5, name)) ||
 +		(!strncmp(sym, "ppc_", 4) && !strcmp(sym + 4, name + 4)) ||
 +		(!strncmp(sym, "ppc32_", 6) && !strcmp(sym + 6, name + 4)) ||
 +		(!strncmp(sym, "ppc64_", 6) && !strcmp(sym + 6, name + 4));
 +}
- #endif
- #endif /* CONFIG_FTRACE_SYSCALLS && !__ASSEMBLY__ */
++#endif /* PPC64_ELF_ABI_v1 */
++#endif /* CONFIG_FTRACE_SYSCALLS */
+ 
+ #ifdef CONFIG_PPC64
+ #include <asm/paca.h>
+ 
+ static inline void this_cpu_disable_ftrace(void)
+ {
+ 	get_paca()->ftrace_enabled = 0;
+ }
+ 
+ static inline void this_cpu_enable_ftrace(void)
+ {
+ 	get_paca()->ftrace_enabled = 1;
+ }
+ #else /* CONFIG_PPC64 */
+ static inline void this_cpu_disable_ftrace(void) { }
+ static inline void this_cpu_enable_ftrace(void) { }
+ #endif /* CONFIG_PPC64 */
+ #endif /* !__ASSEMBLY__ */
  
  #endif /* _ASM_POWERPC_FTRACE */

[-- Attachment #2: OpenPGP digital signature --]
[-- Type: application/pgp-signature, Size: 488 bytes --]

             reply	other threads:[~2018-05-10  0:17 UTC|newest]

Thread overview: 12+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2018-05-10  0:17 Stephen Rothwell [this message]
2018-05-10  0:45 ` linux-next: manual merge of the powerpc tree with the powerpc-fixes tree Michael Ellerman
  -- strict thread matches above, loose matches on Subject: below --
2018-07-19 23:51 Stephen Rothwell
2018-07-20  2:34 ` Michael Ellerman
2018-03-26 23:11 Stephen Rothwell
2018-03-27  4:52 ` Michael Ellerman
2018-01-17 22:21 Stephen Rothwell
2018-01-19 11:18 ` Michael Ellerman
2017-11-01 21:54 Stephen Rothwell
2017-02-02 22:04 Stephen Rothwell
2016-11-23 23:36 Stephen Rothwell
2016-11-24  2:40 ` 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=20180510101703.57ffb774@canb.auug.org.au \
    --to=sfr@canb.auug.org.au \
    --cc=benh@kernel.crashing.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-next@vger.kernel.org \
    --cc=linuxppc-dev@lists.ozlabs.org \
    --cc=mpe@ellerman.id.au \
    --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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox