* Re: [PATCH] early serial init
2002-04-11 20:00 [PATCH] early serial init John Tyner
@ 2002-04-11 14:20 ` Armin
2002-04-11 21:26 ` John Tyner
0 siblings, 1 reply; 16+ messages in thread
From: Armin @ 2002-04-11 14:20 UTC (permalink / raw)
To: John Tyner; +Cc: linuxppc-embedded
John Tyner wrote:
> Here is a patch to setup the serial ports early. It works fine on our
> walnut boards.
>
> --- arch/ppc/platforms/walnut.c.orig Thu Apr 11 12:55:55 2002
> +++ arch/ppc/platforms/walnut.c Thu Apr 11 12:58:35 2002
> @@ -31,6 +31,7 @@
> #include <linux/blk.h>
> #include <linux/pci.h>
> #include <linux/rtc.h>
> +#include <linux/serial.h>
>
> #include <asm/system.h>
> #include <asm/pci-bridge.h>
> @@ -247,6 +248,11 @@
> void __init
> board_init(void)
> {
> + struct serial_struct serial_req;
> + bd_t *bip = (bd_t *) __res;
> + u32 chrcr;
> + int div;
> + ulong bb;
> #ifdef CONFIG_PPC_RTC
> ppc_md.time_init = todc_time_init;
> ppc_md.set_rtc_time = todc_set_rtc_time;
> @@ -254,4 +260,40 @@
> ppc_md.nvram_read_val = todc_direct_read_val;
> ppc_md.nvram_write_val = todc_direct_write_val;
> #endif
> + chrcr = mfdcr(DCRN_CHCR0);
> + div = ((chrcr&0x3e)>>1)+1;
> + div *= 16;
> + bb = bip->bi_intfreq/div;
> +
> + if( !(chrcr & CHR0_U0EC) ){
> + memset(&serial_req, 0, sizeof(serial_req));
> + serial_req.line = 0;
> + serial_req.baud_base = bb;
> + serial_req.port = 0;
> + serial_req.irq = UART0_INT;
> + serial_req.flags = ASYNC_BOOT_AUTOCONF | ASYNC_SKIP_TEST;
> + serial_req.io_type = SERIAL_IO_MEM;
> + serial_req.iomem_base = (u8 *)UART0_IO_BASE;
> + serial_req.iomem_reg_shift = 0;
> +
> + if (early_serial_setup(&serial_req) != 0) {
> + printk("Early serial init of port 0 failed\n");
> + }
> + }
> +
> + if( !(chrcr & CHR0_U1EC) ){
> + memset(&serial_req, 0, sizeof(serial_req));
> + serial_req.line = 1;
> + serial_req.baud_base = bb;
> + serial_req.port = 1;
> + serial_req.irq = UART1_INT;
> + serial_req.flags = ASYNC_BOOT_AUTOCONF | ASYNC_SKIP_TEST;
> + serial_req.io_type = SERIAL_IO_MEM;
> + serial_req.iomem_base = (u8 *)UART1_IO_BASE;
> + serial_req.iomem_reg_shift = 0;
> +
> + if (early_serial_setup(&serial_req) != 0) {
> + printk("Early serial init of port 1 failed\n");
> + }
> + }
> }
>
>
>
>
>
I thought we all ready had an early boot for walnut?
armin
** Sent via the linuxppc-embedded mail list. See http://lists.linuxppc.org/
^ permalink raw reply [flat|nested] 16+ messages in thread
* Re: [PATCH] early serial init
2002-04-11 21:26 ` John Tyner
@ 2002-04-11 14:53 ` Armin
2002-04-11 22:36 ` andrew may
2002-04-11 23:09 ` Tom Rini
0 siblings, 2 replies; 16+ messages in thread
From: Armin @ 2002-04-11 14:53 UTC (permalink / raw)
To: John Tyner; +Cc: linuxppc-embedded
John Tyner wrote:
> I remember seeing something awhile ago about early boots, but I didn't
> think it was for Walnut. Where is it/would it be?
>
> On Thu, 11 Apr 2002, Armin wrote:
>
>
>>John Tyner wrote:
>>
David G did something and he hit the head_4xx.S & ppc4xx_setup.c and a
few header files imb405gp.h
armin
** Sent via the linuxppc-embedded mail list. See http://lists.linuxppc.org/
^ permalink raw reply [flat|nested] 16+ messages in thread
* Re: [PATCH] early serial init
2002-04-11 22:36 ` andrew may
@ 2002-04-11 16:05 ` Armin
2002-04-11 23:18 ` andrew may
2002-04-11 22:43 ` Matthew Locke
` (2 subsequent siblings)
3 siblings, 1 reply; 16+ messages in thread
From: Armin @ 2002-04-11 16:05 UTC (permalink / raw)
To: andrew may; +Cc: John Tyner, linuxppc-embedded
andrew may wrote:
> On Thu, Apr 11, 2002 at 02:53:36PM +0000, Armin wrote:
>
>>John Tyner wrote:
>>
>>>I remember seeing something awhile ago about early boots, but I didn't
>>>think it was for Walnut. Where is it/would it be?
>>>
>>>On Thu, 11 Apr 2002, Armin wrote:
>>>
>>>
>>>
>>>>John Tyner wrote:
>>>>
>>>>
>>
>>David G did something and he hit the head_4xx.S & ppc4xx_setup.c and a
>>few header files imb405gp.h
>>
>
> This patch is to remove the need for the BASE BAUD define. If we ever start
> trying to get a single kernel to build for multiple 405 boards that run at
> various clock rates it becomes helpful to calc the base baud for the serial
> ports rather than forcing it at compile time.
>
>
This patch did not remove BASE_BAUD from the headers??? Having an option
for early boot is a good thing, this patch removes that option. Your
patch would only affect the walnut? David's is at least in setup.c
where more boards have access to the early serial init code.
armin
** Sent via the linuxppc-embedded mail list. See http://lists.linuxppc.org/
^ permalink raw reply [flat|nested] 16+ messages in thread
* [PATCH] early serial init
@ 2002-04-11 20:00 John Tyner
2002-04-11 14:20 ` Armin
0 siblings, 1 reply; 16+ messages in thread
From: John Tyner @ 2002-04-11 20:00 UTC (permalink / raw)
To: linuxppc-embedded
Here is a patch to setup the serial ports early. It works fine on our
walnut boards.
--- arch/ppc/platforms/walnut.c.orig Thu Apr 11 12:55:55 2002
+++ arch/ppc/platforms/walnut.c Thu Apr 11 12:58:35 2002
@@ -31,6 +31,7 @@
#include <linux/blk.h>
#include <linux/pci.h>
#include <linux/rtc.h>
+#include <linux/serial.h>
#include <asm/system.h>
#include <asm/pci-bridge.h>
@@ -247,6 +248,11 @@
void __init
board_init(void)
{
+ struct serial_struct serial_req;
+ bd_t *bip = (bd_t *) __res;
+ u32 chrcr;
+ int div;
+ ulong bb;
#ifdef CONFIG_PPC_RTC
ppc_md.time_init = todc_time_init;
ppc_md.set_rtc_time = todc_set_rtc_time;
@@ -254,4 +260,40 @@
ppc_md.nvram_read_val = todc_direct_read_val;
ppc_md.nvram_write_val = todc_direct_write_val;
#endif
+ chrcr = mfdcr(DCRN_CHCR0);
+ div = ((chrcr&0x3e)>>1)+1;
+ div *= 16;
+ bb = bip->bi_intfreq/div;
+
+ if( !(chrcr & CHR0_U0EC) ){
+ memset(&serial_req, 0, sizeof(serial_req));
+ serial_req.line = 0;
+ serial_req.baud_base = bb;
+ serial_req.port = 0;
+ serial_req.irq = UART0_INT;
+ serial_req.flags = ASYNC_BOOT_AUTOCONF | ASYNC_SKIP_TEST;
+ serial_req.io_type = SERIAL_IO_MEM;
+ serial_req.iomem_base = (u8 *)UART0_IO_BASE;
+ serial_req.iomem_reg_shift = 0;
+
+ if (early_serial_setup(&serial_req) != 0) {
+ printk("Early serial init of port 0 failed\n");
+ }
+ }
+
+ if( !(chrcr & CHR0_U1EC) ){
+ memset(&serial_req, 0, sizeof(serial_req));
+ serial_req.line = 1;
+ serial_req.baud_base = bb;
+ serial_req.port = 1;
+ serial_req.irq = UART1_INT;
+ serial_req.flags = ASYNC_BOOT_AUTOCONF | ASYNC_SKIP_TEST;
+ serial_req.io_type = SERIAL_IO_MEM;
+ serial_req.iomem_base = (u8 *)UART1_IO_BASE;
+ serial_req.iomem_reg_shift = 0;
+
+ if (early_serial_setup(&serial_req) != 0) {
+ printk("Early serial init of port 1 failed\n");
+ }
+ }
}
** Sent via the linuxppc-embedded mail list. See http://lists.linuxppc.org/
^ permalink raw reply [flat|nested] 16+ messages in thread
* Re: [PATCH] early serial init
2002-04-11 14:20 ` Armin
@ 2002-04-11 21:26 ` John Tyner
2002-04-11 14:53 ` Armin
0 siblings, 1 reply; 16+ messages in thread
From: John Tyner @ 2002-04-11 21:26 UTC (permalink / raw)
To: Armin; +Cc: linuxppc-embedded
I remember seeing something awhile ago about early boots, but I didn't
think it was for Walnut. Where is it/would it be?
On Thu, 11 Apr 2002, Armin wrote:
> John Tyner wrote:
> > Here is a patch to setup the serial ports early. It works fine on our
> > walnut boards.
> >
> > --- arch/ppc/platforms/walnut.c.orig Thu Apr 11 12:55:55 2002
> > +++ arch/ppc/platforms/walnut.c Thu Apr 11 12:58:35 2002
> > @@ -31,6 +31,7 @@
> > #include <linux/blk.h>
> > #include <linux/pci.h>
> > #include <linux/rtc.h>
> > +#include <linux/serial.h>
> >
> > #include <asm/system.h>
> > #include <asm/pci-bridge.h>
> > @@ -247,6 +248,11 @@
> > void __init
> > board_init(void)
> > {
> > + struct serial_struct serial_req;
> > + bd_t *bip = (bd_t *) __res;
> > + u32 chrcr;
> > + int div;
> > + ulong bb;
> > #ifdef CONFIG_PPC_RTC
> > ppc_md.time_init = todc_time_init;
> > ppc_md.set_rtc_time = todc_set_rtc_time;
> > @@ -254,4 +260,40 @@
> > ppc_md.nvram_read_val = todc_direct_read_val;
> > ppc_md.nvram_write_val = todc_direct_write_val;
> > #endif
> > + chrcr = mfdcr(DCRN_CHCR0);
> > + div = ((chrcr&0x3e)>>1)+1;
> > + div *= 16;
> > + bb = bip->bi_intfreq/div;
> > +
> > + if( !(chrcr & CHR0_U0EC) ){
> > + memset(&serial_req, 0, sizeof(serial_req));
> > + serial_req.line = 0;
> > + serial_req.baud_base = bb;
> > + serial_req.port = 0;
> > + serial_req.irq = UART0_INT;
> > + serial_req.flags = ASYNC_BOOT_AUTOCONF | ASYNC_SKIP_TEST;
> > + serial_req.io_type = SERIAL_IO_MEM;
> > + serial_req.iomem_base = (u8 *)UART0_IO_BASE;
> > + serial_req.iomem_reg_shift = 0;
> > +
> > + if (early_serial_setup(&serial_req) != 0) {
> > + printk("Early serial init of port 0 failed\n");
> > + }
> > + }
> > +
> > + if( !(chrcr & CHR0_U1EC) ){
> > + memset(&serial_req, 0, sizeof(serial_req));
> > + serial_req.line = 1;
> > + serial_req.baud_base = bb;
> > + serial_req.port = 1;
> > + serial_req.irq = UART1_INT;
> > + serial_req.flags = ASYNC_BOOT_AUTOCONF | ASYNC_SKIP_TEST;
> > + serial_req.io_type = SERIAL_IO_MEM;
> > + serial_req.iomem_base = (u8 *)UART1_IO_BASE;
> > + serial_req.iomem_reg_shift = 0;
> > +
> > + if (early_serial_setup(&serial_req) != 0) {
> > + printk("Early serial init of port 1 failed\n");
> > + }
> > + }
> > }
> >
> >
> >
> >
> >
>
> I thought we all ready had an early boot for walnut?
>
> armin
>
** Sent via the linuxppc-embedded mail list. See http://lists.linuxppc.org/
^ permalink raw reply [flat|nested] 16+ messages in thread
* Re: [PATCH] early serial init
2002-04-11 14:53 ` Armin
@ 2002-04-11 22:36 ` andrew may
2002-04-11 16:05 ` Armin
` (3 more replies)
2002-04-11 23:09 ` Tom Rini
1 sibling, 4 replies; 16+ messages in thread
From: andrew may @ 2002-04-11 22:36 UTC (permalink / raw)
To: Armin; +Cc: John Tyner, linuxppc-embedded
On Thu, Apr 11, 2002 at 02:53:36PM +0000, Armin wrote:
>
> John Tyner wrote:
> > I remember seeing something awhile ago about early boots, but I didn't
> > think it was for Walnut. Where is it/would it be?
> >
> > On Thu, 11 Apr 2002, Armin wrote:
> >
> >
> >>John Tyner wrote:
> >>
>
>
> David G did something and he hit the head_4xx.S & ppc4xx_setup.c and a
> few header files imb405gp.h
This patch is to remove the need for the BASE BAUD define. If we ever start
trying to get a single kernel to build for multiple 405 boards that run at
various clock rates it becomes helpful to calc the base baud for the serial
ports rather than forcing it at compile time.
** Sent via the linuxppc-embedded mail list. See http://lists.linuxppc.org/
^ permalink raw reply [flat|nested] 16+ messages in thread
* Re: [PATCH] early serial init
2002-04-11 22:36 ` andrew may
2002-04-11 16:05 ` Armin
@ 2002-04-11 22:43 ` Matthew Locke
2002-04-11 22:52 ` John Tyner
2002-04-11 22:54 ` Matthew Locke
2002-04-11 23:10 ` Tom Rini
3 siblings, 1 reply; 16+ messages in thread
From: Matthew Locke @ 2002-04-11 22:43 UTC (permalink / raw)
To: andrew may; +Cc: Armin, John Tyner, linuxppc-embedded
andrew may wrote:
>On Thu, Apr 11, 2002 at 02:53:36PM +0000, Armin wrote:
>
>>John Tyner wrote:
>>
>>>I remember seeing something awhile ago about early boots, but I didn't
>>>think it was for Walnut. Where is it/would it be?
>>>
>>>On Thu, 11 Apr 2002, Armin wrote:
>>>
>>>
>>>>John Tyner wrote:
>>>>
>>
>>David G did something and he hit the head_4xx.S & ppc4xx_setup.c and a
>>few header files imb405gp.h
>>
>
>This patch is to remove the need for the BASE BAUD define. If we ever start
>trying to get a single kernel to build for multiple 405 boards that run at
>various clock rates it becomes helpful to calc the base baud for the serial
>ports rather than forcing it at compile time.
>
This does not fit the current design goals of the 4xx port, so I hope
there are better reasons for this patch.
>
>
>
** Sent via the linuxppc-embedded mail list. See http://lists.linuxppc.org/
^ permalink raw reply [flat|nested] 16+ messages in thread
* Re: [PATCH] early serial init
2002-04-11 22:43 ` Matthew Locke
@ 2002-04-11 22:52 ` John Tyner
0 siblings, 0 replies; 16+ messages in thread
From: John Tyner @ 2002-04-11 22:52 UTC (permalink / raw)
To: Matthew Locke; +Cc: andrew may, Armin, linuxppc-embedded
> This does not fit the current design goals of the 4xx port
Why not? I can't possibly understand why not having to know the BASE_BAUD
ahead of time isn't a good thing.
** Sent via the linuxppc-embedded mail list. See http://lists.linuxppc.org/
^ permalink raw reply [flat|nested] 16+ messages in thread
* Re: [PATCH] early serial init
2002-04-11 22:36 ` andrew may
2002-04-11 16:05 ` Armin
2002-04-11 22:43 ` Matthew Locke
@ 2002-04-11 22:54 ` Matthew Locke
2002-04-11 23:10 ` Tom Rini
3 siblings, 0 replies; 16+ messages in thread
From: Matthew Locke @ 2002-04-11 22:54 UTC (permalink / raw)
To: andrew may; +Cc: Armin, John Tyner, linuxppc-embedded
andrew may wrote:
>On Thu, Apr 11, 2002 at 02:53:36PM +0000, Armin wrote:
>
>>John Tyner wrote:
>>
>>>I remember seeing something awhile ago about early boots, but I didn't
>>>think it was for Walnut. Where is it/would it be?
>>>
>>>On Thu, 11 Apr 2002, Armin wrote:
>>>
>>>
>>>>John Tyner wrote:
>>>>
>>
>>David G did something and he hit the head_4xx.S & ppc4xx_setup.c and a
>>few header files imb405gp.h
>>
>
>This patch is to remove the need for the BASE BAUD define. If we ever
start
>trying to get a single kernel to build for multiple 405 boards that run at
>various clock rates it becomes helpful to calc the base baud for the
serial
>ports rather than forcing it at compile time.
>
ok, let me clean this sentence up a bit...
A single kernel for multiple 405 boards does not fit the current design
goals of the 4xx port, so I hope
there are better reasons for this patch.
>
>
>
** Sent via the linuxppc-embedded mail list. See http://lists.linuxppc.org/
^ permalink raw reply [flat|nested] 16+ messages in thread
* Re: [PATCH] early serial init
2002-04-11 14:53 ` Armin
2002-04-11 22:36 ` andrew may
@ 2002-04-11 23:09 ` Tom Rini
2002-04-12 1:29 ` David Gibson
1 sibling, 1 reply; 16+ messages in thread
From: Tom Rini @ 2002-04-11 23:09 UTC (permalink / raw)
To: Armin; +Cc: John Tyner, linuxppc-embedded
On Thu, Apr 11, 2002 at 02:53:36PM +0000, Armin wrote:
>
> John Tyner wrote:
> >I remember seeing something awhile ago about early boots, but I didn't
> >think it was for Walnut. Where is it/would it be?
> >
>
> David G did something and he hit the head_4xx.S & ppc4xx_setup.c and a
> few header files imb405gp.h
Ah, here's some of the confusion. David G did the work for
CONFIG_SERIAL_TEXT_DEBUG or so. What this does is setup
drivers/char/serial.c dynamically instead of statically.
--
Tom Rini (TR1265)
http://gate.crashing.org/~trini/
** Sent via the linuxppc-embedded mail list. See http://lists.linuxppc.org/
^ permalink raw reply [flat|nested] 16+ messages in thread
* Re: [PATCH] early serial init
2002-04-11 22:36 ` andrew may
` (2 preceding siblings ...)
2002-04-11 22:54 ` Matthew Locke
@ 2002-04-11 23:10 ` Tom Rini
2002-04-11 23:28 ` andrew may
3 siblings, 1 reply; 16+ messages in thread
From: Tom Rini @ 2002-04-11 23:10 UTC (permalink / raw)
To: andrew may; +Cc: Armin, John Tyner, linuxppc-embedded
On Thu, Apr 11, 2002 at 03:36:42PM -0700, andrew may wrote:
> This patch is to remove the need for the BASE BAUD define.
Only if you get this information from somewhere else, yes? This isn't
currently something we grab from OpenBIOS, or could, right?
> If we ever start
> trying to get a single kernel to build for multiple 405 boards that run at
> various clock rates it becomes helpful to calc the base baud for the serial
> ports rather than forcing it at compile time.
If we ever start trying to get a single kernel to build for multiple 405
boards something has gone wrong. :)
More seriously, if someone wants to try and do that there's lots of
other things which would need to be changed first.
--
Tom Rini (TR1265)
http://gate.crashing.org/~trini/
** Sent via the linuxppc-embedded mail list. See http://lists.linuxppc.org/
^ permalink raw reply [flat|nested] 16+ messages in thread
* Re: [PATCH] early serial init
2002-04-11 16:05 ` Armin
@ 2002-04-11 23:18 ` andrew may
0 siblings, 0 replies; 16+ messages in thread
From: andrew may @ 2002-04-11 23:18 UTC (permalink / raw)
To: Armin; +Cc: andrew may, John Tyner, linuxppc-embedded
On Thu, Apr 11, 2002 at 04:05:38PM +0000, Armin wrote:
> This patch did not remove BASE_BAUD from the headers??? Having an option
> for early boot is a good thing, this patch removes that option. Your
> patch would only affect the walnut? David's is at least in setup.c
> where more boards have access to the early serial init code.
This patch was more a proof of concept. I need it on our devel board that
may run at different speeds. It becomes hard to find a good overall base baud
rate that will work for multiple clock speeds, that doesn't cause rounding
errors that throw off the final baud rate.
Since BASE_BAUD is defined in the platform section I though to put the code
in the same area. I did not look around for the best place to put it so setup.c
may be a better spot.
If a external serial clock is used the BaseBaud still needs to be correct.
So that is one reason not to remove the define completely, but for anything
that uses the internal clock BaseBaud could be set to 0.
** Sent via the linuxppc-embedded mail list. See http://lists.linuxppc.org/
^ permalink raw reply [flat|nested] 16+ messages in thread
* Re: [PATCH] early serial init
2002-04-11 23:10 ` Tom Rini
@ 2002-04-11 23:28 ` andrew may
2002-04-12 0:03 ` Tom Rini
0 siblings, 1 reply; 16+ messages in thread
From: andrew may @ 2002-04-11 23:28 UTC (permalink / raw)
To: Tom Rini; +Cc: andrew may, Armin, John Tyner, linuxppc-embedded
On Thu, Apr 11, 2002 at 04:10:56PM -0700, Tom Rini wrote:
> On Thu, Apr 11, 2002 at 03:36:42PM -0700, andrew may wrote:
>
> > This patch is to remove the need for the BASE BAUD define.
>
> Only if you get this information from somewhere else, yes? This isn't
> currently something we grab from OpenBIOS, or could, right?
If you look at the patch you see the only thing we need to know is the clock
rate of the CPU. Then you can to a mfdcr() to calc the base baud. If there
is an external clock then we need the basebaud from somewhere else.
We dumped OpenBIOS and put on PPCBoot, but I think OpenBIOS provides the
clock speed.
> > If we ever start
> > trying to get a single kernel to build for multiple 405 boards that run at
> > various clock rates it becomes helpful to calc the base baud for the serial
> > ports rather than forcing it at compile time.
>
> If we ever start trying to get a single kernel to build for multiple 405
> boards something has gone wrong. :)
>
> More seriously, if someone wants to try and do that there's lots of
> other things which would need to be changed first.
Yes there is a lot of work to do, but I would like to see it happen.
Right now we have to do seperate builds for our custum board and one for
our Walnut boards and that is a pain.
I though it would be good to start small and see how things go, before another
fork got started :).
** Sent via the linuxppc-embedded mail list. See http://lists.linuxppc.org/
^ permalink raw reply [flat|nested] 16+ messages in thread
* Re: [PATCH] early serial init
2002-04-11 23:28 ` andrew may
@ 2002-04-12 0:03 ` Tom Rini
2002-04-12 0:41 ` andrew may
0 siblings, 1 reply; 16+ messages in thread
From: Tom Rini @ 2002-04-12 0:03 UTC (permalink / raw)
To: andrew may; +Cc: Armin, John Tyner, linuxppc-embedded
On Thu, Apr 11, 2002 at 04:28:49PM -0700, andrew may wrote:
> On Thu, Apr 11, 2002 at 04:10:56PM -0700, Tom Rini wrote:
> > On Thu, Apr 11, 2002 at 03:36:42PM -0700, andrew may wrote:
> >
> > > This patch is to remove the need for the BASE BAUD define.
> >
> > Only if you get this information from somewhere else, yes? This isn't
> > currently something we grab from OpenBIOS, or could, right?
>
> If you look at the patch you see the only thing we need to know is the clock
> rate of the CPU. Then you can to a mfdcr() to calc the base baud. If there
> is an external clock then we need the basebaud from somewhere else.
Ah, right..
[snip]
> > More seriously, if someone wants to try and do that there's lots of
> > other things which would need to be changed first.
>
> Yes there is a lot of work to do, but I would like to see it happen.
> Right now we have to do seperate builds for our custum board and one for
> our Walnut boards and that is a pain.
I assume once the custom HW is 'ready', you'll be able to stop doing
that tho. I think you'll spend more time trying to get everything just
right than you would building 2 kernels a few times (I bet much of the
pain comes from the current kbuild crap. You might wanna play w/ the
current kbuild-2.5 stuff if you're going to pick a kernel rev & stay for
a while, it gets the deps right so you only recompile the needed files
in cases like this).
--
Tom Rini (TR1265)
http://gate.crashing.org/~trini/
** Sent via the linuxppc-embedded mail list. See http://lists.linuxppc.org/
^ permalink raw reply [flat|nested] 16+ messages in thread
* Re: [PATCH] early serial init
2002-04-12 0:03 ` Tom Rini
@ 2002-04-12 0:41 ` andrew may
0 siblings, 0 replies; 16+ messages in thread
From: andrew may @ 2002-04-12 0:41 UTC (permalink / raw)
To: Tom Rini; +Cc: andrew may, Armin, John Tyner, linuxppc-embedded
On Thu, Apr 11, 2002 at 05:03:41PM -0700, Tom Rini wrote:
> I assume once the custom HW is 'ready', you'll be able to stop doing
> that tho. I think you'll spend more time trying to get everything just
> right than you would building 2 kernels a few times (I bet much of the
> pain comes from the current kbuild crap. You might wanna play w/ the
> current kbuild-2.5 stuff if you're going to pick a kernel rev & stay for
> a while, it gets the deps right so you only recompile the needed files
> in cases like this).
We already have a few boards running but right now we have to fight over
them. With the Walnuts we can build and test kernel changes without
holding up other people using the boards.
So far doing 2 builds has been ok, but it shouldn't be too much work to
get things working for both. I am not looking at the code now, but for
a 405 you just need to do a board header and a C file. The amount of
work these things do is small, but they all define the same functions.
That doesn't lend itself to working for more than one board. It should
be easy enough to put those functions in a structure do things dynamicaly.
** Sent via the linuxppc-embedded mail list. See http://lists.linuxppc.org/
^ permalink raw reply [flat|nested] 16+ messages in thread
* Re: [PATCH] early serial init
2002-04-11 23:09 ` Tom Rini
@ 2002-04-12 1:29 ` David Gibson
0 siblings, 0 replies; 16+ messages in thread
From: David Gibson @ 2002-04-12 1:29 UTC (permalink / raw)
To: Tom Rini; +Cc: Armin, John Tyner, linuxppc-embedded
On Thu, Apr 11, 2002 at 04:09:10PM -0700, Tom Rini wrote:
>
> On Thu, Apr 11, 2002 at 02:53:36PM +0000, Armin wrote:
> >
> > John Tyner wrote:
> > >I remember seeing something awhile ago about early boots, but I didn't
> > >think it was for Walnut. Where is it/would it be?
> > >
> >
> > David G did something and he hit the head_4xx.S & ppc4xx_setup.c and a
> > few header files imb405gp.h
>
> Ah, here's some of the confusion. David G did the work for
> CONFIG_SERIAL_TEXT_DEBUG or so. What this does is setup
> drivers/char/serial.c dynamically instead of statically.
Indeed, my serial debug patches are unrelated to this
early_serial_init() patch.
Mind you I think setting up the serial subsystem dynamically rather
than statically has the potential to make things a good deal neater
than the current maze of twisty little include files.
However there is a problem at the moment, because early_serial_init()
won't work if serial.o is compiled as a module.
--
David Gibson | For every complex problem there is a
david@gibson.dropbear.id.au | solution which is simple, neat and
| wrong. -- H.L. Mencken
http://www.ozlabs.org/people/dgibson
** Sent via the linuxppc-embedded mail list. See http://lists.linuxppc.org/
^ permalink raw reply [flat|nested] 16+ messages in thread
end of thread, other threads:[~2002-04-12 1:29 UTC | newest]
Thread overview: 16+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2002-04-11 20:00 [PATCH] early serial init John Tyner
2002-04-11 14:20 ` Armin
2002-04-11 21:26 ` John Tyner
2002-04-11 14:53 ` Armin
2002-04-11 22:36 ` andrew may
2002-04-11 16:05 ` Armin
2002-04-11 23:18 ` andrew may
2002-04-11 22:43 ` Matthew Locke
2002-04-11 22:52 ` John Tyner
2002-04-11 22:54 ` Matthew Locke
2002-04-11 23:10 ` Tom Rini
2002-04-11 23:28 ` andrew may
2002-04-12 0:03 ` Tom Rini
2002-04-12 0:41 ` andrew may
2002-04-11 23:09 ` Tom Rini
2002-04-12 1:29 ` David Gibson
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).