diff options
| author | Tharo <tharo10600@gmail.com> | 2026-09-24 05:29:19 +0100 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2026-09-24 06:29:19 +0200 |
| commit | 1bef952ff61a6dd1945c7887c1babd94efe95f72 (patch) | |
| tree | 7436c39fce905685f6d2115d487be3303ceda09c /src/libultra/io | |
| parent | 39070bb9dd5bba8b60363b81ef0b36f4590e68f4 (diff) | |
* UNUSED attribute for variables and parameters in static segments and for all stack padding variables
* No more unused variable warnings
* Make pad variable names consistent
* Small cleanup
* Macro-ify stack padding
* Use stack padding for more variables not previously named pad
* Format
* Check unused parameter on gamestate overlays and pause menu
Co-authored-by: Dragorn421 <Dragorn421@users.noreply.github.com>
* Merge 2x u8 stack pads into 1x s16 stack pad in en_ik
* Remove UNUSED from function prototypes
* Suggested changes
Co-authored-by: Dragorn421 <Dragorn421@users.noreply.github.com>
* More unused variables
* Fix merge, updated for new versions
* Format
* questionable UNUSED and STACK_PAD more usage
* format
* format
* one more STACK_PADS in z_kaleido_map.c
---------
Co-authored-by: Dragorn421 <Dragorn421@users.noreply.github.com>
Diffstat (limited to 'src/libultra/io')
| -rw-r--r-- | src/libultra/io/motor.c | 7 | ||||
| -rw-r--r-- | src/libultra/io/sptask.c | 3 |
2 files changed, 7 insertions, 3 deletions
diff --git a/src/libultra/io/motor.c b/src/libultra/io/motor.c index 78ce191b7..4d38714ba 100644 --- a/src/libultra/io/motor.c +++ b/src/libultra/io/motor.c @@ -1,4 +1,5 @@ #include "ultra64.h" +#include "attributes.h" #define MOTOR_ID 0x80 @@ -6,8 +7,8 @@ OSPifRam __MotorDataBuf[MAXCONTROLLERS]; #endif -s32 __osMotorAccess(OSPfs* pfs, s32 vibrate) { #ifndef BBPLAYER +s32 __osMotorAccess(OSPfs* pfs, s32 vibrate) { s32 i; s32 ret; u8* ptr = (u8*)&__MotorDataBuf[pfs->channel]; @@ -47,6 +48,7 @@ s32 __osMotorAccess(OSPfs* pfs, s32 vibrate) { return ret; #else +s32 __osMotorAccess(UNUSED OSPfs* pfs, UNUSED s32 vibrate) { return PFS_ERR_INVALID; #endif } @@ -76,8 +78,8 @@ void _MakeMotorData(s32 channel, OSPifRam* mdata) { } #endif -s32 osMotorInit(OSMesgQueue* ctrlrqueue, OSPfs* pfs, s32 channel) { #ifndef BBPLAYER +s32 osMotorInit(OSMesgQueue* ctrlrqueue, OSPfs* pfs, s32 channel) { s32 ret; u8 temp[BLOCKSIZE]; @@ -133,6 +135,7 @@ s32 osMotorInit(OSMesgQueue* ctrlrqueue, OSPfs* pfs, s32 channel) { pfs->status = PFS_MOTOR_INITIALIZED; return 0; // "Recognized rumble pak" #else +s32 osMotorInit(UNUSED OSMesgQueue* ctrlrqueue, UNUSED OSPfs* pfs, UNUSED s32 channel) { return PFS_ERR_DEVICE; #endif } diff --git a/src/libultra/io/sptask.c b/src/libultra/io/sptask.c index b728146bd..a976df1ea 100644 --- a/src/libultra/io/sptask.c +++ b/src/libultra/io/sptask.c @@ -1,4 +1,5 @@ #include "ultra64.h" +#include "attributes.h" #define _osVirtualToPhysical(ptr) \ if (ptr != NULL) { \ @@ -52,7 +53,7 @@ void osSpTaskLoad(OSTask* intp) { } } -void osSpTaskStartGo(OSTask* tp) { +void osSpTaskStartGo(UNUSED OSTask* tp) { while (__osSpDeviceBusy()) { ; } |
