diff --git a/nx/include/switch/services/hid.h b/nx/include/switch/services/hid.h index ab683294..cf28c667 100644 --- a/nx/include/switch/services/hid.h +++ b/nx/include/switch/services/hid.h @@ -2164,10 +2164,10 @@ Result hidResetPalmaStep(HidPalmaConnectionHandle handle); * @note See \ref hidGetPalmaOperationInfo. * @note Only available on [5.0.0+]. * @param[in] handle \ref HidPalmaConnectionHandle - * @param[in] inval0 First input value. This must be within the size of \ref HidPalmaApplicationSectionAccessBuffer. - * @param[in] inval1 Second input value. + * @param[in] inval0 First input value. + * @param[in] size This must be within the size of \ref HidPalmaApplicationSectionAccessBuffer. */ -Result hidReadPalmaApplicationSection(HidPalmaConnectionHandle handle, s32 inval0, u64 inval1); +Result hidReadPalmaApplicationSection(HidPalmaConnectionHandle handle, s32 inval0, u64 size); /** * @brief WritePalmaApplicationSection @@ -2178,7 +2178,7 @@ Result hidReadPalmaApplicationSection(HidPalmaConnectionHandle handle, s32 inval * @param[in] size Size of the data in \ref HidPalmaApplicationSectionAccessBuffer. * @param[in] buf \ref HidPalmaApplicationSectionAccessBuffer */ -Result hidWritePalmaApplicationSection(HidPalmaConnectionHandle handle, s32 inval0, u64 inval1, const HidPalmaApplicationSectionAccessBuffer *buf); +Result hidWritePalmaApplicationSection(HidPalmaConnectionHandle handle, s32 inval0, u64 size, const HidPalmaApplicationSectionAccessBuffer *buf); /** * @brief ReadPalmaUniqueCode diff --git a/nx/source/services/hid.c b/nx/source/services/hid.c index 4fee04d1..e99fc168 100644 --- a/nx/source/services/hid.c +++ b/nx/source/services/hid.c @@ -2118,18 +2118,18 @@ Result hidResetPalmaStep(HidPalmaConnectionHandle handle) { return _hidCmdInU64NoOut(&g_hidSrv, handle.handle, 508); } -Result hidReadPalmaApplicationSection(HidPalmaConnectionHandle handle, s32 inval0, u64 inval1) { +Result hidReadPalmaApplicationSection(HidPalmaConnectionHandle handle, s32 inval0, u64 size) { if (hosversionBefore(5,0,0)) return MAKERESULT(Module_Libnx, LibnxError_IncompatSysVer); - if (inval0 > sizeof(HidPalmaApplicationSectionAccessBuffer)) + if (size > sizeof(HidPalmaApplicationSectionAccessBuffer)) return MAKERESULT(Module_Libnx, LibnxError_BadInput); const struct { HidPalmaConnectionHandle handle; u64 inval0; - u64 inval1; - } in = { handle, inval0, inval1 }; + u64 size; + } in = { handle, inval0, size }; return serviceDispatchIn(&g_hidSrv, 509, in); }