comparison gsm-fw/services/ffs/task.c @ 218:fee45482aa2a

FFS: hopefully-correct initialization for the FFS_IN_RAM configuration
author Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
date Mon, 06 Jan 2014 08:43:35 +0000
parents 3ebe6409e8bc
children 2beb88a3d528
comparison
equal deleted inserted replaced
217:30a173257f4a 218:fee45482aa2a
206 ttr_init(TTrTask|TTrTest|TTrTestInfo); 206 ttr_init(TTrTask|TTrTest|TTrTestInfo);
207 //ttr_init(TTrTask|TTrTest|TTrTestInfo|TTrDrvErase|TTrDrvWrite|TTrTaskLow|TTrApi); 207 //ttr_init(TTrTask|TTrTest|TTrTestInfo|TTrDrvErase|TTrDrvWrite|TTrTaskLow|TTrApi);
208 208
209 tmp_int_level = TCD_Interrupt_Level; // Backup Int level 209 tmp_int_level = TCD_Interrupt_Level; // Backup Int level
210 TCD_Interrupt_Level = 0xC0; // The Interrups are not yet enabled... 210 TCD_Interrupt_Level = 0xC0; // The Interrups are not yet enabled...
211 #if FFS_IN_RAM
212 ffsdrv_ram_init();
213 #endif
211 ffs_init_status = ffs_initialize(); 214 ffs_init_status = ffs_initialize();
212 TCD_Interrupt_Level = tmp_int_level; // Restore Int level 215 TCD_Interrupt_Level = tmp_int_level; // Restore Int level
213 216
214 #if 0 217 #if 0
215 pcm_init(); // We have to call pcm_init() before G23 starts. 218 pcm_init(); // We have to call pcm_init() before G23 starts.
248 uint32 base; 251 uint32 base;
249 fd_t fdi; 252 fd_t fdi;
250 char *temp_path; 253 char *temp_path;
251 req_id_t temp_id; 254 req_id_t temp_id;
252 255
253 #if (BOARD == 34) 256 #if FFS_IN_RAM
254 // Non formatted FFS should be formatted 257 // Non formatted FFS should be formatted
255 // So we don't have to use PCTM to format it 258 // So we don't have to use PCTM to format it
256 if (fs.initerror == EFFS_NOFORMAT) 259 if (fs.initerror == EFFS_NOFORMAT)
257 { 260 {
258 ffs_format_nb("/", 0x2BAD, 0); 261 ffs_format_nb("/", 0x2BAD, 0);
259 } 262 }
260 263
261 ffs_InitRFCap(); 264 /* ffs_InitRFCap(); */
262 #endif 265 #endif
263 266
264 ttr(TTrTask, "ffs_init() %d" NL, ffs_init_status); 267 ttr(TTrTask, "ffs_init() %d" NL, ffs_init_status);
265 268
266 ffs_query(Q_FFS_REVISION, &revision); 269 ffs_query(Q_FFS_REVISION, &revision);