linuxppc-dev.lists.ozlabs.org archive mirror
 help / color / mirror / Atom feed
From: "旭 罗" <luoxu_gun@yahoo.com.cn>
To: Li Yang <LeoLi@freescale.com>,
	Linu PPC Mail list <linuxppc-dev@ozlabs.org>
Subject: 回复: RE: A question about the 8250/16550 Driver
Date: Fri, 18 Apr 2008 00:44:43 +0800 (CST)	[thread overview]
Message-ID: <58063.72220.qm@web15915.mail.cnb.yahoo.com> (raw)
In-Reply-To: <989B956029373F45A0B8AF02970818900200759C@zch01exm26.fsl.freescale.net>

[-- Attachment #1: Type: text/plain, Size: 2177 bytes --]

Hello Leo:
    Follow your advises, i look the source code and find that you are right. In the source code, There are 2 functions can do some work for the serial port initralization. The code is followed.
1. static int __devinit serial8250_probe(struct platform_device *dev)
2. static void __init serial8250_isa_init_ports(void)

In my system i use the function 2 and this function should use the structer old_serial_port. 
In fact the function 1 can initralize the serial port too. But i don't known how to call this function. 

For the more, i have find some source code in of_serial.c which is in the \drivers\serial directory. In this file, the function 
static int __devinit of_platform_serial_probe(struct of_device *ofdev,
                        const struct of_device_id *id)
call the serial8250_register_port function to initralized the serial port.

This issues makes me puzzlled, Could you help me to analyzed it? and what kind of the function i should used to initralize my serial port.



thanks 
best wishs

Li Yang <LeoLi@freescale.com> 写道: > -----Original Message-----
> From: linuxppc-dev-bounces+leoli=freescale.com@ozlabs.org 
> [mailto:linuxppc-dev-bounces+leoli=freescale.com@ozlabs.org] 
> On Behalf Of 旭 罗
> Sent: Thursday, April 17, 2008 3:32 PM
> To: Linu PPC Mail list
> Cc: Wood Scott
> Subject: A question about the 8250/16550 Driver
> 
> Hello:
>     I have founded that the serial can't be initialized as 
> the bootting process. My platform is MPC8313 and my kernel 
> version is linux-2.6.23.9. I look though the source code and 
> find that the MPC8313 driver is compatible with 8250/16550. 
> The driver is in the \drivers\serial\8250.c
> 
> In the function serial8250_isa_init_ports we should use the 
> structer old_serial_port  but i can't find the definition for 
> this struct. I can only find the following senrense in the 
> head of this file 

If you look into the function carefully enough, you can find that old_serial_port is optional and can be empty.  It seems to be some leftover to provide backward compatibility when the port structure changed.

- Leo


       
---------------------------------
 雅虎邮箱,您的终生邮箱!

[-- Attachment #2: Type: text/html, Size: 2650 bytes --]

      reply	other threads:[~2008-04-17 16:51 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2008-04-17  7:31 A question about the 8250/16550 Driver 旭 罗
2008-04-17  8:55 ` Li Yang
2008-04-17 16:44   ` 旭 罗 [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=58063.72220.qm@web15915.mail.cnb.yahoo.com \
    --to=luoxu_gun@yahoo.com.cn \
    --cc=LeoLi@freescale.com \
    --cc=linuxppc-dev@ozlabs.org \
    /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;
as well as URLs for NNTP newsgroup(s).