aboutsummaryrefslogtreecommitdiffhomepage
path: root/src/core/hle/service/cfg
diff options
context:
space:
mode:
Diffstat (limited to 'src/core/hle/service/cfg')
-rw-r--r--src/core/hle/service/cfg/cfg.cpp12
-rw-r--r--src/core/hle/service/cfg/cfg_i.cpp14
-rw-r--r--src/core/hle/service/cfg/cfg_i.h13
-rw-r--r--src/core/hle/service/cfg/cfg_s.cpp14
-rw-r--r--src/core/hle/service/cfg/cfg_s.h13
-rw-r--r--src/core/hle/service/cfg/cfg_u.cpp14
-rw-r--r--src/core/hle/service/cfg/cfg_u.h13
7 files changed, 43 insertions, 50 deletions
diff --git a/src/core/hle/service/cfg/cfg.cpp b/src/core/hle/service/cfg/cfg.cpp
index b7cdccb8..1eb2562d 100644
--- a/src/core/hle/service/cfg/cfg.cpp
+++ b/src/core/hle/service/cfg/cfg.cpp
@@ -3,9 +3,13 @@
// Refer to the license.txt file included.
#include <algorithm>
-#include "common/make_unique.h"
-#include "core/hle/service/cfg/cfg.h"
+
#include "core/hle/service/fs/archive.h"
+#include "core/hle/service/service.h"
+#include "core/hle/service/cfg/cfg.h"
+#include "core/hle/service/cfg/cfg_i.h"
+#include "core/hle/service/cfg/cfg_s.h"
+#include "core/hle/service/cfg/cfg_u.h"
namespace Service {
namespace CFG {
@@ -162,6 +166,10 @@ ResultCode FormatConfig() {
}
void CFGInit() {
+ AddService(new CFG_I_Interface);
+ AddService(new CFG_S_Interface);
+ AddService(new CFG_U_Interface);
+
// Open the SystemSaveData archive 0x00010017
FileSys::Path archive_path(cfg_system_savedata_id);
auto archive_result = Service::FS::OpenArchive(Service::FS::ArchiveIdCode::SystemSaveData, archive_path);
diff --git a/src/core/hle/service/cfg/cfg_i.cpp b/src/core/hle/service/cfg/cfg_i.cpp
index 20b09a8c..6d1eee4e 100644
--- a/src/core/hle/service/cfg/cfg_i.cpp
+++ b/src/core/hle/service/cfg/cfg_i.cpp
@@ -6,10 +6,8 @@
#include "core/hle/service/cfg/cfg.h"
#include "core/hle/service/cfg/cfg_i.h"
-////////////////////////////////////////////////////////////////////////////////////////////////////
-// Namespace CFG_I
-
-namespace CFG_I {
+namespace Service {
+namespace CFG {
/**
* CFG_I::GetConfigInfoBlk8 service function
@@ -99,11 +97,9 @@ const Interface::FunctionInfo FunctionTable[] = {
{0x08180042, nullptr, "SecureInfoGetSerialNo"},
};
-////////////////////////////////////////////////////////////////////////////////////////////////////
-// Interface class
-
-Interface::Interface() {
+CFG_I_Interface::CFG_I_Interface() {
Register(FunctionTable);
}
-} // namespace
+} // namespace CFG
+} // namespace Service \ No newline at end of file
diff --git a/src/core/hle/service/cfg/cfg_i.h b/src/core/hle/service/cfg/cfg_i.h
index a498dd58..d0a2cce3 100644
--- a/src/core/hle/service/cfg/cfg_i.h
+++ b/src/core/hle/service/cfg/cfg_i.h
@@ -6,18 +6,17 @@
#include "core/hle/service/service.h"
-////////////////////////////////////////////////////////////////////////////////////////////////////
-// Namespace CFG_I
+namespace Service {
+namespace CFG {
-namespace CFG_I {
-
-class Interface : public Service::Interface {
+class CFG_I_Interface : public Service::Interface {
public:
- Interface();
+ CFG_I_Interface();
std::string GetPortName() const override {
return "cfg:i";
}
};
-} // namespace
+} // namespace CFG
+} // namespace Service \ No newline at end of file
diff --git a/src/core/hle/service/cfg/cfg_s.cpp b/src/core/hle/service/cfg/cfg_s.cpp
index d80aeae8..d9a3e5d5 100644
--- a/src/core/hle/service/cfg/cfg_s.cpp
+++ b/src/core/hle/service/cfg/cfg_s.cpp
@@ -6,10 +6,8 @@
#include "core/hle/service/cfg/cfg.h"
#include "core/hle/service/cfg/cfg_s.h"
-////////////////////////////////////////////////////////////////////////////////////////////////////
-// Namespace CFG_S
-
-namespace CFG_S {
+namespace Service {
+namespace CFG {
/**
* CFG_S::GetConfigInfoBlk2 service function
@@ -87,11 +85,9 @@ const Interface::FunctionInfo FunctionTable[] = {
{0x04090000, nullptr, "UpdateConfigBlk00040003"},
};
-////////////////////////////////////////////////////////////////////////////////////////////////////
-// Interface class
-
-Interface::Interface() {
+CFG_S_Interface::CFG_S_Interface() {
Register(FunctionTable);
}
-} // namespace
+} // namespace CFG
+} // namespace Service
diff --git a/src/core/hle/service/cfg/cfg_s.h b/src/core/hle/service/cfg/cfg_s.h
index d8b67137..5568d648 100644
--- a/src/core/hle/service/cfg/cfg_s.h
+++ b/src/core/hle/service/cfg/cfg_s.h
@@ -6,18 +6,17 @@
#include "core/hle/service/service.h"
-////////////////////////////////////////////////////////////////////////////////////////////////////
-// Namespace CFG_S
+namespace Service {
+namespace CFG {
-namespace CFG_S {
-
-class Interface : public Service::Interface {
+class CFG_S_Interface : public Service::Interface {
public:
- Interface();
+ CFG_S_Interface();
std::string GetPortName() const override {
return "cfg:s";
}
};
-} // namespace
+} // namespace CFG
+} // namespace Service
diff --git a/src/core/hle/service/cfg/cfg_u.cpp b/src/core/hle/service/cfg/cfg_u.cpp
index a65da90c..c8c1c5b1 100644
--- a/src/core/hle/service/cfg/cfg_u.cpp
+++ b/src/core/hle/service/cfg/cfg_u.cpp
@@ -10,10 +10,8 @@
#include "core/hle/service/cfg/cfg.h"
#include "core/hle/service/cfg/cfg_u.h"
-////////////////////////////////////////////////////////////////////////////////////////////////////
-// Namespace CFG_U
-
-namespace CFG_U {
+namespace Service {
+namespace CFG {
// TODO(Link Mauve): use a constexpr once MSVC starts supporting it.
#define C(code) ((code)[0] | ((code)[1] << 8))
@@ -241,11 +239,9 @@ const Interface::FunctionInfo FunctionTable[] = {
{0x000A0040, GetCountryCodeID, "GetCountryCodeID"},
};
-////////////////////////////////////////////////////////////////////////////////////////////////////
-// Interface class
-
-Interface::Interface() {
+CFG_U_Interface::CFG_U_Interface() {
Register(FunctionTable);
}
-} // namespace
+} // namespace CFG
+} // namespace Service
diff --git a/src/core/hle/service/cfg/cfg_u.h b/src/core/hle/service/cfg/cfg_u.h
index 9ad73f35..5303d8ac 100644
--- a/src/core/hle/service/cfg/cfg_u.h
+++ b/src/core/hle/service/cfg/cfg_u.h
@@ -6,18 +6,17 @@
#include "core/hle/service/service.h"
-////////////////////////////////////////////////////////////////////////////////////////////////////
-// Namespace CFG_U
+namespace Service {
+namespace CFG {
-namespace CFG_U {
-
-class Interface : public Service::Interface {
+class CFG_U_Interface : public Service::Interface {
public:
- Interface();
+ CFG_U_Interface();
std::string GetPortName() const override {
return "cfg:u";
}
};
-} // namespace
+} // namespace CFG
+} // namespace Service