Search
lxdream.org :: lxdream :: r433:a4f61551d79d
lxdream 0.9.1
released Jun 29
Download Now
changeset433:a4f61551d79d
parent432:0b761ef2dbfd
child434:8af49a412d92
authornkeynes
dateTue Oct 09 08:48:28 2007 +0000 (12 years ago)
Fix compilation warnings
src/gdrom/gdrom.c
src/gdrom/gdrom.h
src/pvr2/pvr2.c
1.1 --- a/src/gdrom/gdrom.c Tue Oct 09 08:46:21 2007 +0000
1.2 +++ b/src/gdrom/gdrom.c Tue Oct 09 08:48:28 2007 +0000
1.3 @@ -1,6 +1,6 @@
1.4
1.5 /**
1.6 - * $Id: gdrom.c,v 1.13 2007-10-06 08:58:00 nkeynes Exp $
1.7 + * $Id: gdrom.c,v 1.14 2007-10-09 08:45:00 nkeynes Exp $
1.8 *
1.9 * GD-Rom access functions.
1.10 *
1.11 @@ -93,12 +93,14 @@
1.12 gdrom_image_dump_info( disc );
1.13 }
1.14
1.15 -gdrom_disc_t gdrom_mount_image( const gchar *filename )
1.16 +gboolean gdrom_mount_image( const gchar *filename )
1.17 {
1.18 gdrom_disc_t disc = gdrom_image_open(filename);
1.19 - if( disc != NULL )
1.20 + if( disc != NULL ) {
1.21 gdrom_mount_disc( disc );
1.22 - return disc;
1.23 + return TRUE;
1.24 + }
1.25 + return FALSE;
1.26 }
1.27
1.28 void gdrom_unmount_disc( )
2.1 --- a/src/gdrom/gdrom.h Tue Oct 09 08:46:21 2007 +0000
2.2 +++ b/src/gdrom/gdrom.h Tue Oct 09 08:48:28 2007 +0000
2.3 @@ -1,5 +1,5 @@
2.4 /**
2.5 - * $Id: gdrom.h,v 1.11 2007-10-06 08:58:00 nkeynes Exp $
2.6 + * $Id: gdrom.h,v 1.12 2007-10-09 08:45:00 nkeynes Exp $
2.7 *
2.8 * This file defines the structures and functions used by the GD-Rom
2.9 * disc driver. (ie, the modules that supply a CD image to be used by the
2.10 @@ -124,7 +124,7 @@
2.11 /**
2.12 * Begin playing audio from the given lba address on the disc.
2.13 */
2.14 - gdrom_error_t (*play_audio)(struct gdrom_disc *disc, uint32_t lba);
2.15 + gdrom_error_t (*play_audio)(struct gdrom_disc *disc, uint32_t lba, uint32_t endlba);
2.16
2.17 /**
2.18 * Executed once per time slice to perform house-keeping operations
2.19 @@ -198,8 +198,9 @@
2.20
2.21 /**
2.22 * Shortcut to open and mount an image file
2.23 + * @return true on success
2.24 */
2.25 -gdrom_disc_t gdrom_mount_image( const gchar *filename );
2.26 +gboolean gdrom_mount_image( const gchar *filename );
2.27
2.28 void gdrom_mount_disc( gdrom_disc_t disc );
2.29
3.1 --- a/src/pvr2/pvr2.c Tue Oct 09 08:46:21 2007 +0000
3.2 +++ b/src/pvr2/pvr2.c Tue Oct 09 08:48:28 2007 +0000
3.3 @@ -1,5 +1,5 @@
3.4 /**
3.5 - * $Id: pvr2.c,v 1.45 2007-09-11 01:05:05 nkeynes Exp $
3.6 + * $Id: pvr2.c,v 1.46 2007-10-09 08:48:28 nkeynes Exp $
3.7 *
3.8 * PVR2 (Video) Core module implementation and MMIO registers.
3.9 *
3.10 @@ -688,7 +688,7 @@
3.11
3.12 void mmio_region_PVR2TA_write( uint32_t reg, uint32_t val )
3.13 {
3.14 - pvr2_ta_write( (char *)&val, sizeof(uint32_t) );
3.15 + pvr2_ta_write( (unsigned char *)&val, sizeof(uint32_t) );
3.16 }
3.17
3.18 /**
3.19 @@ -728,7 +728,7 @@
3.20 uint32_t render_mode = MMIO_READ( PVR2, RENDER_MODE );
3.21 uint32_t render_scale = MMIO_READ( PVR2, RENDER_SCALER );
3.22 uint32_t render_stride = MMIO_READ( PVR2, RENDER_SIZE ) << 3;
3.23 - gboolean render_to_tex;
3.24 +
3.25 if( render_addr & 0x01000000 ) { /* vram64 */
3.26 render_addr = (render_addr & 0x00FFFFFF) + PVR2_RAM_BASE_INT;
3.27 } else { /* vram32 */
3.28 @@ -757,7 +757,7 @@
3.29 width*height ) {
3.30 pvr2_render_buffer_copy_to_sh4( render_buffers[i] );
3.31 }
3.32 - render_buffers[i]->address == -1;
3.33 + render_buffers[i]->address = -1;
3.34 }
3.35 }
3.36
3.37 @@ -812,7 +812,6 @@
3.38 address = address & 0x1FFFFFFF;
3.39 for( i=0; i<render_buffer_count; i++ ) {
3.40 uint32_t bufaddr = render_buffers[i]->address;
3.41 - uint32_t size = render_buffers[i]->size;
3.42 if( bufaddr != -1 && bufaddr <= address &&
3.43 (bufaddr + render_buffers[i]->size) > address ) {
3.44 if( !render_buffers[i]->flushed ) {
.