public inbox for u-boot@lists.denx.de
 help / color / mirror / Atom feed
From: Joey Oravec <joravec@drewtech.com>
To: u-boot@lists.denx.de
Subject: [U-Boot-Users] Implementation of serial console redirection in uboot
Date: Tue, 17 Jul 2007 08:54:34 -0400	[thread overview]
Message-ID: <f7ie6d$od2$1@sea.gmane.org> (raw)
In-Reply-To: 22587334.1242731184650886880.JavaMail.nabble@isper.nabble.com

<yasothabalanr@gmail.com> wrote in message 
news:22587334.1242731184650886880.JavaMail.nabble at isper.nabble.com...
>I am using Uboot as my boot loader.
>
> Actually here I want to do console redirection through USB port.
>
> So that I have to modify console redirection via serial code to console 
> redirection via of USB
>
> To do that first I want to know how serial console redirection is done in 
> the UBOOT code. i.e., how in uboot the "serial console redirection" is 
> implemented.
>
> For console redirection(serial) there should be some code, somewhere in 
> the UBoot. I want to know how and where(in file,in which function) the 
> console redirection is implemented. [I have found how the configuration is 
> done for console redirection]

You have posted the same question several times. I have already responded to 
you. In case you deleted the email, see 
http://article.gmane.org/gmane.comp.boot-loaders.u-boot/30132

File common/console.c and common/devices.c contain everything. When you 
device_register(), you're inserting a new item into the devlist. When you 
set the stdin, stdout, or stderr you're calling console_setfile() which 
assigns a function pointer for each I/O function. When u-boot wants to read 
or display a character it follows the function pointer stored in global 
data.

Please read my previous posting. Use lcd.c as an example. Write 4 new 
functions that implement getc, tstc, putc, and puts. Register these as I/O 
using device_register() and choose them by setting stdin, stdout, and 
stderr.

-joey 

      reply	other threads:[~2007-07-17 12:54 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2007-07-17  5:41 [U-Boot-Users] Implementation of serial console redirection in uboot yasothabalanr at gmail.com
2007-07-17 12:54 ` Joey Oravec [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to='f7ie6d$od2$1@sea.gmane.org' \
    --to=joravec@drewtech.com \
    --cc=u-boot@lists.denx.de \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox