[U-Boot-Users] Clock settings - just can't figure it out.
p
pmeloy at shaw.ca
Sun May 4 17:38:29 CEST 2008
Sorry to be a pest but I just can't figure out how to set the CPU
properly in u-boot for my s3c2410. I think I have the first part correct
for 266mHz but I get usb and other problems when booting the kernel. If
I use the s3c24xx speed set 266 (openmoko patch) then things work
flawlessly.
This is what I'm trying for
FCLK = 266 MHz, HCLK = 133 MHz, PCLK = 66 MHz, UCLK = 48 MHz
The relvent sections of cmd_s3cxx.c from the openmoko patch show
#define CLKDIVN_1_2_4 0x03
static const u_int32_t upllcon = ((0x78 << 12) + (0x2 << 4) + 0x3);
static const struct s3c24x0_pll_speed pll_configs[] = {
... (omitted other speeds)
{
.mhz = 266,
.mpllcon = ((0x7d << 12) + (0x1 << 4) + 0x1),
.clkdivn = CLKDIVN_1_2_4,
},
};
Here's what I have in the u-Boot board config so far
#define M_MDIV 0x7d
#define M_PDIV 0x1
#define M_SDIV 0x1
#define U_M_MDIV 0x78
#define U_M_PDIV 0x2
#define U_M_SDIV 0x3
I know I stumbled across a clock calculator for the s3c2410 somewhere on
the net but of course now I can't find it anywhere.
Thanks for any help you can render. This is the last thing I need to be
able to complete my u-boot setup.
More information about the U-Boot
mailing list