enable fat readahead cache, fixed FAT filenames & history

This commit is contained in:
ekeeke31 2008-12-10 21:29:42 +00:00
parent 8ea80d38a5
commit 822de1bd3f
4 changed files with 12 additions and 5 deletions

View File

@ -1,7 +1,7 @@
Genesis Plus for Gamecube Genesis Plus for Gamecube
------------------------------ ------------------------------
08/12/2008: 11/12/2008:
----------- -----------
[Genesis] [Genesis]
- YM2612 bugfixes (MAME core): - YM2612 bugfixes (MAME core):

View File

@ -38,7 +38,7 @@ void config_load()
char pathname[MAXPATHLEN]; char pathname[MAXPATHLEN];
/* open configuration file */ /* open configuration file */
sprintf (pathname, "%s/genplus.ini", DEFAULT_PATH); sprintf (pathname, "%s/config.ini", DEFAULT_PATH);
FILE *fp = fopen(pathname, "rb"); FILE *fp = fopen(pathname, "rb");
if (fp == NULL) return; if (fp == NULL) return;

View File

@ -230,8 +230,7 @@ int FAT_Open(int type)
/* reset flags */ /* reset flags */
useFAT = 1; useFAT = 1;
useHistory = 0;
/* FAT header */ /* FAT header */
#ifdef HW_RVL #ifdef HW_RVL
if (type == TYPE_SD) sprintf (root, "sd:"); if (type == TYPE_SD) sprintf (root, "sd:");
@ -248,6 +247,7 @@ int FAT_Open(int type)
/* update filelist */ /* update filelist */
if (haveFATdir == 0) if (haveFATdir == 0)
{ {
useHistory = 0;
if (type == TYPE_RECENT) if (type == TYPE_RECENT)
{ {
/* fetch history list */ /* fetch history list */
@ -275,7 +275,7 @@ int FAT_Open(int type)
else else
{ {
/* reset root directory */ /* reset root directory */
sprintf (fatdir, "%s%s/roms", root, DEFAULT_PATH); sprintf (fatdir, "%s%s/roms/", root, DEFAULT_PATH);
/* if directory doesn't exist, use root as default */ /* if directory doesn't exist, use root as default */
DIR_ITER *dir = diropen(fatdir); DIR_ITER *dir = diropen(fatdir);

View File

@ -153,6 +153,13 @@ int main (int argc, char *argv[])
if (fatInitDefault() == true) if (fatInitDefault() == true)
{ {
fat_enabled = 1; fat_enabled = 1;
#ifdef HW_RVL
fatEnableReadAhead ("sd", 6, 64);
fatEnableReadAhead ("usb", 6, 64);
#else
fatEnableReadAhead ("carda", 6, 64);
fatEnableReadAhead ("cardb", 6, 64);
#endif
} }
/* Default Config */ /* Default Config */