20_reset_clear_jffs 287 B

1234567891011121314
  1. #!/bin/sh
  2. # Copyright (C) 2006-2010 OpenWrt.org
  3. # Copyright (C) 2010 Vertical Communications
  4. reset_clear_jffs() {
  5. [ "$reset_has_fo" = "true" ] && {
  6. rm -rf $jffs/* 2>&-
  7. mount -o remount $jffs / 2>&-
  8. exit 0
  9. } || reset_has_fo=false
  10. }
  11. boot_hook_add jffs2reset reset_clear_jffs