linuxppc-dev.lists.ozlabs.org archive mirror
 help / color / mirror / Atom feed
* [PATCH] fix celleb link failure
@ 2007-05-15 13:09 Christoph Hellwig
  2007-05-16  7:14 ` Ishizaki Kou
  0 siblings, 1 reply; 4+ messages in thread
From: Christoph Hellwig @ 2007-05-15 13:09 UTC (permalink / raw)
  To: kou.ishizaki; +Cc: linuxppc-dev, cbe-oss-dev

txx9_serial_init calls early_serial_txx9_setup which is only available
if CONFIG_SERIAL_TXX9_CONSOLE is define.  From looking at scc_sio.c
it seems like the whole file is only needed for
CONFIG_SERIAL_TXX9_CONSOLE=y, so we should only build it for that case.


Signed-off-by: Christoph Hellwig <hch@lst.de>

Index: linux-2.6.20/arch/powerpc/platforms/celleb/Makefile
===================================================================
--- linux-2.6.20.orig/arch/powerpc/platforms/celleb/Makefile	2007-05-15 14:42:15.000000000 +0200
+++ linux-2.6.20/arch/powerpc/platforms/celleb/Makefile	2007-05-15 14:42:31.000000000 +0200
@@ -4,5 +4,5 @@ obj-y				+= interrupt.o iommu.o setup.o 
 
 obj-$(CONFIG_SMP)		+= smp.o
 obj-$(CONFIG_PPC_UDBG_BEAT)	+= udbg_beat.o
-obj-$(CONFIG_HAS_TXX9_SERIAL)	+= scc_sio.o
+obj-$(CONFIG_SERIAL_TXX9_CONSOLE) += scc_sio.o
 obj-$(CONFIG_SPU_BASE)		+= spu_priv1.o
Index: linux-2.6.20/arch/powerpc/platforms/celleb/scc_sio.c
===================================================================
--- linux-2.6.20.orig/arch/powerpc/platforms/celleb/scc_sio.c	2007-05-15 14:40:49.000000000 +0200
+++ linux-2.6.20/arch/powerpc/platforms/celleb/scc_sio.c	2007-05-15 14:42:47.000000000 +0200
@@ -65,9 +65,7 @@ static int txx9_serial_init(void)
 		req.line = i;
 		req.iotype = UPIO_MEM;
 		req.mapbase = res.start + txx9_scc_tab[i].offset;
-#ifdef CONFIG_SERIAL_TXX9_CONSOLE
 		req.membase = ioremap(req.mapbase, 0x24);
-#endif
 		req.irq = irq_create_of_mapping(irq.controller,
 			irq.specifier, irq.size);
 		req.flags |= UPF_IOREMAP | UPF_BUGGY_UART /*HAVE_CTS_LINE*/;

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

* Re: [PATCH] fix celleb link failure
  2007-05-15 13:09 [PATCH] fix celleb link failure Christoph Hellwig
@ 2007-05-16  7:14 ` Ishizaki Kou
  2007-05-16 10:37   ` Christoph Hellwig
  0 siblings, 1 reply; 4+ messages in thread
From: Ishizaki Kou @ 2007-05-16  7:14 UTC (permalink / raw)
  To: hch; +Cc: linuxppc-dev, cbe-oss-dev

Christoph, 

> txx9_serial_init calls early_serial_txx9_setup which is only available
> if CONFIG_SERIAL_TXX9_CONSOLE is define.  From looking at scc_sio.c
> it seems like the whole file is only needed for
> CONFIG_SERIAL_TXX9_CONSOLE=y, so we should only build it for that
case.
> 
> 
> Signed-off-by: Christoph Hellwig <hch@lst.de>

NACK.

Thanks for pointing it out. But this fix is still wrong.
early_serial_txx9_setup is availble if CONFIG_SERIAL_TXX9=y.


> Index: linux-2.6.20/arch/powerpc/platforms/celleb/Makefile
> ===================================================================
> ---
linux-2.6.20.orig/arch/powerpc/platforms/celleb/Makefile	2007-05-
15 14:42:15.000000000 +0200
> +++
linux-2.6.20/arch/powerpc/platforms/celleb/Makefile	2007-05-15
14:42:31.000000000 +0200
> @@ -4,5 +4,5 @@ obj-y				+= interrupt.o iommu.o
setup.o 
>  
>  obj-$(CONFIG_SMP)		+= smp.o
>  obj-$(CONFIG_PPC_UDBG_BEAT)	+= udbg_beat.o
> -obj-$(CONFIG_HAS_TXX9_SERIAL)	+= scc_sio.o
> +obj-$(CONFIG_SERIAL_TXX9_CONSOLE) += scc_sio.o
>  obj-$(CONFIG_SPU_BASE)		+= spu_priv1.o

So scc_sio.o is depend on CONFIG_SERIAL_TXX9.


> Index: linux-2.6.20/arch/powerpc/platforms/celleb/scc_sio.c
> ===================================================================
> ---
linux-2.6.20.orig/arch/powerpc/platforms/celleb/scc_sio.c	2007-05-
15 14:40:49.000000000 +0200
> +++
linux-2.6.20/arch/powerpc/platforms/celleb/scc_sio.c	2007-05-15
14:42:47.000000000 +0200
> @@ -65,9 +65,7 @@ static int txx9_serial_init(void)
>  		req.line = i;
>  		req.iotype = UPIO_MEM;
>  		req.mapbase = res.start + txx9_scc_tab[i].offset;
> -#ifdef CONFIG_SERIAL_TXX9_CONSOLE
>  		req.membase = ioremap(req.mapbase, 0x24);
> -#endif
>  		req.irq = irq_create_of_mapping(irq.controller,
>  			irq.specifier, irq.size);
>  		req.flags |= UPF_IOREMAP | UPF_BUGGY_UART
/*HAVE_CTS_LINE*/;

And we need these #ifdef and #endif.

Best regards,
Kou Ishizaki

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

* Re: [PATCH] fix celleb link failure
  2007-05-16  7:14 ` Ishizaki Kou
@ 2007-05-16 10:37   ` Christoph Hellwig
  2007-05-21  7:28     ` Ishizaki Kou
  0 siblings, 1 reply; 4+ messages in thread
From: Christoph Hellwig @ 2007-05-16 10:37 UTC (permalink / raw)
  To: Ishizaki Kou; +Cc: linuxppc-dev, hch, cbe-oss-dev

On Wed, May 16, 2007 at 04:14:31PM +0900, Ishizaki Kou wrote:
> NACK.
> 
> Thanks for pointing it out. But this fix is still wrong.
> early_serial_txx9_setup is availble if CONFIG_SERIAL_TXX9=y.

You're right.  I've updated the patch to only build scc_sio.o
only if CONFIG_SERIAL_TXX9 is set.  This works because
CONFIG_SERIAL_TXX9 can't be modular currently.

> > -#ifdef CONFIG_SERIAL_TXX9_CONSOLE
> >  		req.membase = ioremap(req.mapbase, 0x24);
> > -#endif
> >  		req.irq = irq_create_of_mapping(irq.controller,
> >  			irq.specifier, irq.size);
> >  		req.flags |= UPF_IOREMAP | UPF_BUGGY_UART
> /*HAVE_CTS_LINE*/;
> 
> And we need these #ifdef and #endif.

Ok, dropped.



Index: linux-2.6.20/arch/powerpc/platforms/celleb/Makefile
===================================================================
--- linux-2.6.20.orig/arch/powerpc/platforms/celleb/Makefile	2007-05-16 11:36:28.000000000 +0200
+++ linux-2.6.20/arch/powerpc/platforms/celleb/Makefile	2007-05-16 11:36:41.000000000 +0200
@@ -4,5 +4,5 @@ obj-y				+= interrupt.o iommu.o setup.o 
 
 obj-$(CONFIG_SMP)		+= smp.o
 obj-$(CONFIG_PPC_UDBG_BEAT)	+= udbg_beat.o
-obj-$(CONFIG_HAS_TXX9_SERIAL)	+= scc_sio.o
+obj-$(CONFIG_SERIAL_TXX9)	+= scc_sio.o
 obj-$(CONFIG_SPU_BASE)		+= spu_priv1.o

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

* Re: [PATCH] fix celleb link failure
  2007-05-16 10:37   ` Christoph Hellwig
@ 2007-05-21  7:28     ` Ishizaki Kou
  0 siblings, 0 replies; 4+ messages in thread
From: Ishizaki Kou @ 2007-05-21  7:28 UTC (permalink / raw)
  To: hch; +Cc: linuxppc-dev, cbe-oss-dev

> Index: linux-2.6.20/arch/powerpc/platforms/celleb/Makefile
> ===================================================================
> ---
linux-2.6.20.orig/arch/powerpc/platforms/celleb/Makefile	2007-05-
16 11:36:28.000000000 +0200
> +++
linux-2.6.20/arch/powerpc/platforms/celleb/Makefile	2007-05-16
11:36:41.000000000 +0200
> @@ -4,5 +4,5 @@ obj-y				+= interrupt.o iommu.o
setup.o 
>  
>  obj-$(CONFIG_SMP)		+= smp.o
>  obj-$(CONFIG_PPC_UDBG_BEAT)	+= udbg_beat.o
> -obj-$(CONFIG_HAS_TXX9_SERIAL)	+= scc_sio.o
> +obj-$(CONFIG_SERIAL_TXX9)	+= scc_sio.o
>  obj-$(CONFIG_SPU_BASE)		+= spu_priv1.o

Acked-by: Kou Ishizaki <kou.ishizaki@toshiba.co.jp>

Thanks.

Best regards,
Kou Ishizaki

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

end of thread, other threads:[~2007-05-21  7:28 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2007-05-15 13:09 [PATCH] fix celleb link failure Christoph Hellwig
2007-05-16  7:14 ` Ishizaki Kou
2007-05-16 10:37   ` Christoph Hellwig
2007-05-21  7:28     ` Ishizaki Kou

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