-
-
Notifications
You must be signed in to change notification settings - Fork 93
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Move some patches code to common.h and fix GCC 6.2 issues (need -O1…
… now to avoid issues)
- Loading branch information
Showing
11 changed files
with
161 additions
and
118 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,34 @@ | ||
#ifndef _COMMON_H_ | ||
|
||
typedef volatile unsigned int vu32; | ||
typedef unsigned int u32; | ||
typedef int s32; | ||
typedef unsigned short u16; | ||
typedef signed short s16; | ||
typedef unsigned char u8; | ||
|
||
#define mftb(rval) ({unsigned long u; do { \ | ||
asm volatile ("mftbu %0" : "=r" (u)); \ | ||
asm volatile ("mftb %0" : "=r" ((rval)->l)); \ | ||
asm volatile ("mftbu %0" : "=r" ((rval)->u)); \ | ||
} while(u != ((rval)->u)); }) | ||
|
||
typedef struct { | ||
unsigned long l, u; | ||
} tb_t; | ||
|
||
#define TB_CLOCK 40500000 | ||
|
||
void do_read(void* dst, u32 len, u32 offset, u32 sector); | ||
void device_frag_read(void* dst, u32 len, u32 offset); | ||
void dcache_flush_icache_inv(void* dst, u32 len); | ||
int ADPdecodebuffer(unsigned char *input, short *outl, short * outr, long *histl1, long *histl2, long *histr1, long *histr2); | ||
void StreamStartStream(u32 CurrentStart, u32 CurrentSize); | ||
void StreamEndStream(void); | ||
u32 process_queue(void* dst, u32 len, u32 offset, int readComplete); | ||
unsigned long tb_diff_usec(tb_t* end, tb_t* start); | ||
|
||
int usb_sendbuffer_safe(const void *buffer,int size); | ||
|
||
|
||
#endif |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.