All of lore.kernel.org
 help / color / mirror / Atom feed
* [U-Boot] PPC405 with XMD boot
@ 2013-02-06  0:51 Frank Lombardo
  2013-02-06 11:13 ` Rommel G Custodio
  0 siblings, 1 reply; 6+ messages in thread
From: Frank Lombardo @ 2013-02-06  0:51 UTC (permalink / raw)
  To: u-boot

Rommel,

I am using your recently posted patch to boot my custom Virtex4 board with
XMD.  Execution gets stuck in the NS16550_init() function.  It gets stuck
at this line:

#if (!defined(CONFIG_SYS_NS16550_BROKEN_TEMT))
    while (!(serial_in(&com_port->lsr) & UART_LSR_TEMT))
        ;
#endif

If I define CONFIG_SYS_NS16550_BROKEN_TEMT, it gets stuck in the while loop
in NS16550_putc:

    while ((serial_in(&com_port->lsr) & UART_LSR_THRE) == 0)
        ;
    serial_out(c, &com_port->thr);

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

* [U-Boot] PPC405 with XMD boot
  2013-02-06  0:51 [U-Boot] PPC405 with XMD boot Frank Lombardo
@ 2013-02-06 11:13 ` Rommel G Custodio
  2013-02-06 14:08   ` Stefan Roese
  0 siblings, 1 reply; 6+ messages in thread
From: Rommel G Custodio @ 2013-02-06 11:13 UTC (permalink / raw)
  To: u-boot

Dear Frank,

On 2013.02/05, Frank Lombardo wrote:
> Rommel,
> 
> I am using your recently posted patch to boot my custom Virtex4 board with
> XMD.  Execution gets stuck in the NS16550_init() function.  It gets stuck
> at this line:

So you're not jumping to random addresses anymore.

> 
> #if (!defined(CONFIG_SYS_NS16550_BROKEN_TEMT))
>     while (!(serial_in(&com_port->lsr) & UART_LSR_TEMT))
>         ;
> #endif
> 
> If I define CONFIG_SYS_NS16550_BROKEN_TEMT, it gets stuck in the while loop
> in NS16550_putc:
> 
>     while ((serial_in(&com_port->lsr) & UART_LSR_THRE) == 0)
>         ;
>     serial_out(c, &com_port->thr);
> 
> From the GDB output, I can see it is using the correct address for the the
> serial port (0x84000000)

Hmmn. I've seen that before, I think.
Don't define CONFIG_SYS_NS16550_BROKEN_TEMT.

Make sure you use CTS/RTS (h/w flow) control with your terminal
application.

HTH.

All the best,
Rommel

> 
> (gdb) target remote localhost:1234
> Remote debugging using localhost:1234
> NS16550_putc (com_port=0x84000000, c=13 '\r') at ns16550.c:91
> 91        while ((serial_in(&com_port->lsr) & UART_LSR_THRE) == 0)
> (gdb)
> 
> 
> In your opinion, is your patch providing everything that I need to boot
> with XMD?  Can you suggest what I might be doing wrong?
> 
> Thanks for any insight you may have,
> Frank
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 487 bytes
Desc: not available
URL: <http://lists.denx.de/pipermail/u-boot/attachments/20130206/082aaf33/attachment.pgp>

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

* [U-Boot] PPC405 with XMD boot
  2013-02-06 11:13 ` Rommel G Custodio
@ 2013-02-06 14:08   ` Stefan Roese
  2013-02-07  3:20     ` Frank Lombardo
  0 siblings, 1 reply; 6+ messages in thread
From: Stefan Roese @ 2013-02-06 14:08 UTC (permalink / raw)
  To: u-boot

On 02/06/2013 12:13 PM, Rommel G Custodio wrote:
>> If I define CONFIG_SYS_NS16550_BROKEN_TEMT, it gets stuck in the while loop
>> in NS16550_putc:
>>
>>     while ((serial_in(&com_port->lsr) & UART_LSR_THRE) == 0)
>>         ;
>>     serial_out(c, &com_port->thr);
>>
>> From the GDB output, I can see it is using the correct address for the the
>> serial port (0x84000000)
> 
> Hmmn. I've seen that before, I think.
> Don't define CONFIG_SYS_NS16550_BROKEN_TEMT.

That should not be necessary.

> Make sure you use CTS/RTS (h/w flow) control with your terminal
> application.

Are you sure that all clocks, especially those related with the UART
controller, are configured correctly?

Thanks,
Stefan

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

* [U-Boot] PPC405 with XMD boot
  2013-02-06 14:08   ` Stefan Roese
@ 2013-02-07  3:20     ` Frank Lombardo
  2013-02-07  7:12       ` Stefan Roese
  0 siblings, 1 reply; 6+ messages in thread
From: Frank Lombardo @ 2013-02-07  3:20 UTC (permalink / raw)
  To: u-boot

Thanks for the responses guys.  I got to work.  What I found was that the
address being passed to the driver code was 0x84000000.  This is the base
address of the UART.  However, the registers of the XPS 16550 UART are
offset by 0x1000 from the base.  I changed the base address in my
xparameters.h file, but I wonder, should this be taken care of in a better
way?


On Wed, Feb 6, 2013 at 9:08 AM, Stefan Roese <sr@denx.de> wrote:

> On 02/06/2013 12:13 PM, Rommel G Custodio wrote:
> >> If I define CONFIG_SYS_NS16550_BROKEN_TEMT, it gets stuck in the while
> loop
> >> in NS16550_putc:
> >>
> >>     while ((serial_in(&com_port->lsr) & UART_LSR_THRE) == 0)
> >>         ;
> >>     serial_out(c, &com_port->thr);
> >>
> >> From the GDB output, I can see it is using the correct address for the
> the
> >> serial port (0x84000000)
> >
> > Hmmn. I've seen that before, I think.
> > Don't define CONFIG_SYS_NS16550_BROKEN_TEMT.
>
> That should not be necessary.
>
> > Make sure you use CTS/RTS (h/w flow) control with your terminal
> > application.
>
> Are you sure that all clocks, especially those related with the UART
> controller, are configured correctly?
>
> Thanks,
> Stefan
>
>

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

* [U-Boot] PPC405 with XMD boot
  2013-02-07  3:20     ` Frank Lombardo
@ 2013-02-07  7:12       ` Stefan Roese
  2013-02-07  9:21         ` Rommel Custodio
  0 siblings, 1 reply; 6+ messages in thread
From: Stefan Roese @ 2013-02-07  7:12 UTC (permalink / raw)
  To: u-boot

On 02/07/2013 04:20 AM, Frank Lombardo wrote:
> Thanks for the responses guys.  I got to work.  What I found was that
> the address being passed to the driver code was 0x84000000.  This is the
> base address of the UART.  However, the registers of the XPS 16550 UART
> are offset by 0x1000 from the base.  I changed the base address in my
> xparameters.h file, but I wonder, should this be taken care of in a
> better way?

I'm afraid, but I have never really worked with the Xilinx PPC4xx
FPGA's. So my knowledge here is "limited". Sorry, but I can't help more.

Thanks,Stefan

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

* [U-Boot] PPC405 with XMD boot
  2013-02-07  7:12       ` Stefan Roese
@ 2013-02-07  9:21         ` Rommel Custodio
  0 siblings, 0 replies; 6+ messages in thread
From: Rommel Custodio @ 2013-02-07  9:21 UTC (permalink / raw)
  To: u-boot

Stefan Roese <sr <at> denx.de> writes:

> 
> On 02/07/2013 04:20 AM, Frank Lombardo wrote:
> > Thanks for the responses guys.  I got to work.  What I found was that
> > the address being passed to the driver code was 0x84000000.  This is the
> > base address of the UART.  However, the registers of the XPS 16550 UART
> > are offset by 0x1000 from the base.  I changed the base address in my
> > xparameters.h file, but I wonder, should this be taken care of in a
> > better way?
> 
> I'm afraid, but I have never really worked with the Xilinx PPC4xx
> FPGA's. So my knowledge here is "limited". Sorry, but I can't help more.

I think include/configs/microblaze-generic.h includes code for this.

The ML-series all now use UARTlite in the configs. Though maybe it won't
hurt to add code similar to the MB in the ML-series headers as a fallback.

All the best,
Rommel

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

end of thread, other threads:[~2013-02-07  9:21 UTC | newest]

Thread overview: 6+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2013-02-06  0:51 [U-Boot] PPC405 with XMD boot Frank Lombardo
2013-02-06 11:13 ` Rommel G Custodio
2013-02-06 14:08   ` Stefan Roese
2013-02-07  3:20     ` Frank Lombardo
2013-02-07  7:12       ` Stefan Roese
2013-02-07  9:21         ` Rommel Custodio

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.