Skip to content

Commit

Permalink
gcc 13 fixes (#610)
Browse files Browse the repository at this point in the history
  • Loading branch information
WinterMute authored May 7, 2023
1 parent d219884 commit 8747689
Show file tree
Hide file tree
Showing 4 changed files with 8 additions and 8 deletions.
2 changes: 1 addition & 1 deletion nx/include/switch/services/btdrv.h
Original file line number Diff line number Diff line change
Expand Up @@ -1270,7 +1270,7 @@ Result btdrvUnregisterGattNotification(u32 connection_handle, bool primary_servi
* @param[in] size Output buffer size.
* @oaram[out] type Output BleEventType.
*/
Result btdrvGetLeHidEventInfo(void* buffer, size_t size, u32 *type);
Result btdrvGetLeHidEventInfo(void* buffer, size_t size, BtdrvBleEventType *type);

/**
* @brief RegisterBleHidEvent
Expand Down
10 changes: 5 additions & 5 deletions nx/include/switch/sf/cmif.h
Original file line number Diff line number Diff line change
Expand Up @@ -91,13 +91,13 @@ typedef struct CmifResponse {
Handle* move_handles;
} CmifResponse;

NX_CONSTEXPR void* cmifGetAlignedDataStart(u32* data_words, void* base)
NX_INLINE void* cmifGetAlignedDataStart(u32* data_words, void* base)
{
intptr_t data_start = ((u8*)data_words - (u8*)base + 15) &~ 15;
return (u8*)base + data_start;
}

NX_CONSTEXPR CmifRequest cmifMakeRequest(void* base, CmifRequestFormat fmt)
NX_INLINE CmifRequest cmifMakeRequest(void* base, CmifRequestFormat fmt)
{
// First of all, we need to figure out what size we need.
u32 actual_size = 16;
Expand Down Expand Up @@ -156,7 +156,7 @@ NX_CONSTEXPR CmifRequest cmifMakeRequest(void* base, CmifRequestFormat fmt)
return req;
}

NX_CONSTEXPR void* cmifMakeControlRequest(void* base, u32 request_id, u32 size)
NX_INLINE void* cmifMakeControlRequest(void* base, u32 request_id, u32 size)
{
u32 actual_size = 16 + sizeof(CmifInHeader) + size;
HipcRequest hipc = hipcMakeRequestInline(base,
Expand All @@ -173,7 +173,7 @@ NX_CONSTEXPR void* cmifMakeControlRequest(void* base, u32 request_id, u32 size)
return hdr+1;
}

NX_CONSTEXPR void cmifMakeCloseRequest(void* base, u32 object_id)
NX_INLINE void cmifMakeCloseRequest(void* base, u32 object_id)
{
if (object_id) {
HipcRequest hipc = hipcMakeRequestInline(base,
Expand Down Expand Up @@ -257,7 +257,7 @@ NX_CONSTEXPR void cmifRequestHandle(CmifRequest* req, Handle handle)
*req->hipc.copy_handles++ = handle;
}

NX_CONSTEXPR Result cmifParseResponse(CmifResponse* res, void* base, bool is_domain, u32 size)
NX_INLINE Result cmifParseResponse(CmifResponse* res, void* base, bool is_domain, u32 size)
{
HipcResponse hipc = hipcParseResponse(base);
void* start = cmifGetAlignedDataStart(hipc.data_words, base);
Expand Down
2 changes: 1 addition & 1 deletion nx/source/applets/web.c
Original file line number Diff line number Diff line change
Expand Up @@ -582,7 +582,7 @@ Result webConfigSetWebAudio(WebCommonConfig* config, bool flag) {
return _webConfigSetFlag(config, WebArgType_WebAudio, flag);
}

Result webConfigSetFooterFixedKind(WebCommonConfig* config, u32 kind) {
Result webConfigSetFooterFixedKind(WebCommonConfig* config, WebFooterFixedKind kind) {
WebShimKind shim = _webGetShimKind(config);
if (shim != WebShimKind_Offline && shim != WebShimKind_Web) return MAKERESULT(Module_Libnx, LibnxError_NotInitialized);
if (hosversionBefore(5,0,0)) return MAKERESULT(Module_Libnx, LibnxError_IncompatSysVer);
Expand Down
2 changes: 1 addition & 1 deletion nx/source/services/applet.c
Original file line number Diff line number Diff line change
Expand Up @@ -1722,7 +1722,7 @@ bool appletHolderCheckFinished(AppletHolder *h) {
return R_SUCCEEDED(eventWait(&h->StateChangedEvent, 0));
}

u32 appletHolderGetExitReason(AppletHolder *h) {
LibAppletExitReason appletHolderGetExitReason(AppletHolder *h) {
return h->exitreason;
}

Expand Down

0 comments on commit 8747689

Please sign in to comment.