]> www.infradead.org Git - users/rw/ppcboot.git/commitdiff
* Re-arrange boot message formatting
authorwdenk <wdenk>
Wed, 29 Aug 2001 07:55:37 +0000 (07:55 +0000)
committerwdenk <wdenk>
Wed, 29 Aug 2001 07:55:37 +0000 (07:55 +0000)
  (includes patch by Jon Diekema, Fri, 10 Aug 2001)

* Add check for and prevent buffer overflow for BOOTP / DHCP string
  parameters

* Fix PUMA download on CCM board

* allow 0x... prefix on input
  (based on idea by Mads Dydensborg, Tue, 7 Aug 2001)

* allow to put "preboot" command in default configuration

* extended flash chip support for TQM8260 board (AM29LV800T/B,
  AM29LV160T/B, AM29DL322T/B, AM29DL323T/B)
* BCR tweakage for the 8260 bus mode on TQM8260
* SIUMCR tweakage enabling the MI interrupt (IRQ7) on TQM8260
* To simplify switching between bus modes, a new configuration option
  (CONFIG_BUSMODE_60x) has been added to the "config_TQM8260.h" file.
  If defined, BCR will be configured for the 60x mode, otherwise for
  8260 mode.

CHANGELOG
README
common/cmd_boot.c
cpu/mpc8260/speed.c
include/config_TQM8260.h
tools/mkimage.c

index 20c397a4db5f3abddee54ffc400a61875fcdc3d1..c01dd121e988e5ac7cf7b907caf74de4dae76efb 100644 (file)
--- a/CHANGELOG
+++ b/CHANGELOG
@@ -56,6 +56,9 @@ To do:
 Modifications for 1.0.5:
 ======================================================================
 
+* Re-arrange boot message formatting
+  (includes patch by Jon Diekema, Fri, 10 Aug 2001)
+
 * Add check for and prevent buffer overflow for BOOTP / DHCP string
   parameters
 
diff --git a/README b/README
index 074466cd6ed36fd2b1bf450fa512f4a610f77a88..1afd567b0528aa9fabb8576e88c36a6456c5e2bd 100644 (file)
--- a/README
+++ b/README
@@ -236,6 +236,12 @@ The following options need to be configured:
                CONFIG_8xx_GCLK_FREQ    - if get_gclk_freq() can not work e.g.
                                          no 32KHz reference PIT/RTC clock
 
+- Clock Interface:
+               CFG_CLKS_IN_HZ
+                If defined, all clock information including those
+                passed in the bd_info structure to the Linux kernel,
+                is calculated in Hz (otherwise it's in MHz).
+
 - Console Interface:
                Define exactly one of
                CONFIG_8xx_CONS_SMC1, CONFIG_8xx_CONS_SMC2 or
index 946fa09fc83ec9cada5422b1fee7a6a0381f706b..361ed57bfc9989f496c705f5da5e723950f39d6d 100644 (file)
@@ -80,8 +80,8 @@ void do_bdinfo (cmd_tbl_t *cmdtp, bd_t *bd, int flag, int argc, char *argv[])
 #ifdef CONFIG_HERMES
        print_str ("ethspeed",      strmhz(buf, bd->bi_ethspeed));
 #endif
-       printf ("\n  IP addr     = ");  print_IPaddr (bd->bi_ip_addr);
-       printf ("\n  baudrate    = %6ld bps\n", bd->bi_baudrate   );
+       printf ("\nIP addr     = ");    print_IPaddr (bd->bi_ip_addr);
+       printf ("\nbaudrate    = %6ld bps\n", bd->bi_baudrate   );
        print_num ("getc",          (ulong)bd->bi_mon_fnc->getc);
        print_num ("tstc",          (ulong)bd->bi_mon_fnc->tstc);
        print_num ("putc",          (ulong)bd->bi_mon_fnc->putc);
index 1a7bca30e810e2b7aacdce231428926d1e9e5bed..a48493d0e36ad7a599357aeae77610c6326a7e84 100644 (file)
@@ -196,11 +196,11 @@ prt_8260_clks(void)
     printf(" - dfbrg %ld, corecnf 0x%02lx, busdf %ld, cpmdf %ld, "
        "plldf %ld, pllmf %ld\n", dfbrg, corecnf, busdf, cpmdf, plldf, pllmf);
 
-    printf(" - vco_out %10ld, cpm_clk %10ld, bus_clk %10ld\n",
-       idata->vco_out, idata->cpm_clk, idata->bus_clk);
+    printf(" - vco_out %10ld, scc_clk %10ld, brg_clk %10ld\n", 
+       idata->vco_out, idata->scc_clk, idata->brg_clk);
 
-    printf(" - scc_clk %10ld, brg_clk %10ld, cpu_clk %10ld\n\n",
-       idata->scc_clk, idata->brg_clk, idata->cpu_clk);
+    printf(" - cpu_clk %10ld, cpm_clk %10ld, bus_clk %10ld\n\n",
+        idata->cpu_clk, idata->cpm_clk, idata->bus_clk);
 }
 
 /* ------------------------------------------------------------------------- */
index f3de7b0db34aab0704780da3bd60e206a87e4d7e..9c380ea72092316527de60948420ca12ce4177f0 100644 (file)
@@ -35,6 +35,8 @@
 
 #define CONFIG_MPC8260         1       /* This is a MPC8260 CPU                */
 #define CONFIG_TQM8260         100     /* ...on a TQM8260 module Rev.100       */
+
+/* Define 60x busmode only if your TQM8260 has L2 cache! */
 #if 0
 #define        CONFIG_BUSMODE_60x      1       /* bus mode: 60x                        */
 #else
@@ -49,9 +51,7 @@
 #define CONFIG_BOOTDELAY       5       /* autoboot after 5 seconds     */
 #endif
 
-#define CONFIG_PREBOOT "echo;" \
-       "echo Type \"run flash_nfs\" to mount root filesystem over NFS;" \
-       "echo"
+#define CONFIG_PREBOOT "echo;echo Type \"run flash_nfs\" to mount root filesystem over NFS;echo"
 
 #undef CONFIG_BOOTARGS
 #define CONFIG_BOOTCOMMAND                                                     \
index 3109c4ac0c08b33941835c6f4cba2f44dca454eb..74fa29f65730e0b563add717f75fef6f327216ac 100644 (file)
@@ -58,7 +58,7 @@ typedef struct table_entry {
 } table_entry_t;
 
 table_entry_t arch_name[] = {
-    {  IH_CPU_INVALID, "",             "Invalid CPU",          },
+    {  IH_CPU_INVALID, NULL,           "Invalid CPU",          },
     {  IH_CPU_ALPHA,   "alpha",        "Alpha",                },
     {  IH_CPU_ARM,     "arm",          "ARM",                  },
     {  IH_CPU_I386,    "x86",          "Intel x86",            },
@@ -74,7 +74,7 @@ table_entry_t arch_name[] = {
 };
 
 table_entry_t os_name[] = {
-    {  IH_OS_INVALID,  "",             "Invalid OS",           },
+    {  IH_OS_INVALID,  NULL,           "Invalid OS",           },
     {  IH_OS_OPENBSD,  "openbsd",      "OpenBSD",              },
     {  IH_OS_NETBSD,   "netbsd",       "NetBSD",               },
     {  IH_OS_FREEBSD,  "freebsd",      "FreeBSD",              },
@@ -96,7 +96,7 @@ table_entry_t os_name[] = {
 };
 
 table_entry_t type_name[] = {
-    {  IH_TYPE_INVALID,    "",           "Invalid Image",      },
+    {  IH_TYPE_INVALID,    NULL,         "Invalid Image",      },
     {  IH_TYPE_STANDALONE, "standalone", "Standalone Program", },
     {  IH_TYPE_KERNEL,     "kernel",     "Kernel Image",       },
     {  IH_TYPE_RAMDISK,    "ramdisk",    "RAMDisk Image",      },
@@ -163,33 +163,34 @@ main (int argc, char **argv)
 
        while (--argc > 0 && **++argv == '-') {
                while (*++*argv) {
+fprintf(stderr, "Flag '%c' - argc=%d\n",**argv,argc);
                        switch (**argv) {
                        case 'l':
                                lflag = 1;
                                break;
                        case 'A':
-                               if ((argc-- <= 0) ||
+                               if ((--argc <= 0) ||
                                    (opt_arch = get_arch(*++argv)) < 0)
                                        usage ();
                                goto NXTARG;
                        case 'C':
-                               if ((argc-- <= 0) ||
+                               if ((--argc <= 0) ||
                                    (opt_comp = get_comp(*++argv)) < 0)
                                        usage ();
                                goto NXTARG;
                        case 'O':
-                               if ((argc-- <= 0) ||
+                               if ((--argc <= 0) ||
                                    (opt_os = get_os(*++argv)) < 0)
                                        usage ();
                                goto NXTARG;
                        case 'T':
-                               if ((argc-- <= 0) ||
+                               if ((--argc <= 0) ||
                                    (opt_type = get_type(*++argv)) < 0)
                                        usage ();
                                goto NXTARG;
 
                        case 'a':
-                               if (argc-- <= 0)
+                               if (--argc <= 0)
                                        usage ();
                                addr = strtoul (*++argv, (char **)&ptr, 16);
                                if (*ptr) {
@@ -200,19 +201,19 @@ main (int argc, char **argv)
                                }
                                goto NXTARG;
                        case 'd':
-                               if (argc-- <= 0)
+                               if (--argc <= 0)
                                        usage ();
                                datafile = *++argv;
                                dflag = 1;
                                goto NXTARG;
                        case 's':
-                               if (argc-- <= 0)
+                               if (--argc <= 0)
                                        usage ();
                                scriptfile = *++argv;
                                sflag = 1;
                                goto NXTARG;
                        case 'e':
-                               if (argc-- <= 0)
+                               if (--argc <= 0)
                                        usage ();
                                ep = strtoul (*++argv, (char **)&ptr, 16);
                                if (*ptr) {
@@ -224,7 +225,7 @@ main (int argc, char **argv)
                                eflag = 1;
                                goto NXTARG;
                        case 'n':
-                               if (argc-- <= 0)
+                               if (--argc <= 0)
                                        usage ();
                                name = *++argv;
                                goto NXTARG;
@@ -654,14 +655,18 @@ static int get_type(char *name)
 static int get_table_entry (table_entry_t *table, char *msg, char *name)
 {
        table_entry_t *t;
+       int first = 1;
 
        for (t=table; t->val>=0; ++t) {
-               if (strcasecmp(t->sname, name) == 0)
+               if (t->sname && strcasecmp(t->sname, name)==0)
                        return (t->val);
        }
        fprintf (stderr, "\nInvalid %s Type - valid names are", msg);
        for (t=table; t->val>=0; ++t) {
-               fprintf (stderr, "%c %s", (t == table) ? ':' : ',', t->sname);
+               if (t->sname == NULL)
+                       continue;
+               fprintf (stderr, "%c %s", (first) ? ':' : ',', t->sname);
+               first = 0;
        }
        fprintf (stderr, "\n");
        return (-1);