From: Christian G. <sa...@us...> - 2013-05-15 07:59:37
|
This is an automated email from the git hooks/post-receive script. It was generated because a ref change was pushed to the repository containing the project "A pseudo Operating System for the Dreamcast.". The branch, master has been updated via 98106fee8d59142513f179b1536b4bdbb77c4a59 (commit) via d793fac0b2d160ba5e9b4501d5c89a13c12c740d (commit) from fb653a8a3c230e08de16c5cffabd139317ec830b (commit) Those revisions listed above that are new to this repository have not appeared on any other notification email; so we list those revisions in full, below. - Log ----------------------------------------------------------------- commit 98106fee8d59142513f179b1536b4bdbb77c4a59 Author: Christian Groessler <ch...@gr...> Date: Wed May 15 09:58:34 2013 +0200 Add -N to linker switches in order not to pad .data section to a 32K boundary. commit d793fac0b2d160ba5e9b4501d5c89a13c12c740d Author: Christian Groessler <ch...@gr...> Date: Wed May 15 09:56:31 2013 +0200 New compiler (gcc 4.7.0) optimizes out the the delay loop in aica_get_pos(). Add a inline "nop" to prevent this. ----------------------------------------------------------------------- Summary of changes: kernel/arch/dreamcast/sound/arm/Makefile | 2 +- kernel/arch/dreamcast/sound/arm/aica.c | 3 ++- 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/kernel/arch/dreamcast/sound/arm/Makefile b/kernel/arch/dreamcast/sound/arm/Makefile index b77d6da..eab400e 100644 --- a/kernel/arch/dreamcast/sound/arm/Makefile +++ b/kernel/arch/dreamcast/sound/arm/Makefile @@ -11,7 +11,7 @@ stream.drv: prog.elf $(DC_ARM_OBJCOPY) -O binary prog.elf stream.drv prog.elf: crt0.o main.o aica.o - $(DC_ARM_CC) -Wl,-Ttext,0x00000000,-Map,prog.map -nostartfiles -nostdlib -e reset -o prog.elf crt0.o main.o aica.o -lgcc + $(DC_ARM_CC) -Wl,-Ttext,0x00000000,-Map,prog.map,-N -nostartfiles -nostdlib -e reset -o prog.elf crt0.o main.o aica.o -lgcc %.o: %.c $(DC_ARM_CC) $(DC_ARM_CFLAGS) $(DC_ARM_INCS) -c $< -o $@ diff --git a/kernel/arch/dreamcast/sound/arm/aica.c b/kernel/arch/dreamcast/sound/arm/aica.c index 8eaf8db..84428ac 100644 --- a/kernel/arch/dreamcast/sound/arm/aica.c +++ b/kernel/arch/dreamcast/sound/arm/aica.c @@ -221,7 +221,8 @@ int aica_get_pos(int ch) { SNDREG8(0x280d) = ch; /* Wait a while */ - for(i = 0; i < 20; i++); + for(i = 0; i < 20; i++) + __asm__ volatile ("nop"); /* Prevent loop from being optimized out */ /* Update position counters */ chans[ch].pos = SNDREG32(0x2814) & 0xffff; hooks/post-receive -- A pseudo Operating System for the Dreamcast. |