2008-10-21 13:51:00     Clock adustment for BF527 in u-boot

Document created by Aaronwu Employee on Sep 18, 2013
Version 1Show Document
  • View in full screen mode

2008-10-21 13:51:00     Clock adustment for BF527 in u-boot

Brian Wenholz (UNITED STATES)

Message: 63996   

 

I need direction please. I have played with changing the clock settings in u_boot for my board. The board is based on the BF527-EZKIT. The HW engineers would like to eliminate one of the crystals by combining the Ethernet and bf527 clock oscillators with a single one. This means changing the bf527 clock input from 25MHz to 50MHz.

 

To test out the clock changes I modified the u-boot code to try and change the clock frequency. I was simply attempting to set the CLKIN/2 bit. I expected to see my external clock shift from 131.25MHz to 65.5125MHz. I did not see the shift. In inspecting the MMRs I see the bit is not actually set.

 

I think I am mis-understanding the clock management code section in the u-boot configuration. Can someone either explain, or point me to the explanation of this code section?

 

I have intentionally not mentioned what files I am looking at as I simply want the correct answer and wish to add no needless confusion.

 

Base configuration is 2008R1.5 release of u-boot and toolchain. Changing the Linux clocks will be my next effort following.

QuoteReplyEditDelete

 

 

2008-10-21 15:52:15     Re: Clock adustment for BF527 in u-boot

Mike Frysinger (UNITED STATES)

Message: 64002   

 

how are you trying to do this ?  you should just have to set CONFIG_CLKIN_HALF to 1 and not define CONFIG_PLL_CTL_VAL in your board.  how are you testing the code ?

 

the correct answer should be here:

http://docs.blackfin.uclinux.org/doku.php?id=bootloaders:u-boot:porting

 

also, make sure you have this patch:

http://blackfin.uclinux.org/git/?p=readonly-mirrors/u-boot.git;a=commitdiff;h=d3f5a384eae2963c411ca8bb3cdb8a55ab01c0e8

QuoteReplyEditDelete

 

 

2008-10-22 17:36:17     Re: Clock adustment for BF527 in u-boot

Brian Wenholz (UNITED STATES)

Message: 64070   

 

Mike,

 

I already had the CONFIG_CLKIN_HALF fix applied to initcode.c. I have set the CONFIG_CLKIN_HALF in the board config header file.

 

When doing a md.w 0xFFC00000 1 I get 0xaa00 where I expected 0xaa01.

 

Any other ideas on where to look?

 

Brian

QuoteReplyEditDelete

 

 

2008-10-22 18:05:43     Re: Clock adustment for BF527 in u-boot

Mike Frysinger (UNITED STATES)

Message: 64072   

 

how are you testing ?  did you actually flash the binary or did you just load it into external memory and do "go" ?

QuoteReplyEditDelete

 

 

2008-10-24 09:14:49     Re: Clock adustment for BF527 in u-boot

Brian Wenholz (UNITED STATES)

Message: 64163   

 

I loaded to external and 'go'. I was looking for the clock to change before obliterating a good copy of u-boot from flash.

 

Does u-boot not implement the PLL load sequence?

QuoteReplyEditDelete

 

 

2008-10-24 12:31:43     Re: Clock adustment for BF527 in u-boot

Mike Frysinger (UNITED STATES)

Message: 64172   

 

the 2008R1.5 release and older did not touch clocks when doing 'go'

QuoteReplyEditDelete

 

 

2008-10-24 15:19:18     Re: Clock adustment for BF527 in u-boot

Brian Wenholz (UNITED STATES)

Message: 64182   

 

Mike,

 

Thank you for the information. I took the leap-of-faith and flashed the adjusted u-boot image today.

 

Everything is working fine.

Attachments

    Outcomes