Send commitlog mailing list submissions to
        [email protected]

To subscribe or unsubscribe via the World Wide Web, visit
        http://lists.openmoko.org/mailman/listinfo/commitlog
or, via email, send a message with subject or body 'help' to
        [EMAIL PROTECTED]

You can reach the person managing the list at
        [EMAIL PROTECTED]

When replying, please edit your Subject line so it is more specific
than "Re: Contents of commitlog digest..."
Today's Topics:

   1. r1082 - in trunk/src/target/OM-2007/panel-plugins: .
      openmoko-panel-mainmenu/src ([EMAIL PROTECTED])
   2. r1083 - trunk/src/target/u-boot/patches ([EMAIL PROTECTED])
   3. r1084 - trunk/src/target/u-boot/patches ([EMAIL PROTECTED])
--- Begin Message ---
Author: mickey
Date: 2007-02-23 14:01:49 +0100 (Fri, 23 Feb 2007)
New Revision: 1082

Modified:
   trunk/src/target/OM-2007/panel-plugins/README
   
trunk/src/target/OM-2007/panel-plugins/openmoko-panel-mainmenu/src/openmoko-panel-mainmenu.c
   trunk/src/target/OM-2007/panel-plugins/panel-plugins.pro
Log:
panel-plugins/README: catch up w/ forthcoming move to matchbox-panel-2


Modified: trunk/src/target/OM-2007/panel-plugins/README
===================================================================
--- trunk/src/target/OM-2007/panel-plugins/README       2007-02-23 03:00:00 UTC 
(rev 1081)
+++ trunk/src/target/OM-2007/panel-plugins/README       2007-02-23 13:01:49 UTC 
(rev 1082)
@@ -1,3 +1,4 @@
-Applications that dock in the Top Panel go here.
-Naming Scheme: openmoko-panel-<name of application>
+Matchbox-Panel-2 plugins that dock in the Top Panel go here.
+Need to be installed to ${libdir}/matchbox-panel/
+Naming Scheme: openmoko-panel-<name of plugin>
 

Modified: 
trunk/src/target/OM-2007/panel-plugins/openmoko-panel-mainmenu/src/openmoko-panel-mainmenu.c
===================================================================
--- 
trunk/src/target/OM-2007/panel-plugins/openmoko-panel-mainmenu/src/openmoko-panel-mainmenu.c
        2007-02-23 03:00:00 UTC (rev 1081)
+++ 
trunk/src/target/OM-2007/panel-plugins/openmoko-panel-mainmenu/src/openmoko-panel-mainmenu.c
        2007-02-23 13:01:49 UTC (rev 1082)
@@ -75,3 +75,5 @@
     return GTK_WIDGET(applet);
 }
 
+
+

Modified: trunk/src/target/OM-2007/panel-plugins/panel-plugins.pro
===================================================================
--- trunk/src/target/OM-2007/panel-plugins/panel-plugins.pro    2007-02-23 
03:00:00 UTC (rev 1081)
+++ trunk/src/target/OM-2007/panel-plugins/panel-plugins.pro    2007-02-23 
13:01:49 UTC (rev 1082)
@@ -4,4 +4,3 @@
   openmoko-panel-clock \
   openmoko-panel-mainmenu
 
-




--- End Message ---
--- Begin Message ---
Author: werner
Date: 2007-02-23 16:54:01 +0100 (Fri, 23 Feb 2007)
New Revision: 1083

Added:
   trunk/src/target/u-boot/patches/dontask.patch
   trunk/src/target/u-boot/patches/wakeup-reason-nand-only.patch
Modified:
   trunk/src/target/u-boot/patches/boot-from-ram-and-nand.patch
   trunk/src/target/u-boot/patches/boot-from-ram-reloc.patch
   trunk/src/target/u-boot/patches/dynenv-harden.patch
   trunk/src/target/u-boot/patches/enable-splash-bmp.patch
   trunk/src/target/u-boot/patches/preboot-override.patch
   trunk/src/target/u-boot/patches/series
   trunk/src/target/u-boot/patches/uboot-neo1973-resume.patch
   trunk/src/target/u-boot/patches/uboot-s3c2410-norelocate_irqvec_cpy.patch
Log:
preboot-override.patch: execute command string from RAM (overrides normal
  operation)
uboot-neo1973-resume.patch: adjusted to fit with the other start.S patches
boot-from-ram-and-nand.patch: decide whether to boot from RAM or NAND at run
  time
dynenv-harden.patch: "dynenv set" also updates environment offset in running
  u-boot
uboot-s3c2410-norelocate_irqvec_cpy.patch: adjusted for other patches
wakeup-reason-nand-only.patch: make u-boot skip wakeup cause detection if not
  booting from NAND (experimental)
boot-from-ram-reloc.patch: boot from anywhere in RAM
enable-splash-bmp.patch: refreshed
dontask.patch: new environment variable "dontask" to override interactive
  prompt in various destructive NAND operations



Modified: trunk/src/target/u-boot/patches/boot-from-ram-and-nand.patch
===================================================================
--- trunk/src/target/u-boot/patches/boot-from-ram-and-nand.patch        
2007-02-23 13:01:49 UTC (rev 1082)
+++ trunk/src/target/u-boot/patches/boot-from-ram-and-nand.patch        
2007-02-23 15:54:01 UTC (rev 1083)
@@ -1,3 +1,15 @@
+Auto-detect whether we're booting from RAM or NAND, and act accordingly. This
+allows us to use the same u-boot binary for all boot modes.
+
+include/configs/neo1973.h: introduced new config option
+  CONFIG_LL_INIT_NAND_ONLY to perform low-level initialization only when
+  booting from NAND
+include/configs/neo1973.h: got rid of BUILD_FOR_RAM
+cpu/arm920t/start.S: detect if we need to boot from NAND at run time (i.e., if
+  we're running at address 0)
+
+- Werner Almesberger <[EMAIL PROTECTED]>
+
 Index: u-boot/cpu/arm920t/start.S
 ===================================================================
 --- u-boot.orig/cpu/arm920t/start.S
@@ -2,3 +14,3 @@
 +++ u-boot/cpu/arm920t/start.S
-@@ -157,17 +157,18 @@ reset:
+@@ -157,18 +157,21 @@ reset:
        str     r1, [r0]
@@ -10,25 +22,27 @@
 -       * we do sys-critical inits only at reboot,
 -       * not when booting from ram!
 -       */
--#ifndef CONFIG_SKIP_LOWLEVEL_INIT
-+#if !defined(CONFIG_SKIP_LOWLEVEL_INIT ) && !defined(CONFIG_LL_INIT_NAND_ONLY)
+ #ifndef CONFIG_SKIP_LOWLEVEL_INIT
++#ifndef CONFIG_LL_INIT_NAND_ONLY
        bl      cpu_init_crit
  #endif
++#endif
  
+ #ifndef CONFIG_SKIP_RELOCATE_UBOOT
 -#ifndef CONFIG_S3C2410_NAND_BOOT
 -relocate:                             /* relocate U-Boot to RAM           */
        adr     r0, _start              /* r0 <- current position of code   */
++
 +#ifdef CONFIG_S3C2410_NAND_BOOT
-+      teq     r0, #0                  /* are we running from NAND ?       */
++      teq     r0, #0                  /* are we running from NAND ?       */
 +      beq     nand_load
 +#endif /* CONFIG_S3C2410_NAND_BOOT */
 +
 +relocate:                             /* relocate U-Boot to RAM           */
-+      adr     r0, _start
        ldr     r1, _TEXT_BASE          /* test if we run from flash or RAM */
        cmp     r0, r1                  /* don't reloc during debug         */
        beq     done_relocate
-@@ -187,10 +188,12 @@ copy_loop:
+@@ -188,10 +191,13 @@ copy_loop:
        ldr     pc, _done_relocate      /* jump to relocated code */
  _done_relocate:
        .word   done_relocate
@@ -37,6 +51,7 @@
 -relocate:
 -copy_myself:
 +
++#ifdef CONFIG_S3C2410_NAND_BOOT
 +nand_load:
 +#if !defined(CONFIG_SKIP_LOWLEVEL_INIT) && defined(CONFIG_LL_INIT_NAND_ONLY)
 +      bl      cpu_init_crit
@@ -45,15 +60,16 @@
        /* mov  r10, lr */
  
        @ reset NAND
-@@ -274,7 +277,7 @@ notmatch:
+@@ -275,7 +281,8 @@ notmatch:
  #endif
  1:    b       1b
  done_nand_read:
 -#endif /* NAND_BOOT */
++#endif /* CONFIG_S3C2410_NAND_BOOT */
 +done_relocate:
+ #endif /* CONFIG_SKIP_RELOCATE_UBOOT */
  
- #if defined(CONFIG_USE_IRQ) && defined(CONFIG_S3C2410)
-       /* In the case of the S3C2410, if we've somehow magically (JTAG, ...)
+       /* Set up the stack                                                 */
 Index: u-boot/include/configs/neo1973.h
 ===================================================================
 --- u-boot.orig/include/configs/neo1973.h

Modified: trunk/src/target/u-boot/patches/boot-from-ram-reloc.patch
===================================================================
--- trunk/src/target/u-boot/patches/boot-from-ram-reloc.patch   2007-02-23 
13:01:49 UTC (rev 1082)
+++ trunk/src/target/u-boot/patches/boot-from-ram-reloc.patch   2007-02-23 
15:54:01 UTC (rev 1083)
@@ -1,3 +1,15 @@
+This patch allows us to boot from anywhere in RAM. It mainly sets the stage
+for later patches. The only real changes here is the better handling of already
+cached code (e.g., if we were started by a previous instance of u-boot), and
+that we drop CONFIG_SKIP_RELOCATE_UBOOT from neo1973.h
+
+cpu/arm920t/start.S: if not relocating, instead of going straight to
+  stack_setup, jump to done_relocate, which may perform other setup tasks
+cpu/arm920t/start.S: after relocating, flush the cache and jump to the new code
+include/configs/neo1973.h: remove CONFIG_SKIP_RELOCATE_UBOOT
+
+- Werner Almesberger <[EMAIL PROTECTED]>
+
 Index: u-boot/cpu/arm920t/start.S
 ===================================================================
 --- u-boot.orig/cpu/arm920t/start.S
@@ -2,9 +14,3 @@
 +++ u-boot/cpu/arm920t/start.S
-@@ -165,13 +165,12 @@ reset:
-       bl      cpu_init_crit
- #endif
- 
--#ifndef CONFIG_SKIP_RELOCATE_UBOOT
- #ifndef CONFIG_S3C2410_NAND_BOOT
- relocate:                             /* relocate U-Boot to RAM           */
+@@ -171,7 +171,7 @@ relocate:                          /* relocate U-Boot to 
RAM        
        adr     r0, _start              /* r0 <- current position of code   */
@@ -17,15 +23,15 @@
  
        ldr     r2, _armboot_start
        ldr     r3, _bss_start
-@@ -181,8 +180,14 @@ relocate:                         /* relocate U-Boot to 
RAM        
+@@ -181,8 +181,14 @@ relocate:                         /* relocate U-Boot to 
RAM        
  copy_loop:
        ldmia   r0!, {r3-r10}           /* copy from source address [r0]    */
        stmia   r1!, {r3-r10}           /* copy to   target address [r1]    */
 -      cmp     r0, r2                  /* until source end addreee [r2]    */
 +      cmp     r0, r2                  /* until source end address [r2]    */
        ble     copy_loop
-+      mov     r0, #0
-+      mcr     p15, 0, r0, c7, c7, 0   /* flush v3/v4 cache */
++      mov     r0, #0                  /* flush v3/v4 cache */
++      mcr     p15, 0, r0, c7, c7, 0
 +      ldr     pc, _done_relocate      /* jump to relocated code */
 +_done_relocate:
 +      .word   done_relocate
@@ -33,26 +39,12 @@
  #else /* NAND_BOOT */
  relocate:
  copy_myself:
-@@ -270,11 +275,13 @@ notmatch:
+@@ -270,7 +276,7 @@ notmatch:
  1:    b       1b
  done_nand_read:
  #endif /* NAND_BOOT */
--#else  /* CONFIG_SKIP_RELOCATE_UBOOT */
-+
- #if defined(CONFIG_USE_IRQ) && defined(CONFIG_S3C2410)
-       /* In the case of the S3C2410, if we've somehow magically (JTAG, ...)
-          ended up in RAM, then that ram is mapped to 0x30000000 and not 0.
-          So we need to copy the interrupt vectors, etc.  */
-+      /* NB: do this always. In the worst case, we'll overwrite with
-+         identical data. */
- 
-       mov     r0, #0
-       ldr     r1, _TEXT_BASE
-@@ -287,7 +294,6 @@ irqvec_cpy_next:
-       bne     irqvec_cpy_next
- irqvec_cpy_done:
- #endif /* CONFIG_USE_IRQ */
 -#endif        /* CONFIG_SKIP_RELOCATE_UBOOT */
++#endif /* CONFIG_SKIP_RELOCATE_UBOOT */
  
        /* Set up the stack                                                 */
  stack_setup:

Added: trunk/src/target/u-boot/patches/dontask.patch
===================================================================
--- trunk/src/target/u-boot/patches/dontask.patch       2007-02-23 13:01:49 UTC 
(rev 1082)
+++ trunk/src/target/u-boot/patches/dontask.patch       2007-02-23 15:54:01 UTC 
(rev 1083)
@@ -0,0 +1,22 @@
+common/cmd_nand.c (yes): if the environment variable "dontask" is set to "y" or
+  "Y", non-interactively assume the answer was "yes". In all other cases, ask.
+
+- Werner Almesberger <[EMAIL PROTECTED]>
+
+Index: u-boot/common/cmd_nand.c
+===================================================================
+--- u-boot.orig/common/cmd_nand.c
++++ u-boot/common/cmd_nand.c
+@@ -165,8 +165,12 @@ out:
+ 
+ static int yes(void)
+ {
++      char *s;
+       char c;
+ 
++      s = getenv("dontask");
++      if (s && (s[0] =='y' || s[0] == 'Y') && !s[1])
++              return 1;
+       c = getc();
+       if (c != 'y' && c != 'Y')
+               return 0;

Modified: trunk/src/target/u-boot/patches/dynenv-harden.patch
===================================================================
--- trunk/src/target/u-boot/patches/dynenv-harden.patch 2007-02-23 13:01:49 UTC 
(rev 1082)
+++ trunk/src/target/u-boot/patches/dynenv-harden.patch 2007-02-23 15:54:01 UTC 
(rev 1083)
@@ -4,6 +4,8 @@
   allow use of partition name
 common/cmd_dynenv.c (do_dynenv): indicate in no uncertain terms when an update
   would not work due to Flash bits already cleared
+common/cmd_dynenv.c (do_dynenv): update CFG_ENV_OFFSET after successful "dynenv
+  set", so that we can write the new environment without having to reboot
 
 - Werner Almesberger <[EMAIL PROTECTED]>
 
@@ -115,7 +117,16 @@
                memcpy(buf+4, &addr, 4);
  
                printf("%02x %02x %02x %02x - %02x %02x %02x %02x\n",
-@@ -72,8 +90,9 @@ int do_dynenv(cmd_tbl_t *cmdtp, int flag
+@@ -65,6 +83,8 @@ int do_dynenv(cmd_tbl_t *cmdtp, int flag
+                       buf[4], buf[5], buf[6], buf[7]);
+ 
+               ret = mtd->write_oob(mtd, 8, size, (size_t *) &size, (u_char *) 
buf);
++              if (!ret)
++                      CFG_ENV_OFFSET = addr;
+       } else
+               goto usage;
+ 
+@@ -72,8 +92,9 @@ int do_dynenv(cmd_tbl_t *cmdtp, int flag
        return ret;
  
  usage:

Modified: trunk/src/target/u-boot/patches/enable-splash-bmp.patch
===================================================================
--- trunk/src/target/u-boot/patches/enable-splash-bmp.patch     2007-02-23 
13:01:49 UTC (rev 1082)
+++ trunk/src/target/u-boot/patches/enable-splash-bmp.patch     2007-02-23 
15:54:01 UTC (rev 1083)
@@ -22,7 +22,7 @@
 ===================================================================
 --- u-boot.orig/include/configs/neo1973.h
 +++ u-boot/include/configs/neo1973.h
-@@ -91,6 +91,7 @@
+@@ -86,6 +86,7 @@
                        /* CFG_CMD_IRQ   | */  \
                        CFG_CMD_BOOTD    | \
                        CFG_CMD_CONSOLE  | \
@@ -30,7 +30,7 @@
                        CFG_CMD_ASKENV   | \
                        CFG_CMD_RUN      | \
                        CFG_CMD_ECHO     | \
-@@ -249,19 +250,21 @@
+@@ -244,19 +245,21 @@
  /* we have a board_late_init() function */
  #define BOARD_LATE_INIT                       1
  

Modified: trunk/src/target/u-boot/patches/preboot-override.patch
===================================================================
--- trunk/src/target/u-boot/patches/preboot-override.patch      2007-02-23 
13:01:49 UTC (rev 1082)
+++ trunk/src/target/u-boot/patches/preboot-override.patch      2007-02-23 
15:54:01 UTC (rev 1083)
@@ -1,3 +1,16 @@
+Provide a place where the loader can patch the binary, such that it executes a
+command string from RAM. We use this for automated installs, where we can thus
+use the same u-boot binary for all stages.
+
+include/configs/neo1973.h: new option CFG_PREBOOT_OVERRIDE to allow setting of
+  the preboot command in memory
+cpu/arm920t/start.S: added variable "preboot_override" at known location
+  (_start+0x40)
+common/main.c (main_loop): if preboot_override is set, execute the command
+  string found there
+
+- Werner Almesberger <[EMAIL PROTECTED]>
+
 Index: u-boot/cpu/arm920t/start.S
 ===================================================================
 --- u-boot.orig/cpu/arm920t/start.S
@@ -2,6 +15,7 @@
 +++ u-boot/cpu/arm920t/start.S
-@@ -77,6 +77,12 @@ _fiq:                       .word fiq
+@@ -77,6 +77,13 @@ _fiq:                       .word fiq
   *************************************************************************
   */
  
++/* Must follow the .balign above, so we get a well-known address ! */
 +#ifdef CFG_PREBOOT_OVERRIDE
@@ -12,9 +26,9 @@
 +      .word   0
 +#endif
 +
- _TEXT_BASE:
-       .word   TEXT_BASE
- 
+ #ifdef CONFIG_S3C2410_NAND_BOOT
+ .globl        booted_from_nand
+ booted_from_nand:
 Index: u-boot/include/configs/neo1973.h
 ===================================================================
 --- u-boot.orig/include/configs/neo1973.h
@@ -54,7 +68,7 @@
  #endif
  #ifdef CONFIG_BOOTCOUNT_LIMIT
        unsigned long bootcount = 0;
-@@ -364,8 +369,19 @@ void main_loop (void)
+@@ -364,8 +369,23 @@ void main_loop (void)
        install_auto_complete();
  #endif
  
@@ -65,6 +79,10 @@
 +#endif
 +#ifdef CFG_PREBOOT_OVERRIDE
 +      if (preboot_override) {
++              /* for convenience, preboot_override may end in \n, not \0 */
++              p = strchr(preboot_override, '\n');
++              if (p)
++                      *p = 0;
 +              /* make sure we can overwrite the load area if we want to */
 +              p = strdup(preboot_override);
 +              /* clean the image in case we want to flash it */
@@ -75,7 +93,7 @@
  # ifdef CONFIG_AUTOBOOT_KEYED
                int prev = disable_ctrlc(1);    /* disable Control C checking */
  # endif
-@@ -381,7 +397,7 @@ void main_loop (void)
+@@ -381,7 +401,7 @@ void main_loop (void)
                disable_ctrlc(prev);    /* restore Control C checking */
  # endif
        }

Modified: trunk/src/target/u-boot/patches/series
===================================================================
--- trunk/src/target/u-boot/patches/series      2007-02-23 13:01:49 UTC (rev 
1082)
+++ trunk/src/target/u-boot/patches/series      2007-02-23 15:54:01 UTC (rev 
1083)
@@ -14,9 +14,15 @@
 uboot-cmd_s3c2410.patch
 uboot-s3c2410-mmc.patch
 env_nand_oob.patch
+dynenv-harden.patch
 uboot-s3c2410_fb.patch
 uboot-20061030-qt2410.patch 
 uboot-20061030-neo1973.patch 
+
+# under construction, but intended for mainline
+boot-from-ram-reloc.patch
+boot-from-ram-and-nand.patch
+wakeup-reason-nand-only.patch
 uboot-neo1973-resume.patch
 
 # this will be somewhat more difficult
@@ -29,6 +35,7 @@
 # those need to be cleaned up
 bbt-create-optional.patch
 nand-createbbt.patch
+dontask.patch
 nand-badisbad.patch
 dynpart-absorb-bad.patch
 uboot-bbt-quiet.patch
@@ -43,4 +50,5 @@
 cmd-unzip.patch
 enable-splash-bmp.patch
 
-dynenv-harden.patch
+# for automated installation
+preboot-override.patch

Modified: trunk/src/target/u-boot/patches/uboot-neo1973-resume.patch
===================================================================
--- trunk/src/target/u-boot/patches/uboot-neo1973-resume.patch  2007-02-23 
13:01:49 UTC (rev 1082)
+++ trunk/src/target/u-boot/patches/uboot-neo1973-resume.patch  2007-02-23 
15:54:01 UTC (rev 1083)
@@ -4,9 +4,9 @@
 
 Index: u-boot/cpu/arm920t/start.S
 ===================================================================
---- u-boot.orig/cpu/arm920t/start.S    2007-02-21 22:52:55.000000000 +0100
-+++ u-boot/cpu/arm920t/start.S 2007-02-21 23:21:08.000000000 +0100
-@@ -150,11 +150,33 @@
+--- u-boot.orig/cpu/arm920t/start.S
++++ u-boot/cpu/arm920t/start.S
+@@ -158,18 +158,55 @@ reset:
        str     r1, [r0]
  # endif
  
@@ -40,13 +40,11 @@
 +      bpl     1b
  #endif        /* CONFIG_S3C2400 || CONFIG_S3C2410 */
  
-       /*
-@@ -163,7 +185,23 @@
-        */
  #ifndef CONFIG_SKIP_LOWLEVEL_INIT
+ #ifndef CONFIG_LL_INIT_NAND_ONLY
        bl      cpu_init_crit
+ #endif
 -#endif
-+
 +#if defined(CONFIG_S3C2410)
 +      /* ensure some refresh has happened */
 +      mov     r1, #4096
@@ -65,12 +63,12 @@
 +#endif /* CONFIG_SKIP_LOWLEVEL_INIT */
  
  #ifndef CONFIG_SKIP_RELOCATE_UBOOT
- #ifndef CONFIG_S3C2410_NAND_BOOT
+       adr     r0, _start              /* r0 <- current position of code   */
 Index: u-boot/include/s3c2410.h
 ===================================================================
---- u-boot.orig/include/s3c2410.h      2007-02-21 15:52:58.000000000 +0100
-+++ u-boot/include/s3c2410.h   2007-02-21 15:54:34.000000000 +0100
-@@ -233,4 +233,40 @@
+--- u-boot.orig/include/s3c2410.h
++++ u-boot/include/s3c2410.h
+@@ -233,4 +233,40 @@ static inline S3C2410_SDI * S3C2410_GetB
                 rINTPND;\
                 }
  /* Wait until rINTPND is changed for the case that the ISR is very short. */
@@ -111,4 +109,3 @@
 +#define S3C2410_CLKSLOW_GET_SLOWVAL(x)        ((x) & 7)
 +
  #endif /*__S3C2410_H__*/
-

Modified: 
trunk/src/target/u-boot/patches/uboot-s3c2410-norelocate_irqvec_cpy.patch
===================================================================
--- trunk/src/target/u-boot/patches/uboot-s3c2410-norelocate_irqvec_cpy.patch   
2007-02-23 13:01:49 UTC (rev 1082)
+++ trunk/src/target/u-boot/patches/uboot-s3c2410-norelocate_irqvec_cpy.patch   
2007-02-23 15:54:01 UTC (rev 1083)
@@ -1,15 +1,15 @@
 If we've somehow magically make u-boot end up in RAM (JTAG, ...), then that RAM
 is mapped to 0x30000000 and not 0, so we need to copy the interrupt vectors, 
etc. 
 
-Index: u-boot.git/cpu/arm920t/start.S
+Index: u-boot/cpu/arm920t/start.S
 ===================================================================
---- u-boot.git.orig/cpu/arm920t/start.S        2007-02-04 14:25:20.000000000 
+0100
-+++ u-boot.git/cpu/arm920t/start.S     2007-02-04 14:39:42.000000000 +0100
-@@ -277,6 +277,23 @@
- 1:    b       1b
- done_nand_read:
- #endif /* NAND_BOOT */
-+#else  /* CONFIG_SKIP_RELOCATE_UBOOT */
+--- u-boot.orig/cpu/arm920t/start.S
++++ u-boot/cpu/arm920t/start.S
+@@ -332,6 +332,24 @@ done_nand_read:
+ #endif /* CONFIG_S3C2410_NAND_BOOT */
+ 
+ done_relocate:
++
 +#if defined(CONFIG_USE_IRQ) && defined(CONFIG_S3C2410)
 +      /* In the case of the S3C2410, if we've somehow magically (JTAG, ...)
 +         ended up in RAM, then that ram is mapped to 0x30000000 and not 0.
@@ -26,6 +26,7 @@
 +      bne     irqvec_cpy_next
 +irqvec_cpy_done:
 +#endif /* CONFIG_USE_IRQ */
- #endif        /* CONFIG_SKIP_RELOCATE_UBOOT */
++
+ #endif /* CONFIG_SKIP_RELOCATE_UBOOT */
  
        /* Set up the stack                                                 */

Added: trunk/src/target/u-boot/patches/wakeup-reason-nand-only.patch
===================================================================
--- trunk/src/target/u-boot/patches/wakeup-reason-nand-only.patch       
2007-02-23 13:01:49 UTC (rev 1082)
+++ trunk/src/target/u-boot/patches/wakeup-reason-nand-only.patch       
2007-02-23 15:54:01 UTC (rev 1083)
@@ -0,0 +1,68 @@
+This patch should get rid of spurious poweroff after booting from RAM.
+Experimental.
+
+cpu/arm920t/start.S: record in global variable "booted_from_nand" whether we
+  booted from NAND or not
+board/neo1973/neo1973.c (board_late_init): if booted from RAM, assume that
+  wakeup cause was "reset", and skip poweroff check
+
+- Werner Almesberger <[EMAIL PROTECTED]>
+
+Index: u-boot/board/neo1973/neo1973.c
+===================================================================
+--- u-boot.orig/board/neo1973/neo1973.c
++++ u-boot/board/neo1973/neo1973.c
+@@ -193,12 +193,16 @@ int board_init (void)
+ 
+ int board_late_init(void)
+ {
++      extern unsigned char booted_from_nand;
+       unsigned char tmp;
+       char buf[32];
+ 
+       /* Initialize the Power Management Unit with a safe register set */
+       pcf50606_init();
+ 
++      if (!booted_from_nand)
++              goto woken_by_reset;
++
+       /* obtain wake-up reason, save INT1 in environment */
+       tmp = pcf50606_reg_read(PCF50606_REG_INT1);
+       sprintf(buf, "0x%02x", tmp);
+@@ -241,6 +245,7 @@ int board_late_init(void)
+               neo1973_poweroff();
+       }
+ 
++woken_by_reset:
+       /* if there's no other reason, must be regular reset */
+       neo1973_wakeup_cause = NEO1973_WAKEUP_RESET;
+ 
+Index: u-boot/cpu/arm920t/start.S
+===================================================================
+--- u-boot.orig/cpu/arm920t/start.S
++++ u-boot/cpu/arm920t/start.S
+@@ -77,6 +77,14 @@ _fiq:                       .word fiq
+  *************************************************************************
+  */
+ 
++#ifdef CONFIG_S3C2410_NAND_BOOT
++.globl        booted_from_nand
++booted_from_nand:
++      .word   0
++_booted_from_nand:
++      .word   booted_from_nand
++#endif /* CONFIG_S3C2410_NAND_BOOT */
++
+ _TEXT_BASE:
+       .word   TEXT_BASE
+ 
+@@ -281,6 +289,9 @@ notmatch:
+ #endif
+ 1:    b       1b
+ done_nand_read:
++      ldr     r0, _booted_from_nand
++      mov     r1, #1
++      strb    r1, [r0]
+ #endif /* CONFIG_S3C2410_NAND_BOOT */
+ done_relocate:
+ #endif /* CONFIG_SKIP_RELOCATE_UBOOT */




--- End Message ---
--- Begin Message ---
Author: werner
Date: 2007-02-23 19:28:20 +0100 (Fri, 23 Feb 2007)
New Revision: 1084

Modified:
   trunk/src/target/u-boot/patches/preboot-override.patch
   trunk/src/target/u-boot/patches/uboot-20061030-neo1973.patch
Log:
common/env_common.c (env_relocate):  if preboot_override is set, always use the
  default environment
board/neo1973/neo1973.c (board_late_init): activate the LCM before the
  backlight, to avoid white flash



Modified: trunk/src/target/u-boot/patches/preboot-override.patch
===================================================================
--- trunk/src/target/u-boot/patches/preboot-override.patch      2007-02-23 
15:54:01 UTC (rev 1083)
+++ trunk/src/target/u-boot/patches/preboot-override.patch      2007-02-23 
18:28:20 UTC (rev 1084)
@@ -8,6 +8,8 @@
   (_start+0x40)
 common/main.c (main_loop): if preboot_override is set, execute the command
   string found there
+common/env_common.c (env_relocate):  if preboot_override is set, always use the
+  default environment
 
 - Werner Almesberger <[EMAIL PROTECTED]>
 
@@ -102,3 +104,33 @@
  
  #if defined(CONFIG_BOOTDELAY) && (CONFIG_BOOTDELAY >= 0)
        s = getenv ("bootdelay");
+Index: u-boot/common/env_common.c
+===================================================================
+--- u-boot.orig/common/env_common.c
++++ u-boot/common/env_common.c
+@@ -37,6 +37,10 @@
+ # define SHOW_BOOT_PROGRESS(arg)
+ #endif
+ 
++#ifdef CFG_PREBOOT_OVERRIDE
++extern char *preboot_override;
++#endif
++
+ DECLARE_GLOBAL_DATA_PTR;
+ 
+ #ifdef CONFIG_AMIGAONEG3SE
+@@ -234,7 +238,14 @@ void env_relocate (void)
+               puts ("*** Warning - bad CRC, using default environment\n\n");
+               SHOW_BOOT_PROGRESS (-1);
+ #endif
++      }
++
++#ifdef CFG_PREBOOT_OVERRIDE
++      if (preboot_override)
++              gd->env_valid = 0;
++#endif
+ 
++      if (gd->env_valid == 0) {
+               if (sizeof(default_environment) > ENV_SIZE)
+               {
+                       puts ("*** Error - default environment is too 
large\n\n");

Modified: trunk/src/target/u-boot/patches/uboot-20061030-neo1973.patch
===================================================================
--- trunk/src/target/u-boot/patches/uboot-20061030-neo1973.patch        
2007-02-23 15:54:01 UTC (rev 1083)
+++ trunk/src/target/u-boot/patches/uboot-20061030-neo1973.patch        
2007-02-23 18:28:20 UTC (rev 1084)
@@ -6,9 +6,9 @@
 
 Index: u-boot/Makefile
 ===================================================================
---- u-boot.orig/Makefile       2007-02-16 23:34:01.000000000 +0100
-+++ u-boot/Makefile    2007-02-16 23:37:04.000000000 +0100
-@@ -1928,6 +1928,13 @@
+--- u-boot.orig/Makefile
++++ u-boot/Makefile
+@@ -1931,6 +1931,13 @@ omap730p2_cs3boot_config :      unconfig
  sbc2410x_config: unconfig
        @$(MKCONFIG) $(@:_config=) arm arm920t sbc2410x NULL s3c24x0
  
@@ -24,8 +24,8 @@
  
 Index: u-boot/board/neo1973/Makefile
 ===================================================================
---- /dev/null  1970-01-01 00:00:00.000000000 +0000
-+++ u-boot/board/neo1973/Makefile      2007-02-16 23:40:48.000000000 +0100
+--- /dev/null
++++ u-boot/board/neo1973/Makefile
 @@ -0,0 +1,47 @@
 +#
 +# (C) Copyright 2000, 2001, 2002
@@ -76,8 +76,8 @@
 +#########################################################################
 Index: u-boot/board/neo1973/config.mk
 ===================================================================
---- /dev/null  1970-01-01 00:00:00.000000000 +0000
-+++ u-boot/board/neo1973/config.mk     2007-02-16 23:37:00.000000000 +0100
+--- /dev/null
++++ u-boot/board/neo1973/config.mk
 @@ -0,0 +1,34 @@
 +#
 +# (C) Copyright 2002
@@ -115,8 +115,8 @@
 +endif
 Index: u-boot/board/neo1973/neo1973.c
 ===================================================================
---- /dev/null  1970-01-01 00:00:00.000000000 +0000
-+++ u-boot/board/neo1973/neo1973.c     2007-02-16 23:40:48.000000000 +0100
+--- /dev/null
++++ u-boot/board/neo1973/neo1973.c
 @@ -0,0 +1,317 @@
 +/*
 + * (C) 2006 by OpenMoko, Inc.
@@ -365,6 +365,10 @@
 +      neo1973_wakeup_cause = NEO1973_WAKEUP_RESET;
 +
 +continue_boot:
++      jbt6k74_init();
++      jbt6k74_enter_state(JBT_STATE_NORMAL);
++      jbt6k74_display_onoff(1);
++
 +      /* issue a short pulse with the vibrator */
 +      neo1973_vibrator(1);
 +      udelay(50000);
@@ -373,10 +377,6 @@
 +      /* switch on the backlight */
 +      neo1973_backlight(1);
 +
-+      jbt6k74_init();
-+      jbt6k74_enter_state(JBT_STATE_NORMAL);
-+      jbt6k74_display_onoff(1);
-+
 +      return 0;
 +}
 +
@@ -437,8 +437,8 @@
 +}
 Index: u-boot/board/neo1973/lowlevel_init.S
 ===================================================================
---- /dev/null  1970-01-01 00:00:00.000000000 +0000
-+++ u-boot/board/neo1973/lowlevel_init.S       2007-02-16 23:37:04.000000000 
+0100
+--- /dev/null
++++ u-boot/board/neo1973/lowlevel_init.S
 @@ -0,0 +1,188 @@
 +/*
 + * Memory Setup stuff - taken from blob memsetup.S
@@ -630,8 +630,8 @@
 +    .word 0x30
 Index: u-boot/board/neo1973/u-boot.lds
 ===================================================================
---- /dev/null  1970-01-01 00:00:00.000000000 +0000
-+++ u-boot/board/neo1973/u-boot.lds    2007-02-16 23:34:02.000000000 +0100
+--- /dev/null
++++ u-boot/board/neo1973/u-boot.lds
 @@ -0,0 +1,58 @@
 +/*
 + * (C) Copyright 2002
@@ -693,8 +693,8 @@
 +}
 Index: u-boot/include/configs/neo1973.h
 ===================================================================
---- /dev/null  1970-01-01 00:00:00.000000000 +0000
-+++ u-boot/include/configs/neo1973.h   2007-02-16 23:41:35.000000000 +0100
+--- /dev/null
++++ u-boot/include/configs/neo1973.h
 @@ -0,0 +1,257 @@
 +/*
 + * (C) Copyright 2006 OpenMoko, Inc.
@@ -955,8 +955,8 @@
 +#endif        /* __CONFIG_H */
 Index: u-boot/board/neo1973/split_by_variant.sh
 ===================================================================
---- /dev/null  1970-01-01 00:00:00.000000000 +0000
-+++ u-boot/board/neo1973/split_by_variant.sh   2007-02-16 23:37:04.000000000 
+0100
+--- /dev/null
++++ u-boot/board/neo1973/split_by_variant.sh
 @@ -0,0 +1,49 @@
 +#!/bin/sh
 +# ---------------------------------------------------------
@@ -1009,8 +1009,8 @@
 +$MKCONFIG -a neo1973 arm arm920t neo1973 NULL s3c24x0
 Index: u-boot/board/neo1973/cmd_neo1973.c
 ===================================================================
---- /dev/null  1970-01-01 00:00:00.000000000 +0000
-+++ u-boot/board/neo1973/cmd_neo1973.c 2007-02-16 23:38:13.000000000 +0100
+--- /dev/null
++++ u-boot/board/neo1973/cmd_neo1973.c
 @@ -0,0 +1,120 @@
 +/*
 + * (C) Copyright 2006 by OpenMoko, Inc.
@@ -1134,8 +1134,8 @@
 +#endif        /* CFG_CMD_BDI */
 Index: u-boot/board/neo1973/neo1973.h
 ===================================================================
---- /dev/null  1970-01-01 00:00:00.000000000 +0000
-+++ u-boot/board/neo1973/neo1973.h     2007-02-16 23:38:13.000000000 +0100
+--- /dev/null
++++ u-boot/board/neo1973/neo1973.h
 @@ -0,0 +1,18 @@
 +#ifndef _NEO1973_H
 +#define _NEO1973_H
@@ -1157,8 +1157,8 @@
 +#endif
 Index: u-boot/board/neo1973/pcf50606.c
 ===================================================================
---- /dev/null  1970-01-01 00:00:00.000000000 +0000
-+++ u-boot/board/neo1973/pcf50606.c    2007-02-16 23:38:13.000000000 +0100
+--- /dev/null
++++ u-boot/board/neo1973/pcf50606.c
 @@ -0,0 +1,168 @@
 +
 +#include <common.h>
@@ -1330,8 +1330,8 @@
 +}
 Index: u-boot/board/neo1973/pcf50606.h
 ===================================================================
---- /dev/null  1970-01-01 00:00:00.000000000 +0000
-+++ u-boot/board/neo1973/pcf50606.h    2007-02-16 23:38:13.000000000 +0100
+--- /dev/null
++++ u-boot/board/neo1973/pcf50606.h
 @@ -0,0 +1,267 @@
 +#ifndef _PCF50606_H
 +#define _PCF50606_H
@@ -1602,9 +1602,9 @@
 +
 Index: u-boot/common/main.c
 ===================================================================
---- u-boot.orig/common/main.c  2007-02-16 23:35:56.000000000 +0100
-+++ u-boot/common/main.c       2007-02-16 23:38:13.000000000 +0100
-@@ -61,6 +61,7 @@
+--- u-boot.orig/common/main.c
++++ u-boot/common/main.c
+@@ -61,6 +61,7 @@ static int abortboot(int);
  #undef DEBUG_PARSER
  
  char        console_buffer[CFG_CBSIZE];               /* console I/O buffer   
*/
@@ -1612,7 +1612,7 @@
  
  #ifndef CONFIG_CMDLINE_EDITING
  static char * delete_char (char *buffer, char *p, int *colp, int *np, int 
plen);
-@@ -404,7 +405,7 @@
+@@ -404,7 +405,7 @@ void main_loop (void)
  
        debug ("### main_loop: bootcmd=\"%s\"\n", s ? s : "<UNDEFINED>");
  
@@ -1623,8 +1623,8 @@
  # endif
 Index: u-boot/board/neo1973/jbt6k74.c
 ===================================================================
---- /dev/null  1970-01-01 00:00:00.000000000 +0000
-+++ u-boot/board/neo1973/jbt6k74.c     2007-02-16 23:40:48.000000000 +0100
+--- /dev/null
++++ u-boot/board/neo1973/jbt6k74.c
 @@ -0,0 +1,403 @@
 +/* u-boot driver for the tpo JBT6K74-AS LCM ASIC
 + *
@@ -2031,8 +2031,8 @@
 +}
 Index: u-boot/board/neo1973/jbt6k74.h
 ===================================================================
---- /dev/null  1970-01-01 00:00:00.000000000 +0000
-+++ u-boot/board/neo1973/jbt6k74.h     2007-02-16 23:40:48.000000000 +0100
+--- /dev/null
++++ u-boot/board/neo1973/jbt6k74.h
 @@ -0,0 +1,14 @@
 +#ifndef _JBT6K74_H
 +#define _JBT6K74_H




--- End Message ---
_______________________________________________
commitlog mailing list
[email protected]
http://lists.openmoko.org/mailman/listinfo/commitlog

Reply via email to