All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH] powerpc/83xx: Fix few build errors with CONFIG_QUICC_ENGINE=n
@ 2008-12-05 16:55 Anton Vorontsov
  2008-12-05 16:59 ` [PATCH] powerpc/qe: " Anton Vorontsov
                   ` (4 more replies)
  0 siblings, 5 replies; 12+ messages in thread
From: Anton Vorontsov @ 2008-12-05 16:55 UTC (permalink / raw)
  To: Kumar Gala; +Cc: linuxppc-dev, Timur Tabi

Some 83xx boards were not ready for the optional QUICC Engine support.

This patch fixes following build errors:

arch/powerpc/platforms/built-in.o: In function `flush_disable_caches':
(.text+0xb308): undefined reference to `par_io_data_set'
arch/powerpc/platforms/built-in.o: In function `flush_disable_caches':
(.text+0xb334): undefined reference to `par_io_data_set'
arch/powerpc/platforms/built-in.o: In function `flush_disable_caches':
(.text+0xb408): undefined reference to `qe_ic_get_high_irq'
arch/powerpc/platforms/built-in.o: In function `flush_disable_caches':
(.text+0xb478): undefined reference to `qe_ic_get_low_irq'
arch/powerpc/platforms/built-in.o: In function `mpc832x_spi_init':
mpc832x_rdb.c:(.init.text+0x574c): undefined reference to `par_io_config_pin'
mpc832x_rdb.c:(.init.text+0x5768): undefined reference to `par_io_config_pin'
mpc832x_rdb.c:(.init.text+0x5784): undefined reference to `par_io_config_pin'
mpc832x_rdb.c:(.init.text+0x57a0): undefined reference to `par_io_config_pin'
mpc832x_rdb.c:(.init.text+0x57bc): undefined reference to `par_io_config_pin'
arch/powerpc/platforms/built-in.o:mpc832x_rdb.c:(.init.text+0x57d8): more undefined references to `par_io_config_pin' follow
arch/powerpc/platforms/built-in.o: In function `mpc836x_rdk_init_IRQ':
mpc836x_rdk.c:(.init.text+0x5e84): undefined reference to `qe_ic_init'
arch/powerpc/platforms/built-in.o: In function `mpc836x_rdk_setup_arch':
mpc836x_rdk.c:(.init.text+0x5f10): undefined reference to `qe_reset'
make: *** [.tmp_vmlinux1] Error 1

Signed-off-by: Anton Vorontsov <avorontsov@ru.mvista.com>
---

This patch implements traditional way of !QE case handling.
Alternative version is coming (w/o ifdefs in the board files).

p.s. I don't know if it is 2.6.28 material...

 arch/powerpc/platforms/83xx/mpc832x_rdb.c |    3 ++-
 arch/powerpc/platforms/83xx/mpc836x_rdk.c |    6 ++++--
 2 files changed, 6 insertions(+), 3 deletions(-)

diff --git a/arch/powerpc/platforms/83xx/mpc832x_rdb.c b/arch/powerpc/platforms/83xx/mpc832x_rdb.c
index 0300268..7e20e91 100644
--- a/arch/powerpc/platforms/83xx/mpc832x_rdb.c
+++ b/arch/powerpc/platforms/83xx/mpc832x_rdb.c
@@ -38,6 +38,7 @@
 #define DBG(fmt...)
 #endif
 
+#ifdef CONFIG_QUICC_ENGINE
 static void mpc83xx_spi_activate_cs(u8 cs, u8 polarity)
 {
 	pr_debug("%s %d %d\n", __func__, cs, polarity);
@@ -77,8 +78,8 @@ static int __init mpc832x_spi_init(void)
 			    mpc83xx_spi_activate_cs,
 			    mpc83xx_spi_deactivate_cs);
 }
-
 machine_device_initcall(mpc832x_rdb, mpc832x_spi_init);
+#endif /* CONFIG_QUICC_ENGINE */
 
 /* ************************************************************************
  *
diff --git a/arch/powerpc/platforms/83xx/mpc836x_rdk.c b/arch/powerpc/platforms/83xx/mpc836x_rdk.c
index a5273bb..b0090aa 100644
--- a/arch/powerpc/platforms/83xx/mpc836x_rdk.c
+++ b/arch/powerpc/platforms/83xx/mpc836x_rdk.c
@@ -51,8 +51,9 @@ static void __init mpc836x_rdk_setup_arch(void)
 	for_each_compatible_node(np, "pci", "fsl,mpc8349-pci")
 		mpc83xx_add_bridge(np);
 #endif
-
+#ifdef CONFIG_QUICC_ENGINE
 	qe_reset();
+#endif
 }
 
 static void __init mpc836x_rdk_init_IRQ(void)
@@ -71,13 +72,14 @@ static void __init mpc836x_rdk_init_IRQ(void)
 	 */
 	ipic_set_default_priority();
 	of_node_put(np);
-
+#ifdef CONFIG_QUICC_ENGINE
 	np = of_find_compatible_node(NULL, NULL, "fsl,qe-ic");
 	if (!np)
 		return;
 
 	qe_ic_init(np, 0, qe_ic_cascade_low_ipic, qe_ic_cascade_high_ipic);
 	of_node_put(np);
+#endif
 }
 
 /*
-- 
1.5.6.5

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

* [PATCH] powerpc/qe: Fix few build errors with CONFIG_QUICC_ENGINE=n
  2008-12-05 16:55 [PATCH] powerpc/83xx: Fix few build errors with CONFIG_QUICC_ENGINE=n Anton Vorontsov
@ 2008-12-05 16:59 ` Anton Vorontsov
  2008-12-30 17:19   ` Kumar Gala
  2008-12-05 17:09 ` [PATCH] powerpc/83xx: " Kumar Gala
                   ` (3 subsequent siblings)
  4 siblings, 1 reply; 12+ messages in thread
From: Anton Vorontsov @ 2008-12-05 16:59 UTC (permalink / raw)
  To: Kumar Gala; +Cc: linuxppc-dev, Timur Tabi

Some 83xx boards were not ready for the optional QUICC Engine support.

This patch fixes following build errors:

arch/powerpc/platforms/built-in.o: In function `flush_disable_caches':
(.text+0xb308): undefined reference to `par_io_data_set'
arch/powerpc/platforms/built-in.o: In function `flush_disable_caches':
(.text+0xb334): undefined reference to `par_io_data_set'
arch/powerpc/platforms/built-in.o: In function `flush_disable_caches':
(.text+0xb408): undefined reference to `qe_ic_get_high_irq'
arch/powerpc/platforms/built-in.o: In function `flush_disable_caches':
(.text+0xb478): undefined reference to `qe_ic_get_low_irq'
arch/powerpc/platforms/built-in.o: In function `mpc832x_spi_init':
mpc832x_rdb.c:(.init.text+0x574c): undefined reference to `par_io_config_pin'
mpc832x_rdb.c:(.init.text+0x5768): undefined reference to `par_io_config_pin'
mpc832x_rdb.c:(.init.text+0x5784): undefined reference to `par_io_config_pin'
mpc832x_rdb.c:(.init.text+0x57a0): undefined reference to `par_io_config_pin'
mpc832x_rdb.c:(.init.text+0x57bc): undefined reference to `par_io_config_pin'
arch/powerpc/platforms/built-in.o:mpc832x_rdb.c:(.init.text+0x57d8): more undefined references to `par_io_config_pin' follow
arch/powerpc/platforms/built-in.o: In function `mpc836x_rdk_init_IRQ':
mpc836x_rdk.c:(.init.text+0x5e84): undefined reference to `qe_ic_init'
arch/powerpc/platforms/built-in.o: In function `mpc836x_rdk_setup_arch':
mpc836x_rdk.c:(.init.text+0x5f10): undefined reference to `qe_reset'
make: *** [.tmp_vmlinux1] Error 1

Signed-off-by: Anton Vorontsov <avorontsov@ru.mvista.com>
---
 arch/powerpc/include/asm/qe.h    |   16 ++++++++++++++--
 arch/powerpc/include/asm/qe_ic.h |   21 +++++++++++++++++----
 2 files changed, 31 insertions(+), 6 deletions(-)

diff --git a/arch/powerpc/include/asm/qe.h b/arch/powerpc/include/asm/qe.h
index 3227440..a0a1531 100644
--- a/arch/powerpc/include/asm/qe.h
+++ b/arch/powerpc/include/asm/qe.h
@@ -86,7 +86,11 @@ static inline bool qe_clock_is_brg(enum qe_clock clk)
 extern spinlock_t cmxgcr_lock;
 
 /* Export QE common operations */
+#ifdef CONFIG_QUICC_ENGINE
 extern void __init qe_reset(void);
+#else
+static inline void qe_reset(void) {}
+#endif
 
 /* QE PIO */
 #define QE_PIO_PINS 32
@@ -103,16 +107,24 @@ struct qe_pio_regs {
 #endif
 };
 
-extern int par_io_init(struct device_node *np);
-extern int par_io_of_config(struct device_node *np);
 #define QE_PIO_DIR_IN	2
 #define QE_PIO_DIR_OUT	1
 extern void __par_io_config_pin(struct qe_pio_regs __iomem *par_io, u8 pin,
 				int dir, int open_drain, int assignment,
 				int has_irq);
+#ifdef CONFIG_QUICC_ENGINE
+extern int par_io_init(struct device_node *np);
+extern int par_io_of_config(struct device_node *np);
 extern int par_io_config_pin(u8 port, u8 pin, int dir, int open_drain,
 			     int assignment, int has_irq);
 extern int par_io_data_set(u8 port, u8 pin, u8 val);
+#else
+static inline int par_io_init(struct device_node *np) { return -ENOSYS; }
+static inline int par_io_of_config(struct device_node *np) { return -ENOSYS; }
+static inline int par_io_config_pin(u8 port, u8 pin, int dir, int open_drain,
+		int assignment, int has_irq) { return -ENOSYS; }
+static inline int par_io_data_set(u8 port, u8 pin, u8 val) { return -ENOSYS; }
+#endif /* CONFIG_QUICC_ENGINE */
 
 /*
  * Pin multiplexing functions.
diff --git a/arch/powerpc/include/asm/qe_ic.h b/arch/powerpc/include/asm/qe_ic.h
index 56a7745..cf51966 100644
--- a/arch/powerpc/include/asm/qe_ic.h
+++ b/arch/powerpc/include/asm/qe_ic.h
@@ -17,6 +17,9 @@
 
 #include <linux/irq.h>
 
+struct device_node;
+struct qe_ic;
+
 #define NUM_OF_QE_IC_GROUPS	6
 
 /* Flags when we init the QE IC */
@@ -54,17 +57,27 @@ enum qe_ic_grp_id {
 	QE_IC_GRP_RISCB		/* QE interrupt controller RISC group B */
 };
 
+#ifdef CONFIG_QUICC_ENGINE
 void qe_ic_init(struct device_node *node, unsigned int flags,
 		void (*low_handler)(unsigned int irq, struct irq_desc *desc),
 		void (*high_handler)(unsigned int irq, struct irq_desc *desc));
+unsigned int qe_ic_get_low_irq(struct qe_ic *qe_ic);
+unsigned int qe_ic_get_high_irq(struct qe_ic *qe_ic);
+#else
+static inline void qe_ic_init(struct device_node *node, unsigned int flags,
+		void (*low_handler)(unsigned int irq, struct irq_desc *desc),
+		void (*high_handler)(unsigned int irq, struct irq_desc *desc))
+{}
+static inline unsigned int qe_ic_get_low_irq(struct qe_ic *qe_ic)
+{ return 0; }
+static inline unsigned int qe_ic_get_high_irq(struct qe_ic *qe_ic)
+{ return 0; }
+#endif /* CONFIG_QUICC_ENGINE */
+
 void qe_ic_set_highest_priority(unsigned int virq, int high);
 int qe_ic_set_priority(unsigned int virq, unsigned int priority);
 int qe_ic_set_high_priority(unsigned int virq, unsigned int priority, int high);
 
-struct qe_ic;
-unsigned int qe_ic_get_low_irq(struct qe_ic *qe_ic);
-unsigned int qe_ic_get_high_irq(struct qe_ic *qe_ic);
-
 static inline void qe_ic_cascade_low_ipic(unsigned int irq,
 					  struct irq_desc *desc)
 {
-- 
1.5.6.5

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

* Re: [PATCH] powerpc/83xx: Fix few build errors with CONFIG_QUICC_ENGINE=n
  2008-12-05 16:55 [PATCH] powerpc/83xx: Fix few build errors with CONFIG_QUICC_ENGINE=n Anton Vorontsov
  2008-12-05 16:59 ` [PATCH] powerpc/qe: " Anton Vorontsov
@ 2008-12-05 17:09 ` Kumar Gala
  2008-12-05 17:14   ` Timur Tabi
  2008-12-16 18:18 ` Kumar Gala
                   ` (2 subsequent siblings)
  4 siblings, 1 reply; 12+ messages in thread
From: Kumar Gala @ 2008-12-05 17:09 UTC (permalink / raw)
  To: Anton Vorontsov; +Cc: linuxppc-dev, Timur Tabi


On Dec 5, 2008, at 10:55 AM, Anton Vorontsov wrote:

> This patch implements traditional way of !QE case handling.
> Alternative version is coming (w/o ifdefs in the board files).
>
> p.s. I don't know if it is 2.6.28 material...
>
> arch/powerpc/platforms/83xx/mpc832x_rdb.c |    3 ++-
> arch/powerpc/platforms/83xx/mpc836x_rdk.c |    6 ++++--
> 2 files changed, 6 insertions(+), 3 deletions(-)

this doesn't seem critical right now so I'd say we wait for .29

- k

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

* Re: [PATCH] powerpc/83xx: Fix few build errors with CONFIG_QUICC_ENGINE=n
  2008-12-05 17:09 ` [PATCH] powerpc/83xx: " Kumar Gala
@ 2008-12-05 17:14   ` Timur Tabi
  0 siblings, 0 replies; 12+ messages in thread
From: Timur Tabi @ 2008-12-05 17:14 UTC (permalink / raw)
  To: Kumar Gala; +Cc: linuxppc-dev

Kumar Gala wrote:

> this doesn't seem critical right now so I'd say we wait for .29

I agree.  None of the defconfigs or default behavior expose this bug.  I don't
expect anyone to actually turn off the QE in a real-world situation.

-- 
Timur Tabi
Linux kernel developer at Freescale

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

* Re: [PATCH] powerpc/83xx: Fix few build errors with CONFIG_QUICC_ENGINE=n
  2008-12-05 16:55 [PATCH] powerpc/83xx: Fix few build errors with CONFIG_QUICC_ENGINE=n Anton Vorontsov
  2008-12-05 16:59 ` [PATCH] powerpc/qe: " Anton Vorontsov
  2008-12-05 17:09 ` [PATCH] powerpc/83xx: " Kumar Gala
@ 2008-12-16 18:18 ` Kumar Gala
  2008-12-16 18:44   ` Anton Vorontsov
  2008-12-22 17:12 ` Anton Vorontsov
  2008-12-30 17:19 ` Kumar Gala
  4 siblings, 1 reply; 12+ messages in thread
From: Kumar Gala @ 2008-12-16 18:18 UTC (permalink / raw)
  To: Anton Vorontsov; +Cc: linuxppc-dev, Timur Tabi


On Dec 5, 2008, at 10:55 AM, Anton Vorontsov wrote:

> Some 83xx boards were not ready for the optional QUICC Engine support.
>
> This patch fixes following build errors:
>
> arch/powerpc/platforms/built-in.o: In function `flush_disable_caches':
> (.text+0xb308): undefined reference to `par_io_data_set'
> arch/powerpc/platforms/built-in.o: In function `flush_disable_caches':
> (.text+0xb334): undefined reference to `par_io_data_set'
> arch/powerpc/platforms/built-in.o: In function `flush_disable_caches':
> (.text+0xb408): undefined reference to `qe_ic_get_high_irq'
> arch/powerpc/platforms/built-in.o: In function `flush_disable_caches':
> (.text+0xb478): undefined reference to `qe_ic_get_low_irq'
> arch/powerpc/platforms/built-in.o: In function `mpc832x_spi_init':
> mpc832x_rdb.c:(.init.text+0x574c): undefined reference to  
> `par_io_config_pin'
> mpc832x_rdb.c:(.init.text+0x5768): undefined reference to  
> `par_io_config_pin'
> mpc832x_rdb.c:(.init.text+0x5784): undefined reference to  
> `par_io_config_pin'
> mpc832x_rdb.c:(.init.text+0x57a0): undefined reference to  
> `par_io_config_pin'
> mpc832x_rdb.c:(.init.text+0x57bc): undefined reference to  
> `par_io_config_pin'
> arch/powerpc/platforms/built-in.o:mpc832x_rdb.c:(.init.text+0x57d8):  
> more undefined references to `par_io_config_pin' follow
> arch/powerpc/platforms/built-in.o: In function `mpc836x_rdk_init_IRQ':
> mpc836x_rdk.c:(.init.text+0x5e84): undefined reference to `qe_ic_init'
> arch/powerpc/platforms/built-in.o: In function  
> `mpc836x_rdk_setup_arch':
> mpc836x_rdk.c:(.init.text+0x5f10): undefined reference to `qe_reset'
> make: *** [.tmp_vmlinux1] Error 1
>
> Signed-off-by: Anton Vorontsov <avorontsov@ru.mvista.com>
> ---
>
> This patch implements traditional way of !QE case handling.
> Alternative version is coming (w/o ifdefs in the board files).
>
> p.s. I don't know if it is 2.6.28 material...

what's the state of this patch vs the alternate version?

- k

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

* Re: [PATCH] powerpc/83xx: Fix few build errors with CONFIG_QUICC_ENGINE=n
  2008-12-16 18:18 ` Kumar Gala
@ 2008-12-16 18:44   ` Anton Vorontsov
  2008-12-16 19:00     ` Scott Wood
  0 siblings, 1 reply; 12+ messages in thread
From: Anton Vorontsov @ 2008-12-16 18:44 UTC (permalink / raw)
  To: Kumar Gala; +Cc: linuxppc-dev, Timur Tabi

On Tue, Dec 16, 2008 at 12:18:07PM -0600, Kumar Gala wrote:
[..]
>> This patch implements traditional way of !QE case handling.
>> Alternative version is coming (w/o ifdefs in the board files).
>>
>> p.s. I don't know if it is 2.6.28 material...
>
> what's the state of this patch vs the alternate version?

Pros of the alternative version:
- No #ifdefs in .c files.

Cons of the alternative version:
- For this code (assuming QE=n):
        if ((np = of_find_node_by_name(NULL, "par_io")) != NULL)
		par_io_init(np);

  GCC can still issue the of_find_node_by_name() call. (I wonder if
  there is any way to tell gcc that particular function doesn't
  produce any side-effects so that gcc can optimize it away too).

It's up to you to decide which version you want to merge.

-- 
Anton Vorontsov
email: cbouatmailru@gmail.com
irc://irc.freenode.net/bd2

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

* Re: [PATCH] powerpc/83xx: Fix few build errors with CONFIG_QUICC_ENGINE=n
  2008-12-16 18:44   ` Anton Vorontsov
@ 2008-12-16 19:00     ` Scott Wood
  2008-12-16 19:14       ` Anton Vorontsov
  0 siblings, 1 reply; 12+ messages in thread
From: Scott Wood @ 2008-12-16 19:00 UTC (permalink / raw)
  To: avorontsov; +Cc: linuxppc-dev, Timur Tabi

Anton Vorontsov wrote:
>   GCC can still issue the of_find_node_by_name() call. (I wonder if
>   there is any way to tell gcc that particular function doesn't
>   produce any side-effects so that gcc can optimize it away too).

__attribute__((pure))

-Scott

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

* Re: [PATCH] powerpc/83xx: Fix few build errors with CONFIG_QUICC_ENGINE=n
  2008-12-16 19:00     ` Scott Wood
@ 2008-12-16 19:14       ` Anton Vorontsov
  2008-12-16 22:57         ` Kumar Gala
  0 siblings, 1 reply; 12+ messages in thread
From: Anton Vorontsov @ 2008-12-16 19:14 UTC (permalink / raw)
  To: Scott Wood; +Cc: linuxppc-dev, Timur Tabi

On Tue, Dec 16, 2008 at 01:00:13PM -0600, Scott Wood wrote:
> Anton Vorontsov wrote:
>>   GCC can still issue the of_find_node_by_name() call. (I wonder if
>>   there is any way to tell gcc that particular function doesn't
>>   produce any side-effects so that gcc can optimize it away too).
>
> __attribute__((pure))

Ah, thanks!

But I forgot that of_find_node_by_name() and friends aren't
actually "pure", they're getting the node. :-(

-- 
Anton Vorontsov
email: cbouatmailru@gmail.com
irc://irc.freenode.net/bd2

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

* Re: [PATCH] powerpc/83xx: Fix few build errors with CONFIG_QUICC_ENGINE=n
  2008-12-16 19:14       ` Anton Vorontsov
@ 2008-12-16 22:57         ` Kumar Gala
  0 siblings, 0 replies; 12+ messages in thread
From: Kumar Gala @ 2008-12-16 22:57 UTC (permalink / raw)
  To: avorontsov; +Cc: Scott Wood, linuxppc-dev, Timur Tabi


On Dec 16, 2008, at 1:14 PM, Anton Vorontsov wrote:

> On Tue, Dec 16, 2008 at 01:00:13PM -0600, Scott Wood wrote:
>> Anton Vorontsov wrote:
>>>  GCC can still issue the of_find_node_by_name() call. (I wonder if
>>>  there is any way to tell gcc that particular function doesn't
>>>  produce any side-effects so that gcc can optimize it away too).
>>
>> __attribute__((pure))
>
> Ah, thanks!
>
> But I forgot that of_find_node_by_name() and friends aren't
> actually "pure", they're getting the node. :-(

Looking at include/linux/compiler-gcc.h I'm guessing the proper way to  
use it is __pure & inclusion of compiler.h

- k

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

* Re: [PATCH] powerpc/83xx: Fix few build errors with CONFIG_QUICC_ENGINE=n
  2008-12-05 16:55 [PATCH] powerpc/83xx: Fix few build errors with CONFIG_QUICC_ENGINE=n Anton Vorontsov
                   ` (2 preceding siblings ...)
  2008-12-16 18:18 ` Kumar Gala
@ 2008-12-22 17:12 ` Anton Vorontsov
  2008-12-30 17:19 ` Kumar Gala
  4 siblings, 0 replies; 12+ messages in thread
From: Anton Vorontsov @ 2008-12-22 17:12 UTC (permalink / raw)
  To: Kumar Gala; +Cc: linuxppc-dev, Timur Tabi

On Fri, Dec 05, 2008 at 07:55:04PM +0300, Anton Vorontsov wrote:
> Some 83xx boards were not ready for the optional QUICC Engine support.
> 
> This patch fixes following build errors:
> 
> arch/powerpc/platforms/built-in.o: In function `flush_disable_caches':
> (.text+0xb308): undefined reference to `par_io_data_set'
> arch/powerpc/platforms/built-in.o: In function `flush_disable_caches':
> (.text+0xb334): undefined reference to `par_io_data_set'
> arch/powerpc/platforms/built-in.o: In function `flush_disable_caches':
> (.text+0xb408): undefined reference to `qe_ic_get_high_irq'
> arch/powerpc/platforms/built-in.o: In function `flush_disable_caches':
> (.text+0xb478): undefined reference to `qe_ic_get_low_irq'
> arch/powerpc/platforms/built-in.o: In function `mpc832x_spi_init':
> mpc832x_rdb.c:(.init.text+0x574c): undefined reference to `par_io_config_pin'
> mpc832x_rdb.c:(.init.text+0x5768): undefined reference to `par_io_config_pin'
> mpc832x_rdb.c:(.init.text+0x5784): undefined reference to `par_io_config_pin'
> mpc832x_rdb.c:(.init.text+0x57a0): undefined reference to `par_io_config_pin'
> mpc832x_rdb.c:(.init.text+0x57bc): undefined reference to `par_io_config_pin'
> arch/powerpc/platforms/built-in.o:mpc832x_rdb.c:(.init.text+0x57d8): more undefined references to `par_io_config_pin' follow
> arch/powerpc/platforms/built-in.o: In function `mpc836x_rdk_init_IRQ':
> mpc836x_rdk.c:(.init.text+0x5e84): undefined reference to `qe_ic_init'
> arch/powerpc/platforms/built-in.o: In function `mpc836x_rdk_setup_arch':
> mpc836x_rdk.c:(.init.text+0x5f10): undefined reference to `qe_reset'
> make: *** [.tmp_vmlinux1] Error 1
> 
> Signed-off-by: Anton Vorontsov <avorontsov@ru.mvista.com>
> ---

Kumar,

After all I think we should apply this version.

Soon I'll send cleanup patches for all QE boards to remove need
for most #ifdefs.

But so far let's be consistent and do what other boards are doing.

Thanks,

> This patch implements traditional way of !QE case handling.
> Alternative version is coming (w/o ifdefs in the board files).
> 
> p.s. I don't know if it is 2.6.28 material...
> 
>  arch/powerpc/platforms/83xx/mpc832x_rdb.c |    3 ++-
>  arch/powerpc/platforms/83xx/mpc836x_rdk.c |    6 ++++--
>  2 files changed, 6 insertions(+), 3 deletions(-)
> 
> diff --git a/arch/powerpc/platforms/83xx/mpc832x_rdb.c b/arch/powerpc/platforms/83xx/mpc832x_rdb.c
> index 0300268..7e20e91 100644
> --- a/arch/powerpc/platforms/83xx/mpc832x_rdb.c
> +++ b/arch/powerpc/platforms/83xx/mpc832x_rdb.c
> @@ -38,6 +38,7 @@
>  #define DBG(fmt...)
>  #endif
>  
> +#ifdef CONFIG_QUICC_ENGINE
>  static void mpc83xx_spi_activate_cs(u8 cs, u8 polarity)
>  {
>  	pr_debug("%s %d %d\n", __func__, cs, polarity);
> @@ -77,8 +78,8 @@ static int __init mpc832x_spi_init(void)
>  			    mpc83xx_spi_activate_cs,
>  			    mpc83xx_spi_deactivate_cs);
>  }
> -
>  machine_device_initcall(mpc832x_rdb, mpc832x_spi_init);
> +#endif /* CONFIG_QUICC_ENGINE */
>  
>  /* ************************************************************************
>   *
> diff --git a/arch/powerpc/platforms/83xx/mpc836x_rdk.c b/arch/powerpc/platforms/83xx/mpc836x_rdk.c
> index a5273bb..b0090aa 100644
> --- a/arch/powerpc/platforms/83xx/mpc836x_rdk.c
> +++ b/arch/powerpc/platforms/83xx/mpc836x_rdk.c
> @@ -51,8 +51,9 @@ static void __init mpc836x_rdk_setup_arch(void)
>  	for_each_compatible_node(np, "pci", "fsl,mpc8349-pci")
>  		mpc83xx_add_bridge(np);
>  #endif
> -
> +#ifdef CONFIG_QUICC_ENGINE
>  	qe_reset();
> +#endif
>  }
>  
>  static void __init mpc836x_rdk_init_IRQ(void)
> @@ -71,13 +72,14 @@ static void __init mpc836x_rdk_init_IRQ(void)
>  	 */
>  	ipic_set_default_priority();
>  	of_node_put(np);
> -
> +#ifdef CONFIG_QUICC_ENGINE
>  	np = of_find_compatible_node(NULL, NULL, "fsl,qe-ic");
>  	if (!np)
>  		return;
>  
>  	qe_ic_init(np, 0, qe_ic_cascade_low_ipic, qe_ic_cascade_high_ipic);
>  	of_node_put(np);
> +#endif
>  }
>  
>  /*
> -- 
> 1.5.6.5
> _______________________________________________
> Linuxppc-dev mailing list
> Linuxppc-dev@ozlabs.org
> https://ozlabs.org/mailman/listinfo/linuxppc-dev

-- 
Anton Vorontsov
email: cbouatmailru@gmail.com
irc://irc.freenode.net/bd2

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

* Re: [PATCH] powerpc/83xx: Fix few build errors with CONFIG_QUICC_ENGINE=n
  2008-12-05 16:55 [PATCH] powerpc/83xx: Fix few build errors with CONFIG_QUICC_ENGINE=n Anton Vorontsov
                   ` (3 preceding siblings ...)
  2008-12-22 17:12 ` Anton Vorontsov
@ 2008-12-30 17:19 ` Kumar Gala
  4 siblings, 0 replies; 12+ messages in thread
From: Kumar Gala @ 2008-12-30 17:19 UTC (permalink / raw)
  To: Anton Vorontsov; +Cc: linuxppc-dev, Timur Tabi


On Dec 5, 2008, at 10:55 AM, Anton Vorontsov wrote:

> Some 83xx boards were not ready for the optional QUICC Engine support.
>
> This patch fixes following build errors:
>
> arch/powerpc/platforms/built-in.o: In function `flush_disable_caches':
> (.text+0xb308): undefined reference to `par_io_data_set'
> arch/powerpc/platforms/built-in.o: In function `flush_disable_caches':
> (.text+0xb334): undefined reference to `par_io_data_set'
> arch/powerpc/platforms/built-in.o: In function `flush_disable_caches':
> (.text+0xb408): undefined reference to `qe_ic_get_high_irq'
> arch/powerpc/platforms/built-in.o: In function `flush_disable_caches':
> (.text+0xb478): undefined reference to `qe_ic_get_low_irq'
> arch/powerpc/platforms/built-in.o: In function `mpc832x_spi_init':
> mpc832x_rdb.c:(.init.text+0x574c): undefined reference to  
> `par_io_config_pin'
> mpc832x_rdb.c:(.init.text+0x5768): undefined reference to  
> `par_io_config_pin'
> mpc832x_rdb.c:(.init.text+0x5784): undefined reference to  
> `par_io_config_pin'
> mpc832x_rdb.c:(.init.text+0x57a0): undefined reference to  
> `par_io_config_pin'
> mpc832x_rdb.c:(.init.text+0x57bc): undefined reference to  
> `par_io_config_pin'
> arch/powerpc/platforms/built-in.o:mpc832x_rdb.c:(.init.text+0x57d8):  
> more undefined references to `par_io_config_pin' follow
> arch/powerpc/platforms/built-in.o: In function `mpc836x_rdk_init_IRQ':
> mpc836x_rdk.c:(.init.text+0x5e84): undefined reference to `qe_ic_init'
> arch/powerpc/platforms/built-in.o: In function  
> `mpc836x_rdk_setup_arch':
> mpc836x_rdk.c:(.init.text+0x5f10): undefined reference to `qe_reset'
> make: *** [.tmp_vmlinux1] Error 1
>
> Signed-off-by: Anton Vorontsov <avorontsov@ru.mvista.com>
> ---
>
> This patch implements traditional way of !QE case handling.
> Alternative version is coming (w/o ifdefs in the board files).
>
> p.s. I don't know if it is 2.6.28 material...
>
> arch/powerpc/platforms/83xx/mpc832x_rdb.c |    3 ++-
> arch/powerpc/platforms/83xx/mpc836x_rdk.c |    6 ++++--
> 2 files changed, 6 insertions(+), 3 deletions(-)

applied to next

- k

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

* Re: [PATCH] powerpc/qe: Fix few build errors with CONFIG_QUICC_ENGINE=n
  2008-12-05 16:59 ` [PATCH] powerpc/qe: " Anton Vorontsov
@ 2008-12-30 17:19   ` Kumar Gala
  0 siblings, 0 replies; 12+ messages in thread
From: Kumar Gala @ 2008-12-30 17:19 UTC (permalink / raw)
  To: Anton Vorontsov; +Cc: linuxppc-dev, Timur Tabi


On Dec 5, 2008, at 10:59 AM, Anton Vorontsov wrote:

> Some 83xx boards were not ready for the optional QUICC Engine support.
>
> This patch fixes following build errors:
>
> arch/powerpc/platforms/built-in.o: In function `flush_disable_caches':
> (.text+0xb308): undefined reference to `par_io_data_set'
> arch/powerpc/platforms/built-in.o: In function `flush_disable_caches':
> (.text+0xb334): undefined reference to `par_io_data_set'
> arch/powerpc/platforms/built-in.o: In function `flush_disable_caches':
> (.text+0xb408): undefined reference to `qe_ic_get_high_irq'
> arch/powerpc/platforms/built-in.o: In function `flush_disable_caches':
> (.text+0xb478): undefined reference to `qe_ic_get_low_irq'
> arch/powerpc/platforms/built-in.o: In function `mpc832x_spi_init':
> mpc832x_rdb.c:(.init.text+0x574c): undefined reference to  
> `par_io_config_pin'
> mpc832x_rdb.c:(.init.text+0x5768): undefined reference to  
> `par_io_config_pin'
> mpc832x_rdb.c:(.init.text+0x5784): undefined reference to  
> `par_io_config_pin'
> mpc832x_rdb.c:(.init.text+0x57a0): undefined reference to  
> `par_io_config_pin'
> mpc832x_rdb.c:(.init.text+0x57bc): undefined reference to  
> `par_io_config_pin'
> arch/powerpc/platforms/built-in.o:mpc832x_rdb.c:(.init.text+0x57d8):  
> more undefined references to `par_io_config_pin' follow
> arch/powerpc/platforms/built-in.o: In function `mpc836x_rdk_init_IRQ':
> mpc836x_rdk.c:(.init.text+0x5e84): undefined reference to `qe_ic_init'
> arch/powerpc/platforms/built-in.o: In function  
> `mpc836x_rdk_setup_arch':
> mpc836x_rdk.c:(.init.text+0x5f10): undefined reference to `qe_reset'
> make: *** [.tmp_vmlinux1] Error 1
>
> Signed-off-by: Anton Vorontsov <avorontsov@ru.mvista.com>
> ---
> arch/powerpc/include/asm/qe.h    |   16 ++++++++++++++--
> arch/powerpc/include/asm/qe_ic.h |   21 +++++++++++++++++----
> 2 files changed, 31 insertions(+), 6 deletions(-)


applied to next

- k

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

end of thread, other threads:[~2008-12-30 17:26 UTC | newest]

Thread overview: 12+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2008-12-05 16:55 [PATCH] powerpc/83xx: Fix few build errors with CONFIG_QUICC_ENGINE=n Anton Vorontsov
2008-12-05 16:59 ` [PATCH] powerpc/qe: " Anton Vorontsov
2008-12-30 17:19   ` Kumar Gala
2008-12-05 17:09 ` [PATCH] powerpc/83xx: " Kumar Gala
2008-12-05 17:14   ` Timur Tabi
2008-12-16 18:18 ` Kumar Gala
2008-12-16 18:44   ` Anton Vorontsov
2008-12-16 19:00     ` Scott Wood
2008-12-16 19:14       ` Anton Vorontsov
2008-12-16 22:57         ` Kumar Gala
2008-12-22 17:12 ` Anton Vorontsov
2008-12-30 17:19 ` Kumar Gala

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.