kernel-janitors.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* Re: [powerpc:next 24/29] drivers/atm/fore200e.h:263:3: error: redefinition of typedef 'opcode_t' wit
       [not found] <20120906021929.GA16076@localhost>
@ 2012-09-06  2:56 ` Benjamin Herrenschmidt
  2012-09-06  3:41   ` David Miller
                     ` (2 more replies)
  0 siblings, 3 replies; 4+ messages in thread
From: Benjamin Herrenschmidt @ 2012-09-06  2:56 UTC (permalink / raw)
  To: Fengguang Wu; +Cc: linuxppc-dev, Meelis Roos, kernel-janitors, David S. Miller

On Thu, 2012-09-06 at 10:19 +0800, Fengguang Wu wrote:
> Hi Ananth,
> 
> FYI, kernel build failed on
> 
> tree:   git://git.kernel.org/pub/scm/linux/kernel/git/benh/powerpc.git next
> head:   8b64a9dfb091f1eca8b7e58da82f1e7d1d5fe0ad
> commit: 8b7b80b9ebb46dd88fbb94e918297295cf312b59 [24/29] powerpc: Uprobes port to powerpc
> config: powerpc-allmodconfig (attached as .config)
> 
> All related error/warning messages:
> 
> In file included from drivers/atm/fore200e.c:70:0:
> drivers/atm/fore200e.h:263:3: error: redefinition of typedef 'opcode_t' with different type
> arch/powerpc/include/asm/probes.h:25:13: note: previous declaration of 'opcode_t' was here

This is a bit more annoying. Ananth, do we need that to be called
opcode_t for generic reasons or can we make it ppc_opcode_t ? If it has
to remain, I suppose we can try to change that ATM driver to use a
different type name...

(CC'ing Dave and Meelis who from the git history *might* have HW access
to test a possible patch).

Cheers,
Ben.



^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: [powerpc:next 24/29] drivers/atm/fore200e.h:263:3: error: redefinition of typedef 'opcode_t' wit
  2012-09-06  2:56 ` [powerpc:next 24/29] drivers/atm/fore200e.h:263:3: error: redefinition of typedef 'opcode_t' wit Benjamin Herrenschmidt
@ 2012-09-06  3:41   ` David Miller
  2012-09-06  6:27   ` Meelis Roos
  2012-09-06  8:29   ` [PATCH] Rename opcode_t in probes.h to ppc_opcode_t Ananth N Mavinakayanahalli
  2 siblings, 0 replies; 4+ messages in thread
From: David Miller @ 2012-09-06  3:41 UTC (permalink / raw)
  To: benh; +Cc: linuxppc-dev, mroos, fengguang.wu, kernel-janitors

From: Benjamin Herrenschmidt <benh@kernel.crashing.org>
Date: Thu, 06 Sep 2012 12:56:12 +1000

> (CC'ing Dave and Meelis who from the git history *might* have HW access
> to test a possible patch).

Hardware isn't necessary, just make sure the resulting binary is
identical both before and after the change.

^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: [powerpc:next 24/29] drivers/atm/fore200e.h:263:3: error: redefinition of typedef 'opcode_t' wit
  2012-09-06  2:56 ` [powerpc:next 24/29] drivers/atm/fore200e.h:263:3: error: redefinition of typedef 'opcode_t' wit Benjamin Herrenschmidt
  2012-09-06  3:41   ` David Miller
@ 2012-09-06  6:27   ` Meelis Roos
  2012-09-06  8:29   ` [PATCH] Rename opcode_t in probes.h to ppc_opcode_t Ananth N Mavinakayanahalli
  2 siblings, 0 replies; 4+ messages in thread
From: Meelis Roos @ 2012-09-06  6:27 UTC (permalink / raw)
  To: Benjamin Herrenschmidt
  Cc: linuxppc-dev, Fengguang Wu, kernel-janitors, David S. Miller

> (CC'ing Dave and Meelis who from the git history *might* have HW access
> to test a possible patch).

I do have the hardware and can test patches, but it usually takes 
several days until I happen to go where it is and connect the machine.

-- 
Meelis Roos (mroos@linux.ee)

^ permalink raw reply	[flat|nested] 4+ messages in thread

* [PATCH] Rename opcode_t in probes.h to ppc_opcode_t
  2012-09-06  2:56 ` [powerpc:next 24/29] drivers/atm/fore200e.h:263:3: error: redefinition of typedef 'opcode_t' wit Benjamin Herrenschmidt
  2012-09-06  3:41   ` David Miller
  2012-09-06  6:27   ` Meelis Roos
@ 2012-09-06  8:29   ` Ananth N Mavinakayanahalli
  2 siblings, 0 replies; 4+ messages in thread
From: Ananth N Mavinakayanahalli @ 2012-09-06  8:29 UTC (permalink / raw)
  To: Benjamin Herrenschmidt, Stephen Rothwell
  Cc: linuxppc-dev, Meelis Roos, Fengguang Wu, kernel-janitors,
	David S. Miller

On Thu, Sep 06, 2012 at 12:56:12PM +1000, Benjamin Herrenschmidt wrote:
> On Thu, 2012-09-06 at 10:19 +0800, Fengguang Wu wrote:
> > Hi Ananth,
> > 
> > FYI, kernel build failed on
> > 
> > tree:   git://git.kernel.org/pub/scm/linux/kernel/git/benh/powerpc.git next
> > head:   8b64a9dfb091f1eca8b7e58da82f1e7d1d5fe0ad
> > commit: 8b7b80b9ebb46dd88fbb94e918297295cf312b59 [24/29] powerpc: Uprobes port to powerpc
> > config: powerpc-allmodconfig (attached as .config)
> > 
> > All related error/warning messages:
> > 
> > In file included from drivers/atm/fore200e.c:70:0:
> > drivers/atm/fore200e.h:263:3: error: redefinition of typedef 'opcode_t' with different type
> > arch/powerpc/include/asm/probes.h:25:13: note: previous declaration of 'opcode_t' was here
> 
> This is a bit more annoying. Ananth, do we need that to be called
> opcode_t for generic reasons or can we make it ppc_opcode_t ? If it has
> to remain, I suppose we can try to change that ATM driver to use a
> different type name...

We can make it ppc_opcode_t. Attached is the patch that fixes this.

Regards,
Ananth
---

From: Ananth N Mavinakayanahalli <ananth@in.ibm.com>

tree:   git://git.kernel.org/pub/scm/linux/kernel/git/benh/powerpc.git next
head:   8b64a9dfb091f1eca8b7e58da82f1e7d1d5fe0ad
commit: 8b7b80b9ebb46dd88fbb94e918297295cf312b59 [24/29] powerpc: Uprobes port to powerpc
config: powerpc-allmodconfig (attached as .config)

All related error/warning messages:

In file included from drivers/atm/fore200e.c:70:0:
drivers/atm/fore200e.h:263:3: error: redefinition of typedef 'opcode_t' with different type
arch/powerpc/include/asm/probes.h:25:13: note: previous declaration of 'opcode_t' was here

Fix the namespace clash by making opcode_t in probes.h to ppc_opcode_t.

Signed-off-by: Ananth N Mavinakayanahalli <ananth@in.ibm.com>
---
Index: linux-tip-22aug/arch/powerpc/include/asm/probes.h
=================================--- linux-tip-22aug.orig/arch/powerpc/include/asm/probes.h	2012-09-04 20:00:19.747069793 +0530
+++ linux-tip-22aug/arch/powerpc/include/asm/probes.h	2012-09-04 20:42:08.147286718 +0530
@@ -22,7 +22,7 @@
  */
 #include <linux/types.h>
 
-typedef u32 opcode_t;
+typedef u32 ppc_opcode_t;
 #define BREAKPOINT_INSTRUCTION	0x7fe00008	/* trap */
 
 /* Trap definitions per ISA */
Index: linux-tip-22aug/arch/powerpc/include/asm/uprobes.h
=================================--- linux-tip-22aug.orig/arch/powerpc/include/asm/uprobes.h	2012-09-04 20:01:30.617071747 +0530
+++ linux-tip-22aug/arch/powerpc/include/asm/uprobes.h	2012-09-04 20:42:26.657287349 +0530
@@ -25,7 +25,7 @@
 #include <linux/notifier.h>
 #include <asm/probes.h>
 
-typedef opcode_t uprobe_opcode_t;
+typedef ppc_opcode_t uprobe_opcode_t;
 
 #define MAX_UINSN_BYTES		4
 #define UPROBE_XOL_SLOT_BYTES	(MAX_UINSN_BYTES)
Index: linux-tip-22aug/arch/powerpc/include/asm/kprobes.h
=================================--- linux-tip-22aug.orig/arch/powerpc/include/asm/kprobes.h	2012-09-04 20:00:19.747069793 +0530
+++ linux-tip-22aug/arch/powerpc/include/asm/kprobes.h	2012-09-04 20:42:15.557286955 +0530
@@ -36,7 +36,7 @@
 struct pt_regs;
 struct kprobe;
 
-typedef opcode_t kprobe_opcode_t;
+typedef ppc_opcode_t kprobe_opcode_t;
 #define MAX_INSN_SIZE 1
 
 #ifdef CONFIG_PPC64


^ permalink raw reply	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2012-09-06  8:29 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
     [not found] <20120906021929.GA16076@localhost>
2012-09-06  2:56 ` [powerpc:next 24/29] drivers/atm/fore200e.h:263:3: error: redefinition of typedef 'opcode_t' wit Benjamin Herrenschmidt
2012-09-06  3:41   ` David Miller
2012-09-06  6:27   ` Meelis Roos
2012-09-06  8:29   ` [PATCH] Rename opcode_t in probes.h to ppc_opcode_t Ananth N Mavinakayanahalli

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).