From: profi200 Date: Mon, 23 Mar 2015 23:05:26 +0000 (+0100) Subject: Replaced AM_installFIRM() with AM_installNativeFirm(). X-Git-Tag: v0.6.0~72^2 X-Git-Url: https://chaos.moe/g/?a=commitdiff_plain;h=4ab2b1a363399c2d39ccf4425f9b075279a798c7;p=corbenik%2Fctrulib.git Replaced AM_installFIRM() with AM_installNativeFirm(). --- diff --git a/libctru/include/3ds/services/am.h b/libctru/include/3ds/services/am.h index eaf7379..06ce957 100644 --- a/libctru/include/3ds/services/am.h +++ b/libctru/include/3ds/services/am.h @@ -103,13 +103,10 @@ Note: If the title has the system category bit set, this will fail */ Result AM_DeleteAppTitle(u8 mediatype, u64 titleID); -/* AM_InstallFIRM() -About: Installs FIRM to NAND (firm0:/ & firm1:/) from a CXI -Note: The title must have the uniqueid: 0x00000, otherwise this will fail. - - titleid title id of title +/* AM_InstallNativeFirm() +About: Installs NATIVE_FIRM to NAND (firm0:/ & firm1:/) from a CXI */ -Result AM_InstallFIRM(u64 titleID); +Result AM_InstallNativeFirm(); /* AM_GetTitleProductCode() About: Gets the product code of a title based on its title id. diff --git a/libctru/source/services/am.c b/libctru/source/services/am.c index e80faff..a6f6cb3 100644 --- a/libctru/source/services/am.c +++ b/libctru/source/services/am.c @@ -171,14 +171,12 @@ Result AM_DeleteAppTitle(u8 mediatype, u64 titleID) return (Result)cmdbuf[1]; } -Result AM_InstallFIRM(u64 titleID) +Result AM_InstallNativeFirm() { Result ret = 0; u32 *cmdbuf = getThreadCommandBuffer(); - cmdbuf[0] = 0x04010080; - cmdbuf[1] = titleID & 0xffffffff; - cmdbuf[2] = (u32)(titleID >> 32); + cmdbuf[0] = 0x040F0000; if((ret = svcSendSyncRequest(amHandle))!=0) return ret;