English Language flag
// Log In
// CVSweb
Project: FreeWRT
// Summary // Activity // Search // Tracker // Lists // News // SCM // Wiki

SCM Repository

ViewVC logotype

Diff of /branches/freewrt_1_0/target/linux/brcm-2.4/squashfs-overlay/files/etc/init.d/S20jffsclean

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

revision 2765 by wbx, Thu Sep 28 10:42:55 2006 UTC revision 2766 by tha, Mon Jun 11 23:24:02 2007 UTC
# Line 1  Line 1 
1  #!/bin/sh  #!/bin/sh
2  # if / is tmpfs, we have an old or broken jffs2  
3  # erase data partition and set flag between bootloader and kernel  case $1 in
4  { mount|grep "on / type tmpfs" 1>&-; } && {  autostart)
5          mtd erase data          exec $0 start
6          jffs2root --clean          ;;
7          reboot  start)
8  }          # if / is tmpfs, we have an old or broken jffs2
9            # erase data partition and set flag between bootloader and kernel
10            { mount|grep "on / type tmpfs" 1>&-; } && {
11                    mtd erase data
12                    jffs2root --clean
13                    /bin/sync && /bin/busybox reboot -f
14            }
15            ;;
16    stop)
17            echo "no stop function implemented..."
18            ;;
19    *)
20            echo "Usage: $0 {start | stop }"
21            exit 1
22            ;;
23    esac
24    exit $?

Legend:
Removed from v.2765  
changed lines
  Added in v.2766

root@freewrt.org:443
ViewVC Help
Powered by ViewVC 1.1.20