Changeset 222
- Timestamp:
- Nov 12, 2012, 6:11:03 PM (12 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
soft/giet_vm/xml/xml_parser.c
r218 r222 1208 1208 { 1209 1209 #if XML_PARSER_DEBUG 1210 printf(" name = %s\n", str);1210 printf(" name = %s\n", str); 1211 1211 #endif 1212 1212 strncpy(coproc[coproc_index]->name, str, 31); … … 2090 2090 void def_int_write(int fdout, char* def, int num) 2091 2091 { 2092 char 2092 char buf[64]; 2093 2093 sprintf(buf, "#define\t %s %d\n", def, num); 2094 2094 file_write(fdout, buf); … … 2098 2098 void def_hex_write(int fdout, char* def, int num) 2099 2099 { 2100 char 2100 char buf[64]; 2101 2101 sprintf(buf, "#define\t %s 0x%x\n", def, num); 2102 2102 file_write(fdout, buf); … … 2115 2115 def_int_write(fdout, "CLUSTER_Y" , cluster_y); 2116 2116 def_int_write(fdout, "NB_CLUSTERS" , cluster_index); 2117 def_hex_write(fdout, "CLUSTER_SIZE" , ( ((unsigned long)1) << 32)/cluster_index);2117 def_hex_write(fdout, "CLUSTER_SIZE" , (((unsigned long long) 1) << 32) / cluster_index); 2118 2118 def_int_write(fdout, "NB_PROCS_MAX" , nb_proc_max); 2119 2119 def_int_write(fdout, "NB_TIMERS_MAX" , nb_timer_channel_max); … … 2143 2143 2144 2144 /////////////////////////////////////// 2145 void genLd ( const char* file_path)2145 void genLd (const char * file_path) 2146 2146 /////////////////////////////////////// 2147 2147 { … … 2154 2154 ld_write(fdout, "seg_boot_code_base" , boot_code_base); 2155 2155 ld_write(fdout, "seg_boot_stack_base" , boot_stack_base); 2156 ld_write(fdout, "seg_mapping_base" , boot_mapping_base);2156 ld_write(fdout, "seg_mapping_base" , boot_mapping_base); 2157 2157 2158 2158 //kernel 2159 ld_write(fdout, "\nseg_kernel_code_base" 2159 ld_write(fdout, "\nseg_kernel_code_base" , kernel_code_base); 2160 2160 ld_write(fdout, "seg_kernel_data_base" , kernel_data_base); 2161 2161 ld_write(fdout, "seg_kernel_uncdata_base" , kernel_uncdata_base); … … 2163 2163 2164 2164 //peripherals 2165 ld_write(fdout, "\nseg_fbf_base" 2166 ld_write(fdout, "seg_icu_base" , icu_base_offset);2167 ld_write(fdout, "seg_ioc_base" , ioc_base_offset);2168 ld_write(fdout, "seg_nic_base" , nic_base_offset);2169 ld_write(fdout, "seg_tty_base" , tty_base_offset);2170 ld_write(fdout, "seg_dma_base" , dma_base_offset);2171 ld_write(fdout, "seg_tim_base" , tim_base_offset);2172 ld_write(fdout, "seg_gcd_base" , gcd_base_offset);2173 ld_write(fdout, "seg_iob_base" , iob_base_offset);2165 ld_write(fdout, "\nseg_fbf_base", fbf_base_offset); 2166 ld_write(fdout, "seg_icu_base" , icu_base_offset); 2167 ld_write(fdout, "seg_ioc_base" , ioc_base_offset); 2168 ld_write(fdout, "seg_nic_base" , nic_base_offset); 2169 ld_write(fdout, "seg_tty_base" , tty_base_offset); 2170 ld_write(fdout, "seg_dma_base" , dma_base_offset); 2171 ld_write(fdout, "seg_tim_base" , tim_base_offset); 2172 ld_write(fdout, "seg_gcd_base" , gcd_base_offset); 2173 ld_write(fdout, "seg_iob_base" , iob_base_offset); 2174 2174 2175 2175 close(fdout); 2176 2176 } 2177 2177 2178 char * buildPath(const char* path, const char*name)2179 { 2180 char * res = calloc(strlen(path) + strlen(name) + 1, 1);2178 char * buildPath(const char * path, const char * name) 2179 { 2180 char * res = calloc(strlen(path) + strlen(name) + 1, 1); 2181 2181 strcat(res, path); 2182 2182 strcat(res, "/"); … … 2186 2186 2187 2187 ///////////////////////////////////// 2188 int main ( int argc, char* argv[])2188 int main(int argc, char * argv[]) 2189 2189 ///////////////////////////////////// 2190 2190 { … … 2250 2250 return 0; 2251 2251 } // end main() 2252 2253 2254 2255
Note: See TracChangeset
for help on using the changeset viewer.