annotate gsm-fw/cfgmagic/feature.aftermarket-ffs @ 1034:405b5469abc4 default tip

top README: repository change notice
author Mychaela Falconia <falcon@freecalypso.org>
date Sun, 12 Jun 2016 19:06:34 +0000
parents f22b34873ea5
children
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
943
f22b34873ea5 gsm-fw: feature pirhack-ffs changed to feature aftermarket-ffs,
Mychaela Falconia <falcon@ivan.Harhan.ORG>
parents: 942
diff changeset
1 # This feature is specific to Compal and Pirelli targets. When we put our own
f22b34873ea5 gsm-fw: feature pirhack-ffs changed to feature aftermarket-ffs,
Mychaela Falconia <falcon@ivan.Harhan.ORG>
parents: 942
diff changeset
2 # FreeCalypso firmware on these phones, we are using them in a way that is very
f22b34873ea5 gsm-fw: feature pirhack-ffs changed to feature aftermarket-ffs,
Mychaela Falconia <falcon@ivan.Harhan.ORG>
parents: 942
diff changeset
3 # different from how they were intended to be used by their respective
f22b34873ea5 gsm-fw: feature pirhack-ffs changed to feature aftermarket-ffs,
Mychaela Falconia <falcon@ivan.Harhan.ORG>
parents: 942
diff changeset
4 # manufacturers. Hence the term "aftermarket". Although the original firmwares
f22b34873ea5 gsm-fw: feature pirhack-ffs changed to feature aftermarket-ffs,
Mychaela Falconia <falcon@ivan.Harhan.ORG>
parents: 942
diff changeset
5 # of these phones are TI-based and feature TI-based flash file systems, neither
f22b34873ea5 gsm-fw: feature pirhack-ffs changed to feature aftermarket-ffs,
Mychaela Falconia <falcon@ivan.Harhan.ORG>
parents: 942
diff changeset
6 # Pirelli's FFS nor that of any Compal variant is suitable for direct reuse by
f22b34873ea5 gsm-fw: feature pirhack-ffs changed to feature aftermarket-ffs,
Mychaela Falconia <falcon@ivan.Harhan.ORG>
parents: 942
diff changeset
7 # FreeCalypso GSM fw.
207
c70c077243dd gsm-fw: beginning of config magic for FFS
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff changeset
8 #
943
f22b34873ea5 gsm-fw: feature pirhack-ffs changed to feature aftermarket-ffs,
Mychaela Falconia <falcon@ivan.Harhan.ORG>
parents: 942
diff changeset
9 # Therefore, if we are putting our own fw on one of these aftermarket devices
f22b34873ea5 gsm-fw: feature pirhack-ffs changed to feature aftermarket-ffs,
Mychaela Falconia <falcon@ivan.Harhan.ORG>
parents: 942
diff changeset
10 # and we need to use a real non-volatile FFS in flash, rather than fake FFS
f22b34873ea5 gsm-fw: feature pirhack-ffs changed to feature aftermarket-ffs,
Mychaela Falconia <falcon@ivan.Harhan.ORG>
parents: 942
diff changeset
11 # in RAM, we need to define our own aftermarket FFS, and we can put it in any
f22b34873ea5 gsm-fw: feature pirhack-ffs changed to feature aftermarket-ffs,
Mychaela Falconia <falcon@ivan.Harhan.ORG>
parents: 942
diff changeset
12 # part of the flash that suits our needs, without much regard for Compal's or
f22b34873ea5 gsm-fw: feature pirhack-ffs changed to feature aftermarket-ffs,
Mychaela Falconia <falcon@ivan.Harhan.ORG>
parents: 942
diff changeset
13 # Foxconn's originally intended flash layout - what we are doing with their
f22b34873ea5 gsm-fw: feature pirhack-ffs changed to feature aftermarket-ffs,
Mychaela Falconia <falcon@ivan.Harhan.ORG>
parents: 942
diff changeset
14 # hardware goes totally against their intentions anyway.
226
4d706a4134b0 FFS in gsm-fw: generate the legacy block info table at run time
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents: 207
diff changeset
15 #
943
f22b34873ea5 gsm-fw: feature pirhack-ffs changed to feature aftermarket-ffs,
Mychaela Falconia <falcon@ivan.Harhan.ORG>
parents: 942
diff changeset
16 # Because our aftermarket FFS configuration inherently involves our own choice
f22b34873ea5 gsm-fw: feature pirhack-ffs changed to feature aftermarket-ffs,
Mychaela Falconia <falcon@ivan.Harhan.ORG>
parents: 942
diff changeset
17 # of flash location for this FFS, the present feature aftermarket-ffs takes two
f22b34873ea5 gsm-fw: feature pirhack-ffs changed to feature aftermarket-ffs,
Mychaela Falconia <falcon@ivan.Harhan.ORG>
parents: 942
diff changeset
18 # required arguments: the starting flash sector number and the total number of
f22b34873ea5 gsm-fw: feature pirhack-ffs changed to feature aftermarket-ffs,
Mychaela Falconia <falcon@ivan.Harhan.ORG>
parents: 942
diff changeset
19 # flash sectors to be used for the aftermarket FFS. It is the user's
f22b34873ea5 gsm-fw: feature pirhack-ffs changed to feature aftermarket-ffs,
Mychaela Falconia <falcon@ivan.Harhan.ORG>
parents: 942
diff changeset
20 # responsibility to ensure that these numbers are sensible.
207
c70c077243dd gsm-fw: beginning of config magic for FFS
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff changeset
21
942
042c178ebac5 gsm-fw/cfgmagic: logic for target-dependent features streamlined a little
Mychaela Falconia <falcon@ivan.Harhan.ORG>
parents: 269
diff changeset
22 check_target_feature "$1"
207
c70c077243dd gsm-fw: beginning of config magic for FFS
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff changeset
23
269
6e7410f7975c gsm-fw feature pirhack-ffs: require explicit selection of sectors to be used
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents: 226
diff changeset
24 if [ $# != 3 ]
6e7410f7975c gsm-fw feature pirhack-ffs: require explicit selection of sectors to be used
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents: 226
diff changeset
25 then
943
f22b34873ea5 gsm-fw: feature pirhack-ffs changed to feature aftermarket-ffs,
Mychaela Falconia <falcon@ivan.Harhan.ORG>
parents: 942
diff changeset
26 echo "feature aftermarket-ffs: two arguments required" 1>&2
269
6e7410f7975c gsm-fw feature pirhack-ffs: require explicit selection of sectors to be used
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents: 226
diff changeset
27 exit 1
6e7410f7975c gsm-fw feature pirhack-ffs: require explicit selection of sectors to be used
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents: 226
diff changeset
28 fi
6e7410f7975c gsm-fw feature pirhack-ffs: require explicit selection of sectors to be used
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents: 226
diff changeset
29
207
c70c077243dd gsm-fw: beginning of config magic for FFS
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff changeset
30 FFS_IN_RAM=0
943
f22b34873ea5 gsm-fw: feature pirhack-ffs changed to feature aftermarket-ffs,
Mychaela Falconia <falcon@ivan.Harhan.ORG>
parents: 942
diff changeset
31 CONFIG_AFTERMARKET_FFS=1
f22b34873ea5 gsm-fw: feature pirhack-ffs changed to feature aftermarket-ffs,
Mychaela Falconia <falcon@ivan.Harhan.ORG>
parents: 942
diff changeset
32 CONFIG_AFTERMARKET_FFS_START=$2
f22b34873ea5 gsm-fw: feature pirhack-ffs changed to feature aftermarket-ffs,
Mychaela Falconia <falcon@ivan.Harhan.ORG>
parents: 942
diff changeset
33 CONFIG_AFTERMARKET_FFS_NBLOCKS=$3
207
c70c077243dd gsm-fw: beginning of config magic for FFS
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff changeset
34 CONFIG_FLASH_WRITE=1
943
f22b34873ea5 gsm-fw: feature pirhack-ffs changed to feature aftermarket-ffs,
Mychaela Falconia <falcon@ivan.Harhan.ORG>
parents: 942
diff changeset
35 export_to_c CONFIG_AFTERMARKET_FFS
f22b34873ea5 gsm-fw: feature pirhack-ffs changed to feature aftermarket-ffs,
Mychaela Falconia <falcon@ivan.Harhan.ORG>
parents: 942
diff changeset
36 export_to_c CONFIG_AFTERMARKET_FFS_START
f22b34873ea5 gsm-fw: feature pirhack-ffs changed to feature aftermarket-ffs,
Mychaela Falconia <falcon@ivan.Harhan.ORG>
parents: 942
diff changeset
37 export_to_c CONFIG_AFTERMARKET_FFS_NBLOCKS
207
c70c077243dd gsm-fw: beginning of config magic for FFS
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff changeset
38 export_to_c CONFIG_FLASH_WRITE