annotate configs/classic @ 516:1ed9de6c90bd

src/g23m-gsm/sms/sms_for.c: bogus malloc removed The new error handling code that was not present in TCS211 blob version contains a malloc call that is bogus for 3 reasons: 1) The memory allocation in question is not needed in the first place; 2) libc malloc is used instead of one of the firmware's proper ways; 3) The memory allocation is made inside a function and then never freed, i.e., a memory leak. This bug was caught in gcc-built FreeCalypso fw projects (Citrine and Selenite) because our gcc environment does not allow any use of libc malloc (any reference to malloc produces a link failure), but this code from TCS3.2 is wrong even for Magnetite: if this code path is executed repeatedly over a long time, the many small allocations made by this malloc call without a subsequent free will eventually exhaust the malloc heap provided by the TMS470 environment, malloc will start returning NULL, and the bogus code will treat it as an error. Because the memory allocation in question is not needed at all, the fix entails simply removing it.
author Mychaela Falconia <falcon@freecalypso.org>
date Sun, 22 Jul 2018 06:04:49 +0000
parents 2c61607bb3e3
children 4a242cfb9bc5
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
57
ecad19ce63c5 configs/classic: concept created
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
1 # This configuration reproduces the original TCS211 pdt_2091 build,
ecad19ce63c5 configs/classic: concept created
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
2 # using almost all of the original blobs from Sotovik.
ecad19ce63c5 configs/classic: concept created
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
3
144
fd8227e3047d config headers overhaul
Mychaela Falconia <falcon@freecalypso.org>
parents: 68
diff changeset
4 scripts/config-headers.sh gprs 2091
57
ecad19ce63c5 configs/classic: concept created
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
5
ecad19ce63c5 configs/classic: concept created
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
6 CONDAT=condat2
ecad19ce63c5 configs/classic: concept created
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
7 GPF=gpf2
ecad19ce63c5 configs/classic: concept created
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
8 CDGINC=cdg211/cdginc
ecad19ce63c5 configs/classic: concept created
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
9 CDGPRIM=cdg211/prim
172
2c61607bb3e3 build system: pass ACI version for headers to the component recipes
Mychaela Falconia <falcon@freecalypso.org>
parents: 144
diff changeset
10 ACI=aci2
2c61607bb3e3 build system: pass ACI version for headers to the component recipes
Mychaela Falconia <falcon@freecalypso.org>
parents: 144
diff changeset
11 export CONDAT GPF CDGINC CDGPRIM ACI
57
ecad19ce63c5 configs/classic: concept created
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
12
ecad19ce63c5 configs/classic: concept created
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
13 GPRS=1
ecad19ce63c5 configs/classic: concept created
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
14 MMI=0
ecad19ce63c5 configs/classic: concept created
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
15 SRVC=1
ecad19ce63c5 configs/classic: concept created
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
16 export GPRS MMI SRVC
ecad19ce63c5 configs/classic: concept created
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
17
65
bb53b2e2d548 revamped the handling of blob libs
Mychaela Falconia <falcon@freecalypso.org>
parents: 57
diff changeset
18 blob_lib_std ccddata
57
ecad19ce63c5 configs/classic: concept created
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
19
ecad19ce63c5 configs/classic: concept created
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
20 # ACI libs
ecad19ce63c5 configs/classic: concept created
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
21 build_lib aci classic
ecad19ce63c5 configs/classic: concept created
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
22 build_lib aciext classic
ecad19ce63c5 configs/classic: concept created
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
23 build_lib aci_dti_mng classic
ecad19ce63c5 configs/classic: concept created
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
24 build_lib atiext classic
ecad19ce63c5 configs/classic: concept created
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
25 build_lib comlib
ecad19ce63c5 configs/classic: concept created
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
26 build_lib config_gprs_fl
ecad19ce63c5 configs/classic: concept created
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
27 build_lib config_gprs_ir
ecad19ce63c5 configs/classic: concept created
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
28 lib_link_magic '(BSS_LIBS (.bss) CONST_LIBS (.text, .const))'
ecad19ce63c5 configs/classic: concept created
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
29
ecad19ce63c5 configs/classic: concept created
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
30 # G23M protocol stack libs
65
bb53b2e2d548 revamped the handling of blob libs
Mychaela Falconia <falcon@freecalypso.org>
parents: 57
diff changeset
31 blob_lib_std alr
bb53b2e2d548 revamped the handling of blob libs
Mychaela Falconia <falcon@freecalypso.org>
parents: 57
diff changeset
32 blob_lib_std cc
bb53b2e2d548 revamped the handling of blob libs
Mychaela Falconia <falcon@freecalypso.org>
parents: 57
diff changeset
33 blob_lib_std cci
bb53b2e2d548 revamped the handling of blob libs
Mychaela Falconia <falcon@freecalypso.org>
parents: 57
diff changeset
34 blob_lib_std cci_ir
57
ecad19ce63c5 configs/classic: concept created
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
35 lib_link_magic '(BSS_LIBS (.bss) CONST_LIBS (.text, .const))'
65
bb53b2e2d548 revamped the handling of blob libs
Mychaela Falconia <falcon@freecalypso.org>
parents: 57
diff changeset
36 blob_lib_std dl
bb53b2e2d548 revamped the handling of blob libs
Mychaela Falconia <falcon@freecalypso.org>
parents: 57
diff changeset
37 blob_lib_std dti
bb53b2e2d548 revamped the handling of blob libs
Mychaela Falconia <falcon@freecalypso.org>
parents: 57
diff changeset
38 blob_lib_std fad
bb53b2e2d548 revamped the handling of blob libs
Mychaela Falconia <falcon@freecalypso.org>
parents: 57
diff changeset
39 blob_lib_std gmm
bb53b2e2d548 revamped the handling of blob libs
Mychaela Falconia <falcon@freecalypso.org>
parents: 57
diff changeset
40 blob_lib_std grlc
bb53b2e2d548 revamped the handling of blob libs
Mychaela Falconia <falcon@freecalypso.org>
parents: 57
diff changeset
41 blob_lib_std grlc_ir
57
ecad19ce63c5 configs/classic: concept created
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
42 lib_link_magic '(BSS_LIBS (.bss) CONST_LIBS (.text, .const))'
65
bb53b2e2d548 revamped the handling of blob libs
Mychaela Falconia <falcon@freecalypso.org>
parents: 57
diff changeset
43 blob_lib_std grr
bb53b2e2d548 revamped the handling of blob libs
Mychaela Falconia <falcon@freecalypso.org>
parents: 57
diff changeset
44 blob_lib_std l1_pei
bb53b2e2d548 revamped the handling of blob libs
Mychaela Falconia <falcon@freecalypso.org>
parents: 57
diff changeset
45 blob_lib_std l2r
bb53b2e2d548 revamped the handling of blob libs
Mychaela Falconia <falcon@freecalypso.org>
parents: 57
diff changeset
46 blob_lib_std llc
bb53b2e2d548 revamped the handling of blob libs
Mychaela Falconia <falcon@freecalypso.org>
parents: 57
diff changeset
47 blob_lib_std mm
bb53b2e2d548 revamped the handling of blob libs
Mychaela Falconia <falcon@freecalypso.org>
parents: 57
diff changeset
48 blob_lib_std ra
bb53b2e2d548 revamped the handling of blob libs
Mychaela Falconia <falcon@freecalypso.org>
parents: 57
diff changeset
49 blob_lib_std rlp
bb53b2e2d548 revamped the handling of blob libs
Mychaela Falconia <falcon@freecalypso.org>
parents: 57
diff changeset
50 blob_lib_std rr
bb53b2e2d548 revamped the handling of blob libs
Mychaela Falconia <falcon@freecalypso.org>
parents: 57
diff changeset
51 blob_lib_std sim_b_lib
bb53b2e2d548 revamped the handling of blob libs
Mychaela Falconia <falcon@freecalypso.org>
parents: 57
diff changeset
52 blob_lib_std sm
bb53b2e2d548 revamped the handling of blob libs
Mychaela Falconia <falcon@freecalypso.org>
parents: 57
diff changeset
53 blob_lib_std sms
bb53b2e2d548 revamped the handling of blob libs
Mychaela Falconia <falcon@freecalypso.org>
parents: 57
diff changeset
54 blob_lib_std sndcp
bb53b2e2d548 revamped the handling of blob libs
Mychaela Falconia <falcon@freecalypso.org>
parents: 57
diff changeset
55 blob_lib_std ss
bb53b2e2d548 revamped the handling of blob libs
Mychaela Falconia <falcon@freecalypso.org>
parents: 57
diff changeset
56 blob_lib_std t30
bb53b2e2d548 revamped the handling of blob libs
Mychaela Falconia <falcon@freecalypso.org>
parents: 57
diff changeset
57 blob_lib_std uart_b_lib
bb53b2e2d548 revamped the handling of blob libs
Mychaela Falconia <falcon@freecalypso.org>
parents: 57
diff changeset
58 blob_lib_std ppp
bb53b2e2d548 revamped the handling of blob libs
Mychaela Falconia <falcon@freecalypso.org>
parents: 57
diff changeset
59 blob_lib_std ppp_ir
57
ecad19ce63c5 configs/classic: concept created
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
60 lib_link_magic '(BSS_LIBS (.bss) CONST_LIBS (.text, .const))'
ecad19ce63c5 configs/classic: concept created
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
61
ecad19ce63c5 configs/classic: concept created
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
62 # Condat drivers
ecad19ce63c5 configs/classic: concept created
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
63 build_lib gdi
ecad19ce63c5 configs/classic: concept created
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
64
ecad19ce63c5 configs/classic: concept created
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
65 # GPF
65
bb53b2e2d548 revamped the handling of blob libs
Mychaela Falconia <falcon@freecalypso.org>
parents: 57
diff changeset
66 blob_lib_gpf ccd_na7_db
bb53b2e2d548 revamped the handling of blob libs
Mychaela Falconia <falcon@freecalypso.org>
parents: 57
diff changeset
67 blob_lib_gpf frame_na7_db_fl
67
41779e8ae4da configs/classic: use blobs/patches/frame_na7_db_ir-systrace.lib
Mychaela Falconia <falcon@freecalypso.org>
parents: 66
diff changeset
68 blob_lib_custom blobs/patches/frame_na7_db_ir-systrace.lib frame_na7_db_ir
57
ecad19ce63c5 configs/classic: concept created
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
69 lib_link_magic '(BSS_LIBS (.bss) CONST_LIBS (.text, .const))'
65
bb53b2e2d548 revamped the handling of blob libs
Mychaela Falconia <falcon@freecalypso.org>
parents: 57
diff changeset
70 blob_lib_gpf misc_na7_db_fl
bb53b2e2d548 revamped the handling of blob libs
Mychaela Falconia <falcon@freecalypso.org>
parents: 57
diff changeset
71 blob_lib_gpf misc_na7_db_ir
57
ecad19ce63c5 configs/classic: concept created
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
72 lib_link_magic '(BSS_LIBS (.bss) CONST_LIBS (.text, .const))'
65
bb53b2e2d548 revamped the handling of blob libs
Mychaela Falconia <falcon@freecalypso.org>
parents: 57
diff changeset
73 blob_lib_gpf osx_na7_db
57
ecad19ce63c5 configs/classic: concept created
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
74 lib_link_magic '(BSS_LIBS (.bss) CONST_LIBS (.text, .const))'
65
bb53b2e2d548 revamped the handling of blob libs
Mychaela Falconia <falcon@freecalypso.org>
parents: 57
diff changeset
75 blob_lib_gpf tif_na7_db_fl
bb53b2e2d548 revamped the handling of blob libs
Mychaela Falconia <falcon@freecalypso.org>
parents: 57
diff changeset
76 blob_lib_gpf tif_na7_db_ir
57
ecad19ce63c5 configs/classic: concept created
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
77 lib_link_magic '(BSS_LIBS (.bss) CONST_LIBS (.text, .const))'
ecad19ce63c5 configs/classic: concept created
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
78
ecad19ce63c5 configs/classic: concept created
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
79 # core drivers
ecad19ce63c5 configs/classic: concept created
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
80 build_lib drivers_flash
ecad19ce63c5 configs/classic: concept created
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
81
ecad19ce63c5 configs/classic: concept created
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
82 # Layer 1
66
0377665aef9d tpudrv.lib blob selection in targets/*.conf
Mychaela Falconia <falcon@freecalypso.org>
parents: 65
diff changeset
83 blob_lib_custom "$TPUDRV_blob" tpudrv
57
ecad19ce63c5 configs/classic: concept created
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
84 lib_link_magic '(BSS_LIBS (.bss) CONST_LIBS (.text, .const))'
65
bb53b2e2d548 revamped the handling of blob libs
Mychaela Falconia <falcon@freecalypso.org>
parents: 57
diff changeset
85 blob_lib_std l1_ext
57
ecad19ce63c5 configs/classic: concept created
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
86 lib_link_magic '(BSS_LIBS (.l1s_global))'
65
bb53b2e2d548 revamped the handling of blob libs
Mychaela Falconia <falcon@freecalypso.org>
parents: 57
diff changeset
87 blob_lib_std l1_int
57
ecad19ce63c5 configs/classic: concept created
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
88 lib_link_magic '(BSS_LIBS (.bss) CONST_LIBS (.text, .const))'
65
bb53b2e2d548 revamped the handling of blob libs
Mychaela Falconia <falcon@freecalypso.org>
parents: 57
diff changeset
89 blob_lib_std l1_custom_ext
bb53b2e2d548 revamped the handling of blob libs
Mychaela Falconia <falcon@freecalypso.org>
parents: 57
diff changeset
90 blob_lib_std l1_custom_int
57
ecad19ce63c5 configs/classic: concept created
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
91 lib_link_magic '(BSS_LIBS (.bss) CONST_LIBS (.text, .const))'
ecad19ce63c5 configs/classic: concept created
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
92
ecad19ce63c5 configs/classic: concept created
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
93 build_lib riviera_core_flash
ecad19ce63c5 configs/classic: concept created
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
94 build_lib riviera_cust_flash
ecad19ce63c5 configs/classic: concept created
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
95
ecad19ce63c5 configs/classic: concept created
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
96 # services
ecad19ce63c5 configs/classic: concept created
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
97 build_lib atp
ecad19ce63c5 configs/classic: concept created
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
98 build_lib audio
ecad19ce63c5 configs/classic: concept created
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
99 build_lib audio_bgd
ecad19ce63c5 configs/classic: concept created
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
100 build_lib cst
ecad19ce63c5 configs/classic: concept created
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
101 build_lib dar
ecad19ce63c5 configs/classic: concept created
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
102 build_lib dar_gbl_var
ecad19ce63c5 configs/classic: concept created
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
103 lib_link_magic '(BSS_DAR_LIB (.bss))'
ecad19ce63c5 configs/classic: concept created
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
104 build_lib etm
ecad19ce63c5 configs/classic: concept created
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
105 build_lib lls
ecad19ce63c5 configs/classic: concept created
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
106 build_lib mks
ecad19ce63c5 configs/classic: concept created
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
107
ecad19ce63c5 configs/classic: concept created
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
108 # app drivers
ecad19ce63c5 configs/classic: concept created
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
109 build_lib abb
ecad19ce63c5 configs/classic: concept created
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
110 build_lib buzzer
ecad19ce63c5 configs/classic: concept created
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
111 build_lib ffs
ecad19ce63c5 configs/classic: concept created
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
112 build_lib ffs_drv
ecad19ce63c5 configs/classic: concept created
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
113 build_lib ffs_pcm
ecad19ce63c5 configs/classic: concept created
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
114 build_lib kpd
ecad19ce63c5 configs/classic: concept created
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
115 build_lib lcc
ecad19ce63c5 configs/classic: concept created
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
116 build_lib power
ecad19ce63c5 configs/classic: concept created
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
117 build_lib rtc_drv
ecad19ce63c5 configs/classic: concept created
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
118 build_lib sim_drv
ecad19ce63c5 configs/classic: concept created
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
119 build_lib spi_drv
ecad19ce63c5 configs/classic: concept created
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
120 build_lib uart_drv
ecad19ce63c5 configs/classic: concept created
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
121
ecad19ce63c5 configs/classic: concept created
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
122 # eyesores
65
bb53b2e2d548 revamped the handling of blob libs
Mychaela Falconia <falcon@freecalypso.org>
parents: 57
diff changeset
123 blob_lib_custom "$MAIN_blob" main
68
838717193e09 eliminated the use of bootloader.lib binary blob
Mychaela Falconia <falcon@freecalypso.org>
parents: 67
diff changeset
124 build_lib bootloader
57
ecad19ce63c5 configs/classic: concept created
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
125 lib_link_magic '(CONST_BOOT_LIB (.const, .text, .text:v$3) BSS_BOOT_LIB (.bss))'
ecad19ce63c5 configs/classic: concept created
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
126
ecad19ce63c5 configs/classic: concept created
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
127 # Nucleus and TI's compiler stuff
65
bb53b2e2d548 revamped the handling of blob libs
Mychaela Falconia <falcon@freecalypso.org>
parents: 57
diff changeset
128 blob_lib_os nucleus_flash_nodbg
bb53b2e2d548 revamped the handling of blob libs
Mychaela Falconia <falcon@freecalypso.org>
parents: 57
diff changeset
129 blob_lib_os nucleus_int_ram_nodbg
57
ecad19ce63c5 configs/classic: concept created
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
130 lib_link_magic '(BSS_LIBS (.bss) CONST_LIBS (.text, .const))'
65
bb53b2e2d548 revamped the handling of blob libs
Mychaela Falconia <falcon@freecalypso.org>
parents: 57
diff changeset
131 blob_lib_os rts16le_flash
bb53b2e2d548 revamped the handling of blob libs
Mychaela Falconia <falcon@freecalypso.org>
parents: 57
diff changeset
132 blob_lib_os rts16le_int_ram
57
ecad19ce63c5 configs/classic: concept created
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
133 lib_link_magic '(BSS_LIBS (.bss))'
ecad19ce63c5 configs/classic: concept created
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
134
ecad19ce63c5 configs/classic: concept created
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
135 str2ind_blobs_used=1