Changeset 6 for trunk/tools/bootloader_tsar/boot_fat32.c
- Timestamp:
- Apr 26, 2017, 2:14:33 PM (8 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/tools/bootloader_tsar/boot_fat32.c
r1 r6 148 148 { 149 149 #if DEBUG_BOOT_FAT32 150 boot_printf("\n[BOOT ] %s: Enters at cycle %d\n",150 boot_printf("\n[BOOT INFO] %s enters at cycle %d\n", 151 151 __FUNCTION__ , boot_get_proctime() ); 152 152 #endif … … 163 163 164 164 #if DEBUG_BOOT_FAT32 165 boot_printf("\n[BOOT ] %s: FSI Sector loaded at cycle %d\n",165 boot_printf("\n[BOOT INFO] %s : FSI Sector loaded at cycle %d\n", 166 166 __FUNCTION__ , boot_get_proctime() ); 167 167 #endif … … 197 197 198 198 #if DEBUG_BOOT_FAT32 199 boot_printf("\n[BOOT ] %s: free_clusters_nr = %x / free_cluster_hint = %x\n",199 boot_printf("\n[BOOT INFO] %s : free_clusters_nr = %x / free_cluster_hint = %x\n", 200 200 __FUNCTION__ , boot_fat.free_clusters_nr , boot_fat.free_cluster_hint ); 201 201 #endif … … 430 430 431 431 #if DEBUG_BOOT_FAT32 432 boot_printf("\n[BOOT ] %s: returns <%s> from <%s> at cycle %d\n",432 boot_printf("\n[BOOT INFO] %s : returns <%s> from <%s> at cycle %d\n", 433 433 __FUNCTION__ , path_component , pathname , boot_get_proctime() ); 434 434 #endif … … 592 592 593 593 #if DEBUG_BOOT_FAT32 594 boot_printf("\n[BOOT ] %s: Enters for <%s> file at cycle %d\n",594 boot_printf("\n[BOOT INFO] %s enters for <%s> file at cycle %d\n", 595 595 __FUNCTION__ , pathname, boot_get_proctime()); 596 596 #endif … … 615 615 while ( found == 0 ) 616 616 { 617 618 boot_printf("\n!!! enter second while for <%s> path_comp\n", path_comp );619 620 617 cluster_lba = cluster_to_lba( parent_cluster ); 621 618 … … 646 643 if (ord == LAST_ENTRY) // no more entry in this directory 647 644 { 648 649 boot_printf("\n@@@ for <%s> component / offset = %d : last entry\n", path_comp , offset );650 651 645 found = 2; 652 646 } … … 654 648 else if (ord == FREE_ENTRY) // unused, check the next entry 655 649 { 656 657 boot_printf("\n@@@ for <%s> component / offset = %d : free entry\n", path_comp , offset );658 659 650 continue; 660 651 } … … 672 663 get_name_from_long(entry, buffer_lfn); 673 664 674 boot_printf("\n@@@ for <%s> component / offset = %d : LFN entry = %s\n",675 path_comp , offset , buffer_lfn );676 677 665 // Append this portion of the name to the full name buffer 678 666 boot_strcpy(name + 13 * (lfn_seq_order-1) , buffer_lfn); … … 685 673 { 686 674 if (lfn_seq_elem_nr == 0) get_name_from_short(entry, name); 687 688 boot_printf("\n@@@ for <%s> component / offset = %d : SFN entry = %s\n",689 path_comp , offset , name );690 675 691 676 // check if the full name is what we are looking for. … … 725 710 } // end second while for one component in pathname 726 711 727 boot_printf("\n### exit hwile fpr component <%s>\n", path_comp );728 729 712 // Check the result of this path component search. 730 713 if (found == 2) … … 755 738 756 739 #if DEBUG_BOOT_FAT32 757 boot_printf("\n[BOOT ] fat_file_search():"758 " <%s> file of size %x found at cluster %x at cycle %d\n",759 pathname, *file_size, *first_cluster, boot_get_proctime());740 boot_printf("\n[BOOT INFO] %s : <%s> file found at cycle %d\n" 741 " fat_cluster = %x / size = %x\n", 742 __FUNCTION__ , pathname , boot_get_proctime() , *first_cluster , *file_size ); 760 743 #endif 761 744 … … 771 754 int boot_fat32_init() 772 755 { 773 774 boot_printf("@@@ BEFORE_VALUE = %x\n", FAT_MAGIC_VALUE);775 776 756 // FAT32 initialization should be done only once 777 757 if (boot_fat.initialized == FAT_MAGIC_VALUE) … … 783 763 784 764 #if DEBUG_BOOT_FAT32 785 boot_printf("\n[BOOT ] %s: Enters at cycle %d\n",765 boot_printf("\n[BOOT INFO] %s: Enters at cycle %d\n", 786 766 __FUNCTION__ , boot_get_proctime() ); 787 767 #endif … … 799 779 800 780 #if DEBUG_BOOT_FAT32 801 boot_printf("\n[BOOT ] %s: Boot Sector loaded at cycle %d\n",781 boot_printf("\n[BOOT INFO] %s: Boot Sector loaded at cycle %d\n", 802 782 __FUNCTION__ , boot_get_proctime() ); 803 // unsigned char * data = boot_fat.block_buffer;804 // uint32_t byte;805 // for( byte = 0 ; byte < 16 ; byte++ ) boot_printf("%d : %x\n", byte , data[byte] );806 783 #endif 807 784 … … 865 842 boot_fat.initialized = FAT_MAGIC_VALUE; 866 843 867 boot_printf("@@@ AFTER_VALUE = %x\n", FAT_MAGIC_VALUE);868 869 fat32_desc_display();870 871 844 // Set information from FS Information Sector 872 845 if (set_fsi()) return -1; … … 878 851 #if DEBUG_BOOT_FAT32 879 852 fat32_desc_display(); 880 boot_printf("\n[BOOT ] boot_fat32_init(): FAT32 File System initialized at cycle %d\n",881 boot_get_proctime());853 boot_printf("\n[BOOT INFO] %s : FAT32 File System initialized at cycle %d\n", 854 __FUNCTION__ , boot_get_proctime() ); 882 855 #endif 883 856 … … 907 880 908 881 #if DEBUG_BOOT_FAT32 909 boot_printf("\n[BOOT ] %s: Enters for file <%s> at cycle %d\n",882 boot_printf("\n[BOOT INFO] %s enters for file <%s> at cycle %d\n", 910 883 __FUNCTION__ , pathname, boot_get_proctime() ); 911 884 #endif … … 973 946 974 947 #if DEBUG_BOOT_FAT32 975 boot_printf("\n[BOOT ] boot_fat32_load():"976 " File <%s> of size %x loaded at address %x at cycle %d\n",977 pathname, size, buff_addr, boot_get_proctime());948 boot_printf("\n[BOOT INFO] %s : file <%s> loaded at cycle %d\n" 949 " address = %x , size = %x\n", 950 __FUNCTION__ , pathname , boot_get_proctime() , buff_addr , size ); 978 951 #endif 979 952
Note: See TracChangeset
for help on using the changeset viewer.