TX49x7: fix reporting of the CPU name and PCI clock
PATCH 1/1 TX49x7: fix reporting of the CPU name and PCI clock
Hello.
I've noticed that PCI clock was incorrectly reported as 66 MHz while being
mere 33 MHz on RBTX4937 board -- this was due to the different encoding of the PCI divisor field in CCFG register between TX4927 and TX4937 chips...
Also, RBTX49x7 was printed out as a CPU name (e.g., "CPU is RBTX4937");
and some debug printk() were duplicating each other...
WBR, Sergei
Signed-off-by Konstantin Baydarov <[email protected]>
Signed-off-by Sergei Shtylyov <[email protected]>
arch/mips/tx4927/toshiba_rbtx4927/toshiba_rbtx4927_prom.c +5 -5
@@ -60,7 +60,6 @@ void __init prom_init_cmdline(void)void __init prom_init (void ) { -const char * toshiba_name_list[] =GROUP_TOSHIBA_NAMES ;extern int tx4927_get_mem_size (void );extern char * toshiba_name;int msize;
@@ -69,12 +68,13 @@ void __init prom_init(void) mips_machgroup =MACH_GROUP_TOSHIBA ; -if ((read_c0_prid () &0xff ) ==PRID_REV_TX4927 ) +if ((read_c0_prid () &0xff ) ==PRID_REV_TX4927 ) { mips_machtype =MACH_TOSHIBA_RBTX4927 ; -else + toshiba_name ="TX4927" ; + }else { mips_machtype =MACH_TOSHIBA_RBTX4937 ; - - toshiba_name = toshiba_name_list[mips_machtype]; + toshiba_name ="TX4937" ; + } msize =tx4927_get_mem_size ();add_memory_region (0 , msize <<20 ,BOOT_MEM_RAM );
arch/mips/tx4927/toshiba_rbtx4927/toshiba_rbtx4927_setup.c +92 -44
169 lines not on this page · raw message
include/asm-mips/tx4927/tx4927_pci.h +10 -0
@@ -253,6 +253,16 @@ struct tx4927_pcic_reg {#define TX4927_CCFG_PCIDIVMODE_5 0x00001000#define TX4927_CCFG_PCIDIVMODE_6 0x00001800 +#define TX4937_CCFG_PCIDIVMODE_MASK 0x00001c00 +#define TX4937_CCFG_PCIDIVMODE_8 0x00000000 +#define TX4937_CCFG_PCIDIVMODE_4 0x00000400 +#define TX4937_CCFG_PCIDIVMODE_9 0x00000800 +#define TX4937_CCFG_PCIDIVMODE_4_5 0x00000c00 +#define TX4937_CCFG_PCIDIVMODE_10 0x00001000 +#define TX4937_CCFG_PCIDIVMODE_5 0x00001400 +#define TX4937_CCFG_PCIDIVMODE_11 0x00001800 +#define TX4937_CCFG_PCIDIVMODE_5_5 0x00001c00 +/* PCFG : Pin Configuration */ #define TX4927_PCFG_PCICLKEN_ALL 0x003f0000#define TX4927_PCFG_PCICLKEN (ch) (0x00010000<<(ch))
Ralf Baechle
AppliedOn Sat, Feb 04, 2006 at 03:11:14PM +0300, Sergei Shtylylov wrote:
Applied.