blob: 2462ff6817119a13ab23e7e91cd3225249c5279b [file] [log] [blame]
yuezonghe824eb0c2024-06-27 02:32:26 -07001#!/bin/bash
2
3if [ x"$PAGESIZE" = x"" ]; then
4 PAGESIZE=0x800
5fi
6
7if [ x"$ERASEBLOCK" = x"" ]; then
8 ERASEBLOCK=0x20000
9fi
10
11mkfs.jffs2 --pagesize=$PAGESIZE --eraseblock=$ERASEBLOCK --little-endian --no-cleanmarkers --squash -d $1 -o $2
12if [ $? -ne 0 ]; then
13 echo "mkfs.jffs2 error"
14 exit -1
15else
16 echo "mkfs.jffs2 ok"
17fi
18
19exit 0