public inbox for u-boot@lists.denx.de
 help / color / mirror / Atom feed
From: Stefan Roese <sr@denx.de>
To: u-boot@lists.denx.de
Subject: [U-Boot-Users] [PATCH] ppc7xx: Update CPCI750 board
Date: Fri, 22 Jun 2007 17:32:28 +0200	[thread overview]
Message-ID: <200706221732.28457.sr@denx.de> (raw)
In-Reply-To: <200706221705.56930.sr@denx.de>

This small CPCI750 update extends the board specific command
"show_config" to display the Marvell strapping registers and
extends the PCI IDE controller.

Signed-off-by: Reinhard Arlt <reinhard.arlt@esd-electronics.com>
Signed-off-by: Stefan Roese <sr@denx.de>

---
commit c9cfe580f6376de734a58707448914c8f7815043
tree 2731456a3e94d72412abe3f5881943dded1dd579
parent 83b4cfa3d629dff0264366263c5e94d9a50ad80b
author Reinhard Arlt <reinhard.arlt@esd-electronics.com> Fri, 22 Jun 2007 17:28:42 +0200
committer Stefan Roese <sr@denx.de> Fri, 22 Jun 2007 17:28:42 +0200

 board/esd/cpci750/cpci750.c    |   89 ++++++++++++++++++++++++++++++++++++++--
 board/esd/cpci750/ide.c        |    2 +
 board/esd/cpci750/sdram_init.c |    2 -
 3 files changed, 88 insertions(+), 5 deletions(-)

diff --git a/board/esd/cpci750/cpci750.c b/board/esd/cpci750/cpci750.c
index 17e3568..298aa6a 100644
--- a/board/esd/cpci750/cpci750.c
+++ b/board/esd/cpci750/cpci750.c
@@ -55,6 +55,71 @@
 #define DP(x)
 #endif
 
+static char show_config_tab[][15] = {{"PCI0DLL_2     "},  /* 31 */
+				     {"PCI0DLL_1     "},  /* 30 */
+				     {"PCI0DLL_0     "},  /* 29 */
+				     {"PCI1DLL_2     "},  /* 28 */
+				     {"PCI1DLL_1     "},  /* 27 */
+				     {"PCI1DLL_0     "},  /* 26 */
+				     {"BbEP2En       "},  /* 25 */
+				     {"SDRAMRdDataDel"},  /* 24 */
+				     {"SDRAMRdDel    "},  /* 23 */
+				     {"SDRAMSync     "},  /* 22 */
+				     {"SDRAMPipeSel_1"},  /* 21 */
+				     {"SDRAMPipeSel_0"},  /* 20 */
+				     {"SDRAMAddDel   "},  /* 19 */
+				     {"SDRAMClkSel   "},  /* 18 */
+				     {"Reserved(1!)  "},  /* 17 */
+				     {"PCIRty        "},  /* 16 */
+				     {"BootCSWidth_1 "},  /* 15 */
+				     {"BootCSWidth_0 "},  /* 14 */
+				     {"PCI1PadsCal   "},  /* 13 */
+				     {"PCI0PadsCal   "},  /* 12 */
+				     {"MultiMVId_1   "},  /* 11 */
+				     {"MultiMVId_0   "},  /* 10 */
+				     {"MultiGTEn     "},  /* 09 */
+				     {"Int60xArb     "},  /* 08 */
+				     {"CPUBusConfig_1"},  /* 07 */
+				     {"CPUBusConfig_0"},  /* 06 */
+				     {"DefIntSpc     "},  /* 05 */
+				     {0               },  /* 04 */
+				     {"SROMAdd_1     "},  /* 03 */
+				     {"SROMAdd_0     "},  /* 02 */
+				     {"DRAMPadCal    "},  /* 01 */
+				     {"SInitEn       "},  /* 00 */
+				     {0               },  /* 31 */
+				     {0               },  /* 30 */
+				     {0               },  /* 29 */
+				     {0               },  /* 28 */
+				     {0               },  /* 27 */
+				     {0               },  /* 26 */
+				     {0               },  /* 25 */
+				     {0               },  /* 24 */
+				     {0               },  /* 23 */
+				     {0               },  /* 22 */
+				     {"JTAGCalBy     "},  /* 21 */
+				     {"GB2Sel        "},  /* 20 */
+				     {"GB1Sel        "},  /* 19 */
+				     {"DRAMPLL_MDiv_5"},  /* 18 */
+				     {"DRAMPLL_MDiv_4"},  /* 17 */
+				     {"DRAMPLL_MDiv_3"},  /* 16 */
+				     {"DRAMPLL_MDiv_2"},  /* 15 */
+				     {"DRAMPLL_MDiv_1"},  /* 14 */
+				     {"DRAMPLL_MDiv_0"},  /* 13 */
+				     {"GB0Sel        "},  /* 12 */
+				     {"DRAMPLLPU     "},  /* 11 */
+				     {"DRAMPLL_HIKVCO"},  /* 10 */
+				     {"DRAMPLLNP     "},  /* 09 */
+				     {"DRAMPLL_NDiv_7"},  /* 08 */
+				     {"DRAMPLL_NDiv_6"},  /* 07 */
+				     {"CPUPadCal     "},  /* 06 */
+				     {"DRAMPLL_NDiv_5"},  /* 05 */
+				     {"DRAMPLL_NDiv_4"},  /* 04 */
+				     {"DRAMPLL_NDiv_3"},  /* 03 */
+				     {"DRAMPLL_NDiv_2"},  /* 02 */
+				     {"DRAMPLL_NDiv_1"},  /* 01 */
+				     {"DRAMPLL_NDiv_0"}}; /* 00 */
+
 extern void flush_data_cache (void);
 extern void invalidate_l1_instruction_cache (void);
 extern flash_info_t flash_info[];
@@ -901,21 +966,37 @@ void board_prebootm_init ()
 	dcache_disable ();
 }
 
-
-int do_show_cfg(cmd_tbl_t * cmdtp, int flag, int argc, char *argv[])
+int do_show_config(cmd_tbl_t * cmdtp, int flag, int argc, char *argv[])
 {
 	unsigned int reset_sample_low;
 	unsigned int reset_sample_high;
+	unsigned int l, l1, l2;
 
 	GT_REG_READ(0x3c4, &reset_sample_low);
 	GT_REG_READ(0x3d4, &reset_sample_high);
 	printf("Reset configuration 0x%08x 0x%08x\n", reset_sample_low, reset_sample_high);
 
+	l2 = 0;
+	for (l=0; l<63; l++) {
+		if (show_config_tab[l][0] != 0) {
+			printf("%14s:%1x ", show_config_tab[l],
+			       ((reset_sample_low >> (31 - (l & 0x1f)))) & 0x01);
+			l2++;
+			if ((l2 % 4) == 0)
+				printf("\n");
+		} else {
+			l1++;
+		}
+		if (l == 32)
+			reset_sample_low = reset_sample_high;
+	}
+	printf("\n");
+
 	return(0);
 }
 
 U_BOOT_CMD(
-	show_cfg,	1,	1,	do_show_cfg,
-	"show_cfg- Show Marvell strapping register\n",
+	show_config,	1,	1,	do_show_config,
+	"show_config - Show Marvell strapping register\n",
 	"Show Marvell strapping register (ResetSampleLow ResetSampleHigh)\n"
 	);
diff --git a/board/esd/cpci750/ide.c b/board/esd/cpci750/ide.c
index bea99ce..2b8fe6b 100644
--- a/board/esd/cpci750/ide.c
+++ b/board/esd/cpci750/ide.c
@@ -43,6 +43,8 @@ int ide_preinit (void)
 		ide_bus_offset[l] = -ATA_STATUS;
 	}
 	devbusfn = pci_find_device (0x1103, 0x0004, 0);
+	if (devbusfn == -1)
+	        devbusfn = pci_find_device (0x1095, 0x3114, 0);
 	if (devbusfn != -1) {
 		status = 0;
 
diff --git a/board/esd/cpci750/sdram_init.c b/board/esd/cpci750/sdram_init.c
index c094755..78d1880 100644
--- a/board/esd/cpci750/sdram_init.c
+++ b/board/esd/cpci750/sdram_init.c
@@ -1252,7 +1252,7 @@ static int check_dimm (uchar slot, AUX_MEM_DIMM_INFO * dimmInfo)
 /* sets up the GT properly with information passed in */
 int setup_sdram (AUX_MEM_DIMM_INFO * info)
 {
-	ulong tmp, check;
+	ulong tmp;
 	ulong tmp_sdram_mode = 0;	/* 0x141c */
 	ulong tmp_dunit_control_low = 0;	/* 0x1404 */
 	int i;

  reply	other threads:[~2007-06-22 15:32 UTC|newest]

Thread overview: 98+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2007-04-23 12:32 [U-Boot-Users] [MPC82xx] Fixes for MPC8272 Wolfgang Denk
2007-04-23 13:16 ` [U-Boot-Users] [PPC4xx] Please pull git://www.denx.de/git/u-boot-nand-flash.git Stefan Roese
2007-04-23 13:41   ` [U-Boot-Users] Please pull git://www.denx.de/git/u-boot-testing.git Stefan Roese
2007-05-05 15:31   ` [U-Boot-Users] [PPC4xx] Please pull git://www.denx.de/git/u-boot-nand-flash.git Wolfgang Denk
2007-05-18  9:21   ` [U-Boot-Users] [PPC4xx] Please pull git://www.denx.de/git/u-boot-ppc4xx.git Stefan Roese
2007-05-24  9:12     ` Stefan Roese
2007-06-01 14:27       ` Stefan Roese
2007-06-06  9:50         ` Stefan Roese
2007-06-19 15:49           ` Stefan Roese
2007-06-20 16:15             ` Wolfgang Denk
2007-06-22  1:09             ` Kim Phillips
2007-06-22  5:41               ` Stefan Roese
2007-06-22 14:18                 ` Stefan Roese
2007-06-22 15:34                   ` Kim Phillips
2007-06-22 15:05             ` Stefan Roese
2007-06-22 15:32               ` Stefan Roese [this message]
2007-08-16  9:18                 ` [U-Boot-Users] [PATCH] ppc7xx: Update CPCI750 board Wolfgang Denk
2007-08-02  6:47             ` [U-Boot-Users] [PPC4xx] Please pull git://www.denx.de/git/u-boot-ppc4xx.git Stefan Roese
2007-08-14 14:39               ` Stefan Roese
2007-08-14 18:38                 ` Wolfgang Denk
2007-08-16  6:58                 ` [U-Boot-Users] [NAND] Please pull git://www.denx.de/git/u-boot-nand-flash.git Stefan Roese
2007-08-16  9:52                   ` Wolfgang Denk
2007-08-16 17:53                 ` [U-Boot-Users] [PPC4xx] Please pull git://www.denx.de/git/u-boot-ppc4xx.git Stefan Roese
2007-08-18 12:44                   ` [U-Boot-Users] [ColdFire] Please pull git://www.denx.de/git/u-boot-coldfire.git Stefan Roese
2007-08-18 19:57                     ` Wolfgang Denk
2007-08-18 19:37                   ` [U-Boot-Users] [PPC4xx] Please pull git://www.denx.de/git/u-boot-ppc4xx.git Wolfgang Denk
2007-08-28 13:12                   ` Stefan Roese
2007-08-28 22:54                     ` Wolfgang Denk
2007-09-02 12:05                     ` Stefan Roese
2007-09-06 22:07                       ` Wolfgang Denk
2007-09-17  6:50                       ` [U-Boot-Users] [NAND] Please pull git://www.denx.de/git/u-boot-nand-flash.git Stefan Roese
2007-10-13 19:43                         ` Wolfgang Denk
2007-09-27 11:59                       ` [U-Boot-Users] [PPC4xx] Please pull git://www.denx.de/git/u-boot-ppc4xx.git Stefan Roese
2007-10-02  9:47                         ` Stefan Roese
2007-10-02 17:57                           ` Wolfgang Denk
2007-10-15  9:57                 ` Stefan Roese
2007-10-15 10:56                   ` Wolfgang Denk
2007-10-18  5:59                   ` Stefan Roese
2007-10-18 20:03                     ` Wolfgang Denk
2007-12-17 14:56                 ` [U-Boot-Users] [cfi-flash] Please pull git://www.denx.de/git/u-boot-cfi-flash.git Stefan Roese
2007-12-26 23:09                   ` Wolfgang Denk
2007-12-31  6:36                   ` Stefan Roese
2007-12-31  7:13                     ` [U-Boot-Users] [ppc4xx] Please pull git://www.denx.de/git/u-boot-ppc4xx.git Stefan Roese
2007-12-31 13:59                       ` gvb.uboot
2008-01-02 11:41                       ` Wolfgang Denk
2008-01-04 11:08                       ` Stefan Roese
2008-01-05  9:21                         ` Stefan Roese
2008-01-08 12:42                           ` Wolfgang Denk
2008-01-09 10:01                           ` Stefan Roese
2008-01-09 10:24                             ` Wolfgang Denk
2008-01-09 18:38                             ` Larry Johnson
2008-01-09 18:59                               ` Stefan Roese
2008-01-09 19:05                               ` Jerry Van Baren
2008-02-14 10:55                             ` Stefan Roese
2008-02-14 23:23                               ` Wolfgang Denk
2008-02-16  6:11                               ` Stefan Roese
2008-02-16 22:59                                 ` Wolfgang Denk
2008-02-21 16:19                                 ` [U-Boot-Users] [cfi-flash] Please pull git://www.denx.de/git/u-boot-cfi-flash.git Stefan Roese
2008-02-22 12:02                                   ` Wolfgang Denk
2008-02-25 15:52                                 ` [U-Boot-Users] [ppc4xx] Please pull git://www.denx.de/git/u-boot-ppc4xx.git Stefan Roese
2008-03-02 20:30                                   ` Wolfgang Denk
2008-03-07  8:23                                   ` Stefan Roese
2008-03-08  9:52                                     ` Wolfgang Denk
2008-03-15  7:00                                     ` Stefan Roese
2008-03-15 23:42                                       ` Wolfgang Denk
2008-03-19 12:46                                       ` [U-Boot-Users] [cfi-flash] Please pull git://www.denx.de/git/u-boot-cfi-flash.git Stefan Roese
2008-03-22 23:53                                         ` Wolfgang Denk
2008-03-27 10:30                                       ` [U-Boot-Users] [ppc4xx] Please pull git://www.denx.de/git/u-boot-ppc4xx.git Stefan Roese
2008-03-29  5:21                                         ` [U-Boot-Users] [cfi-flash] Please pull git://www.denx.de/git/u-boot-cfi-flash.git Stefan Roese
2008-03-29  5:54                                           ` Stefan Roese
2008-04-07 21:56                                             ` Wolfgang Denk
2008-03-31 10:28                                         ` [U-Boot-Users] [ppc4xx] Please pull git://www.denx.de/git/u-boot-ppc4xx.git Stefan Roese
2008-04-07 21:54                                           ` Wolfgang Denk
2008-04-09 10:58                                           ` Stefan Roese
2008-04-11 14:49                                             ` Stefan Roese
2008-04-12  7:02                                               ` [U-Boot-Users] [cfi-flash] Please pull git://www.denx.de/git/u-boot-cfi-flash.git Stefan Roese
2008-04-13 17:18                                                 ` Wolfgang Denk
2008-04-25 13:55                                                 ` Stefan Roese
2008-04-25 22:07                                                   ` Wolfgang Denk
2008-04-13 17:17                                               ` [U-Boot-Users] [ppc4xx] Please pull git://www.denx.de/git/u-boot-ppc4xx.git Wolfgang Denk
2008-04-18 15:02                                               ` Stefan Roese
2008-04-22 13:51                                                 ` Stefan Roese
2008-04-22 15:28                                                   ` Wolfgang Denk
2008-04-25 11:40                                                   ` Stefan Roese
2008-04-25 22:06                                                     ` Wolfgang Denk
2008-04-13 17:17                                             ` Wolfgang Denk
2008-01-11 15:14                       ` Stefan Roese
2008-01-11 23:16                         ` Wolfgang Denk
2008-01-17 15:07                           ` Stefan Roese
2008-01-23 13:20                             ` Wolfgang Denk
2008-01-13 14:11                         ` [U-Boot-Users] [cfi-flash] Please pull git://www.denx.de/git/u-boot-cfi-flash.git Stefan Roese
2008-01-13 15:53                           ` Wolfgang Denk
2008-01-16 13:33                           ` [U-Boot-Users] [nand-flash] Please pull git://www.denx.de/git/u-boot-nand-flash.git Stefan Roese
2008-01-16 14:05                             ` Wolfgang Denk
2008-04-18 14:30                             ` Stefan Roese
2008-01-14  9:11                         ` [U-Boot-Users] [ppc4xx] Please pull git://www.denx.de/git/u-boot-ppc4xx.git Stefan Roese
2008-01-14  9:53                           ` Wolfgang Denk
2008-01-02 11:40                     ` [U-Boot-Users] [cfi-flash] Please pull git://www.denx.de/git/u-boot-cfi-flash.git Wolfgang Denk

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=200706221732.28457.sr@denx.de \
    --to=sr@denx.de \
    --cc=u-boot@lists.denx.de \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox