Skip to contentSkip to conversation

CFG_HZ and CFG_SCCR question

U-Boot-Users Peter Asemann 2 participants 2 messages Dec 8, 2004

lore
Share & tools
lore
#0 lore raw

1. There is a CFG_HZ configuration setting in many config files, but it's not mentioned in the README.
The source code of components where it is used suggests it has to do with timer issues.

Having thought and done some "research" on that matter I do believe now that the CFG_HZ setting must have something to do with the expiry of some timer, but probably doesn't set the tmbclk/tbclk but some counter to have some timer expire every CFG_HZ times per second. Is that right?

2. Whilst taking a look in the MPC875 documentation I found there are system registers I'd like to take influence on to make sure there are the "right" values in them. For example the SCCR. I saw that in the README SCCR is mentioned:

- CFG_SCCR: System Clock and reset Control Register (15-27)

So I suppose by defining CFG_SCCR as something I assign the value of something to the register and therefore set the registers content.

But what do the numbers (the range?) in the braces mean?

Best regards and thanks for reading,

Peter Asemann

#1 lore raw
Quoted 2 lines · In message <[email protected]> you wrote:

1. There is a CFG_HZ configuration setting in many config files, but it's not mentioned in the README.

Please consider CFG_HZ to be a constant with the value of 1000.

Quoted 4 lines

Having thought and done some "research" on that matter I do believe now that the CFG_HZ setting must have something to do with the expiry of some timer, but probably doesn't set the tmbclk/tbclk but some counter to have some timer expire every CFG_HZ times per second. Is that right?

Something like that. It's the system tick, similar to the constant "HZ" in the Linux kernel.

Quoted 1 line

- CFG_SCCR: System Clock and reset Control Register (15-27)

...

Quoted 1 line

But what do the numbers (the range?) in the braces mean?

It's a reference to page 15-27 in the MPC860 User's Manual.

Best regards,

Wolfgang Denk

Signature · 4 lines
Software Engineering:  Embedded and Realtime Systems,  Embedded Linux
Phone: (+49)-8142-66989-10 Fax: (+49)-8142-66989-80 Email: wd at denx.de
The first thing we do is kill all the lawyers.
(Shakespeare. II Henry VI, Act IV, scene ii)