mirror of
https://github.com/Rockbox/rockbox.git
synced 2025-12-09 13:15:18 -05:00
Added cluster size to the disk debug screen
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@4469 a1c6a512-1295-4272-9138-f99709370657
This commit is contained in:
parent
d4241b0f62
commit
ef1698e648
3 changed files with 13 additions and 1 deletions
|
|
@ -1253,7 +1253,7 @@ static bool dbg_disk_info(void)
|
||||||
bool done = false;
|
bool done = false;
|
||||||
int i;
|
int i;
|
||||||
int page = 0;
|
int page = 0;
|
||||||
const int max_page = 10;
|
const int max_page = 11;
|
||||||
unsigned short* identify_info = ata_get_identify();
|
unsigned short* identify_info = ata_get_identify();
|
||||||
bool timing_info_present = false;
|
bool timing_info_present = false;
|
||||||
char pio3[2], pio4[2];
|
char pio3[2], pio4[2];
|
||||||
|
|
@ -1374,6 +1374,12 @@ static bool dbg_disk_info(void)
|
||||||
lcd_puts(0, y++, "No timing info");
|
lcd_puts(0, y++, "No timing info");
|
||||||
}
|
}
|
||||||
break;
|
break;
|
||||||
|
|
||||||
|
case 11:
|
||||||
|
lcd_puts(0, y++, "Cluster size");
|
||||||
|
snprintf(buf, 128, "%d bytes", fat_get_cluster_size());
|
||||||
|
lcd_puts(0, y++, buf);
|
||||||
|
break;
|
||||||
}
|
}
|
||||||
lcd_update();
|
lcd_update();
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -1989,3 +1989,8 @@ int fat_getnext(struct fat_dir *dir, struct fat_direntry *entry)
|
||||||
}
|
}
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
int fat_get_cluster_size(void)
|
||||||
|
{
|
||||||
|
return fat_bpb.bpb_secperclus * SECTOR_SIZE;
|
||||||
|
}
|
||||||
|
|
|
||||||
|
|
@ -94,5 +94,6 @@ extern int fat_rename(struct fat_file* file,
|
||||||
|
|
||||||
extern int fat_opendir(struct fat_dir *ent, unsigned int currdir);
|
extern int fat_opendir(struct fat_dir *ent, unsigned int currdir);
|
||||||
extern int fat_getnext(struct fat_dir *ent, struct fat_direntry *entry);
|
extern int fat_getnext(struct fat_dir *ent, struct fat_direntry *entry);
|
||||||
|
extern int fat_get_cluster_size(void);
|
||||||
|
|
||||||
#endif
|
#endif
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue