moved flushDataCache function from ds-loader.cpp to elf-loader.cpp and moved arm-relocations from ds-loader.cpp to arm-relocs.cpp; deleted ds-loader.cpp
svn-id: r51289
This commit is contained in:
parent
95f66e6fb2
commit
4e530debd2
3 changed files with 17 additions and 10 deletions
|
@ -296,7 +296,7 @@ PORT_OBJS := $(portdir)/source/blitters_arm.o $(portdir)/source/cdaudio.o $(port
|
||||||
$(portdir)/source/dsoptions.o $(portdir)/source/keys.o $(portdir)/source/wordcompletion.o\
|
$(portdir)/source/dsoptions.o $(portdir)/source/keys.o $(portdir)/source/wordcompletion.o\
|
||||||
$(portdir)/source/interrupt.o\
|
$(portdir)/source/interrupt.o\
|
||||||
$(srcdir)/backends/plugins/elf-loader.o\
|
$(srcdir)/backends/plugins/elf-loader.o\
|
||||||
$(srcdir)/backends/plugins/ds/ds-loader.o
|
$(srcdir)/backends/plugins/arm-relocs.o
|
||||||
|
|
||||||
ifdef USE_PROFILER
|
ifdef USE_PROFILER
|
||||||
PORT_OBJS += $(portdir)/source/profiler/cyg-profile.o
|
PORT_OBJS += $(portdir)/source/profiler/cyg-profile.o
|
||||||
|
|
|
@ -24,7 +24,7 @@
|
||||||
*/
|
*/
|
||||||
|
|
||||||
#include "backends/fs/ds/ds-fs.h"
|
#include "backends/fs/ds/ds-fs.h"
|
||||||
#include "../elf-loader.h"
|
#include "elf-loader.h"
|
||||||
#include "dsmain.h"
|
#include "dsmain.h"
|
||||||
|
|
||||||
#define __DEBUG_PLUGINS__
|
#define __DEBUG_PLUGINS__
|
||||||
|
@ -37,13 +37,6 @@
|
||||||
|
|
||||||
#define seterror(x,...) consolePrintf(x, ## __VA_ARGS__)
|
#define seterror(x,...) consolePrintf(x, ## __VA_ARGS__)
|
||||||
|
|
||||||
/**
|
|
||||||
* Flushes the data cache.
|
|
||||||
*/
|
|
||||||
void flushDataCache() {
|
|
||||||
DC_FlushAll();
|
|
||||||
}
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Follow the instruction of a relocation section.
|
* Follow the instruction of a relocation section.
|
||||||
*
|
*
|
||||||
|
@ -52,7 +45,7 @@ void flushDataCache() {
|
||||||
* @param size Size of relocation section
|
* @param size Size of relocation section
|
||||||
*
|
*
|
||||||
*/
|
*/
|
||||||
bool dlRelocate(Common::SeekableReadStream* DLFile, unsigned long offset, unsigned long size, void *relSegment) {
|
bool DLObject::relocate(Common::SeekableReadStream* DLFile, unsigned long offset, unsigned long size, void *relSegment) {
|
||||||
Elf32_Rel *rel = NULL; //relocation entry
|
Elf32_Rel *rel = NULL; //relocation entry
|
||||||
|
|
||||||
// Allocate memory for relocation table
|
// Allocate memory for relocation table
|
|
@ -48,6 +48,20 @@
|
||||||
|
|
||||||
#define seterror(x,...) printf(x, ## __VA_ARGS__)
|
#define seterror(x,...) printf(x, ## __VA_ARGS__)
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Flushes the data cache.
|
||||||
|
*/
|
||||||
|
void flushDataCache() {
|
||||||
|
#ifdef __DS__
|
||||||
|
DC_FlushAll();
|
||||||
|
#endif
|
||||||
|
#ifdef __PLAYSTATION2__
|
||||||
|
FlushCache(0);
|
||||||
|
FlushCache(2);
|
||||||
|
#endif
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
// Expel the symbol table from memory
|
// Expel the symbol table from memory
|
||||||
void DLObject::discard_symtab() {
|
void DLObject::discard_symtab() {
|
||||||
free(_symtab);
|
free(_symtab);
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue