From: kosmirror <kos...@us...> - 2025-05-22 13:53:00
|
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 4d8a1165d929359cca0a6c91f9538cf0e71064f8 (commit) via 67032d5dd373b4614a16bf82814e7be11aa64240 (commit) from 79f8d37af06e725cfe5927936240a36b87cba274 (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 4d8a1165d929359cca0a6c91f9538cf0e71064f8 Author: kapodamy <168...@us...> Date: Mon May 5 19:28:21 2025 -0300 Fix build warnings in netcfg, snd_sfxmgr, vqenc * update netcfg.c: add type cast. * update snd_sfxmgr.c: change type int to uint32_t. * update vqenc.c: use "PRIxPTR" print formatter. commit 67032d5dd373b4614a16bf82814e7be11aa64240 Author: kapodamy <168...@us...> Date: Sat Apr 19 21:54:47 2025 -0300 Update irq.h and g2bus.h files change param type of __irq_scoped_cleanup() function change g2_ctx irq_state field type (again) ----------------------------------------------------------------------- Summary of changes: addons/libkosutils/netcfg.c | 2 +- kernel/arch/dreamcast/include/arch/irq.h | 4 ++-- kernel/arch/dreamcast/include/dc/g2bus.h | 2 +- kernel/arch/dreamcast/sound/snd_sfxmgr.c | 4 ++-- utils/vqenc/vqenc.c | 3 ++- 5 files changed, 8 insertions(+), 7 deletions(-) diff --git a/addons/libkosutils/netcfg.c b/addons/libkosutils/netcfg.c index 39a78613..3d5cd963 100644 --- a/addons/libkosutils/netcfg.c +++ b/addons/libkosutils/netcfg.c @@ -44,7 +44,7 @@ void netcfg_vmuify(const char *filename_in, const char *filename_out) { pkg.icon_cnt = 1; pkg.icon_anim_speed = 1; memcpy(&pkg.icon_pal[0], netcfg_icon, 32); - pkg.icon_data = netcfg_icon + 32; + pkg.icon_data = (uint8_t *)(netcfg_icon + 32); pkg.eyecatch_type = VMUPKG_EC_NONE; pkg.data_len = fs_total(fd); pkg.data = buf; diff --git a/kernel/arch/dreamcast/include/arch/irq.h b/kernel/arch/dreamcast/include/arch/irq.h index fc5c53e8..3fcb4752 100644 --- a/kernel/arch/dreamcast/include/arch/irq.h +++ b/kernel/arch/dreamcast/include/arch/irq.h @@ -510,12 +510,12 @@ int irq_init(void); */ void irq_shutdown(void); -static inline void __irq_scoped_cleanup(int *state) { +static inline void __irq_scoped_cleanup(irq_mask_t *state) { irq_restore(*state); } #define ___irq_disable_scoped(l) \ - int __scoped_irq_##l __attribute__((cleanup(__irq_scoped_cleanup))) = irq_disable() + irq_mask_t __scoped_irq_##l __attribute__((cleanup(__irq_scoped_cleanup))) = irq_disable() #define __irq_disable_scoped(l) ___irq_disable_scoped(l) /** \endcond */ diff --git a/kernel/arch/dreamcast/include/dc/g2bus.h b/kernel/arch/dreamcast/include/dc/g2bus.h index 8b449aab..248b5a1c 100644 --- a/kernel/arch/dreamcast/include/dc/g2bus.h +++ b/kernel/arch/dreamcast/include/dc/g2bus.h @@ -140,7 +140,7 @@ void g2_dma_shutdown(void); is used in with g2_lock() and g2_unlock(). */ typedef struct { - int irq_state; /** \brief IRQ state when entering a G2 critical block */ + irq_mask_t irq_state; /** \brief IRQ state when entering a G2 critical block */ } g2_ctx_t; /* Internal constants to access suspend registers for G2 DMA. They are not meant for diff --git a/kernel/arch/dreamcast/sound/snd_sfxmgr.c b/kernel/arch/dreamcast/sound/snd_sfxmgr.c index 31f974a9..6fa406d2 100644 --- a/kernel/arch/dreamcast/sound/snd_sfxmgr.c +++ b/kernel/arch/dreamcast/sound/snd_sfxmgr.c @@ -771,7 +771,7 @@ int snd_sfx_play_ex(sfx_play_data_t *data) { } } - int size; + uint32_t size; snd_effect_t *t = (snd_effect_t *)data->idx; AICA_CMDSTR_CHANNEL(tmp, cmd, chan); @@ -790,7 +790,7 @@ int snd_sfx_play_ex(sfx_play_data_t *data) { chan->loop = data->loop; chan->loopstart = data->loopstart; chan->loopend = data->loopend ? data->loopend : size; - chan->freq = data->freq > 0 ? data->freq : t->rate; + chan->freq = data->freq > 0 ? (uint32_t)data->freq : t->rate; chan->vol = data->vol; if(!t->stereo) { diff --git a/utils/vqenc/vqenc.c b/utils/vqenc/vqenc.c index 5924da41..4f487ae9 100644 --- a/utils/vqenc/vqenc.c +++ b/utils/vqenc/vqenc.c @@ -18,6 +18,7 @@ #include <math.h> #include <unistd.h> #include <errno.h> +#include <inttypes.h> #include "get_image.h" #include "vq_internal.h" #include "vq_types.h" @@ -572,7 +573,7 @@ static fquad_t *create_downscaled_map(int res, fquad_t *oneup) { fquad_t *q, *larger, tmp; if(use_debug) { - printf("create_downscaled_map(%d %lx)\n", res, (uintptr_t)oneup); + printf("create_downscaled_map(%d %" PRIxPTR ")\n", res, (uintptr_t)oneup); } /* each quad in the lower resolution is an average of hooks/post-receive -- A pseudo Operating System for the Dreamcast. |