summaryrefslogtreecommitdiff
path: root/src/core/loader/loader.h
diff options
context:
space:
mode:
authorGravatar Yuri Kunde Schlesner2016-11-27 17:04:11 -0800
committerGravatar GitHub2016-11-27 17:04:11 -0800
commit3174bfd50c69dfa523671b96448113996a0bc42c (patch)
tree89575620a506d18c6fea2f8570c09bc0e9864263 /src/core/loader/loader.h
parentMerge pull request #2222 from linkmauve/die-frameskip-die (diff)
parentKernel/Loader: Grab the system mode from the NCCH ExHeader. (diff)
downloadyuzu-3174bfd50c69dfa523671b96448113996a0bc42c.tar.gz
yuzu-3174bfd50c69dfa523671b96448113996a0bc42c.tar.xz
yuzu-3174bfd50c69dfa523671b96448113996a0bc42c.zip
Merge pull request #2196 from Subv/system_mode
Kernel/Loader: Grab the system mode from the NCCH ExHeader.
Diffstat (limited to 'src/core/loader/loader.h')
-rw-r--r--src/core/loader/loader.h12
1 files changed, 12 insertions, 0 deletions
diff --git a/src/core/loader/loader.h b/src/core/loader/loader.h
index 9652d7ac5..5e3d46638 100644
--- a/src/core/loader/loader.h
+++ b/src/core/loader/loader.h
@@ -9,6 +9,7 @@
9#include <memory> 9#include <memory>
10#include <string> 10#include <string>
11#include <vector> 11#include <vector>
12#include <boost/optional.hpp>
12#include "common/common_types.h" 13#include "common/common_types.h"
13#include "common/file_util.h" 14#include "common/file_util.h"
14 15
@@ -96,6 +97,17 @@ public:
96 virtual ResultStatus Load() = 0; 97 virtual ResultStatus Load() = 0;
97 98
98 /** 99 /**
100 * Loads the system mode that this application needs.
101 * This function defaults to 2 (96MB allocated to the application) if it can't read the
102 * information.
103 * @returns Optional with the kernel system mode
104 */
105 virtual boost::optional<u32> LoadKernelSystemMode() {
106 // 96MB allocated to the application.
107 return 2;
108 }
109
110 /**
99 * Get the code (typically .code section) of the application 111 * Get the code (typically .code section) of the application
100 * @param buffer Reference to buffer to store data 112 * @param buffer Reference to buffer to store data
101 * @return ResultStatus result of function 113 * @return ResultStatus result of function