[U-Boot] suggest on how to convey value of 'CCSRBAR' to user on FSL PPC parts
Wolfgang Denk
wd at denx.de
Tue Aug 4 16:24:39 CEST 2009
Dear Kumar Gala,
In message <7ACC3970-1B73-4828-941C-48C6601A7F80 at kernel.crashing.org> you wrote:
> I had two ideas on simple ways to convey the value of CCSRBAR, IMMR,
> etc.. on various Freescale PPC SoCs. Knowing the value is useful in
> debugging if you need to dump the register space. I wanted to see if
> people had a preference or other ideas:
>
> 1. add it as output when we boot:
This would be only acceptable when DEBUG is enabled, and even this
it's ugly.
> 2. add it as a environment variable
>
> ccsrbar=fe000000
Please don't.
> I also thought about having it as a command but that seems like a lot
> of code w/o any real purpose.
I don't understand what exactly you need it for.
The information should be part of struct bd_info for all relevant
architectures, and struct global_data holds a pointer to bd_info as
the first element, and on PowerPC R2 holds a pointer to the global
data.
So you can easily define a GDB macro to do something like this:
(gdb) print/x ((gd_t *)$r2)->bd->bi_immr_base
Best regards,
Wolfgang Denk
--
DENX Software Engineering GmbH, MD: Wolfgang Denk & Detlev Zundel
HRB 165235 Munich, Office: Kirchenstr.5, D-82194 Groebenzell, Germany
Phone: (+49)-8142-66989-10 Fax: (+49)-8142-66989-80 Email: wd at denx.de
"If you'll excuse me a minute, I'm going to have a cup of coffee."
- broadcast from Apollo 11's LEM, "Eagle", to Johnson Space Center,
Houston July 20, 1969, 7:27 P.M.
More information about the U-Boot
mailing list