FreeCalypso > hg > freecalypso-sw
comparison ffstools/Usage @ 250:3d88461d8284
beginning of TIFFS IVA documentation
author | Michael Spacefalcon <msokolov@ivan.Harhan.ORG> |
---|---|
date | Fri, 31 Jan 2014 07:37:39 +0000 |
parents | |
children | 63cd64625597 |
comparison
equal
deleted
inserted
replaced
249:66a6f1652909 | 250:3d88461d8284 |
---|---|
1 The generic tiffs utility needs to be invoked as follows: | |
2 | |
3 tiffs [global-options] <imgfile> <org> <cmd> [command-args] | |
4 | |
5 The first 3 non-optional arguments are the filename of the TIFFS image under | |
6 examination, the FFS organization being examined, and the operation to be | |
7 performed. The present utility is designed in the classic Unix manner in that | |
8 each invokation performs a single operation and exits, such that invokations of | |
9 tiffs (or one of the wrappers described below) may be plumbed into pipes and | |
10 the like. | |
11 | |
12 The 2nd argument to tiffs after the FFS image filename describes how the TIFFS | |
13 instance under study is organized in terms of flash sectors. The syntax of | |
14 this argument is KxN, where K is the flash sector size in KiB and N is the | |
15 number of sectors occupied by the FFS. For MokoFFS images the correct | |
16 organization argument is 64x7 (7 sectors of 64 KiB each); for Pirelli's FFS | |
17 images it is 256x18 (18 sectors of 256 KiB each). | |
18 | |
19 The following global options may be given before the image filename argument: | |
20 | |
21 -a num | |
22 | |
23 Use the specified flash block (sector) as the inode array block. | |
24 | |
25 -o offset | |
26 | |
27 The FFS image begins at the specified offset within the file, rather | |
28 than at the beginning. This option is useful when working with complete | |
29 device flash dumps of which FFS is only a part, starting somewhere | |
30 other than at 0. | |
31 | |
32 -r ino | |
33 | |
34 Use the specified inode as the root. Per Falcon's convention, TIFFS | |
35 inode numbers are always given in hex, hence this argument is | |
36 interpreted as hex without needing a 0x prefix. | |
37 | |
38 The invokation syntax for mokoffs and pirffs wrappers is the same as for tiffs, | |
39 except that the FFS organization argument (64x7 or 256x18) is omitted; the | |
40 wrapper fills that argument in before passing the command to the main tiffs | |
41 program. The only other difference is that instead of the generic -o global | |
42 option, mokoffs takes a -f global option (no argument) which indicates that one | |
43 is working with a complete flash dump image, rather than just the FFS portion; | |
44 mokoffs -f gets translated into tiffs -o0x380000. (pirffs has no such option | |
45 at all because Pirelli's FFS starts at offset 0 within its respective flash | |
46 chip select.) | |
47 | |
48 The next argument after the FFS organization for tiffs (or after the image | |
49 filename for mokoffs/pirffs) is the command (or operation) to be performed. | |
50 The following tiffs commands are currently available: | |
51 | |
52 Standard listing/extraction commands | |
53 ==================================== | |
54 | |
55 These commands list or extract the normally-visible content of the FFS, i.e., | |
56 the content which is visible when the FFS is "mounted" normally, and which the | |
57 FFS promises to preserve - as opposed to deleted or overwritten content. | |
58 | |
59 ls [-v[v]] [pathname...] | |
60 | |
61 Tiffs ls without additional arguments yields a listing of the complete FFS | |
62 directory tree, akin to tar tv. Example output fragment: | |
63 | |
64 fr 4096 /.journal | |
65 d /gsm | |
66 d /gsm/rf | |
67 d /gsm/rf/tx | |
68 f 512 /gsm/rf/tx/ramps.900 | |
69 f 128 /gsm/rf/tx/levels.900 | |
70 f 128 /gsm/rf/tx/calchan.900 | |
71 | |
72 The first character is 'f' for files or 'd' for directories. An 'r' following | |
73 immediately afterward means that the object has the read-only attribute set. | |
74 For files the listing includes the content size in bytes, and the last part is | |
75 the pathname of the object within the FFS. | |
76 | |
77 With a single -v option added after ls, the output will include verbose | |
78 information as to the segmentation structure of each file. With two -v options | |
79 or with -vv, this additional output will also include the byte offset of each | |
80 data chunk, relative to the beginning of the FFS image. | |
81 | |
82 Tiffs ls with a pathname argument yields information about the specified FFS | |
83 object; -v and -vv options act as already described, but are arguably more | |
84 useful when listing single files. |