[ECOS] diag_printf

Andy Simpkins andy.simpkins@mindsail.com
Fri Sep 27 06:04:00 GMT 2002


please be aware that (for serial ports - I can not comment on other ports as
I don't use them) the physical driver routine will be different than that
used outside of debug mode.

i.e. normal printf function will likely use an interrupt driven serial port
routine where as the diag version will probably drive the uart (or whatever)
in blocking mode (thus greatly increasing the likelihood of successfully
sending data on a system that you are just bringing up)

Andy

-----Original Message-----
From: ecos-discuss-owner@sources.redhat.com
[mailto:ecos-discuss-owner@sources.redhat.com]On Behalf Of NavEcos
Sent: 27 September 2002 13:38
To: Vinayak P Risbud; Ecos-Discuss
Subject: Re: [ECOS] diag_printf


On Friday 27 September 2002 04:43 am, Vinayak P Risbud wrote:
>         Hi,
>             I am not able trace the diag_printf function.
>             Which function of my serial driver is called,
>             when, I execute diag_printf ?
>
>             Can any one explain me the complete flow ?
>
>         Thanks in advance
>             Vinayak

You mean the trace FROM diag_printf?

I don't have the complete rundown, but by sampling my system statistically,
the function tree looks something like this:

>diag_printf
->_vprintf (void (*)(char, void **), void **, char const *)
-+>_diag_write_char (char, void **)
-+->diag_write_char
-+-->hal_if_diag_write_char
-+>diag_check_string (char const *)
-+>_cvt(unsigned long long, char *, long, char *)
--->__udivdi3

I cannot represent the tree very well in with just text, but I think you get
idea.  This is the tree for an ethernet debug port.  I'm not using the
serial
port.

Keep in mind this is from doing a SAMPLING of my system, I'm not actually
going through the code.  That tree is probably incomplete, but I think you
are looking for the hal_if_diag_write_char() function.

Hope that helps.

-Rich

--
Before posting, please read the FAQ: http://sources.redhat.com/fom/ecos
and search the list archive: http://sources.redhat.com/ml/ecos-discuss



-- 
Before posting, please read the FAQ: http://sources.redhat.com/fom/ecos
and search the list archive: http://sources.redhat.com/ml/ecos-discuss



More information about the Ecos-discuss mailing list