erpt: skeleton sprofile apis
This commit is contained in:
@@ -88,6 +88,7 @@
|
||||
#include <stratosphere/sm.hpp>
|
||||
#include <stratosphere/socket.hpp>
|
||||
#include <stratosphere/spl.hpp>
|
||||
#include <stratosphere/sprofile.hpp>
|
||||
#include <stratosphere/time.hpp>
|
||||
#include <stratosphere/tipc.hpp>
|
||||
#include <stratosphere/tma.hpp>
|
||||
|
||||
@@ -168,6 +168,9 @@ namespace ams::impl {
|
||||
AMS_DEFINE_SYSTEM_THREAD(21, TioServer, FileServerHtcsServer);
|
||||
AMS_DEFINE_SYSTEM_THREAD(21, TioServer, SdCardObserver);
|
||||
|
||||
/* ServiceProfile */
|
||||
AMS_DEFINE_SYSTEM_THREAD(-1, sprofile, IpcServer);
|
||||
|
||||
|
||||
#undef AMS_DEFINE_SYSTEM_THREAD
|
||||
|
||||
|
||||
@@ -171,6 +171,9 @@
|
||||
HANDLER(AcpUserAccountSettingsInfo, 130) \
|
||||
HANDLER(AudioDeviceInfo, 131) \
|
||||
HANDLER(AbnormalWakeInfo, 132) \
|
||||
HANDLER(ServiceProfileInfo, 133) \
|
||||
HANDLER(BluetoothAudioInfo, 134) \
|
||||
HANDLER(BluetoothPairingCountInfo, 135) \
|
||||
|
||||
#define AMS_ERPT_FOREACH_FIELD(HANDLER) \
|
||||
HANDLER(TestU64, 0, Test, FieldType_NumericU64, FieldFlag_None ) \
|
||||
@@ -812,4 +815,15 @@
|
||||
HANDLER(AppletTotalActiveTime, 636, ErrorInfoAuto, FieldType_NumericI64, FieldFlag_None ) \
|
||||
HANDLER(WakeCount, 637, AbnormalWakeInfo, FieldType_NumericU32, FieldFlag_None ) \
|
||||
HANDLER(PredominantWakeReason, 638, AbnormalWakeInfo, FieldType_NumericU32, FieldFlag_None ) \
|
||||
HANDLER(EdidExtensionBlock2, 639, EdidInfo, FieldType_U8Array, FieldFlag_None ) \
|
||||
HANDLER(EdidExtensionBlock3, 640, EdidInfo, FieldType_U8Array, FieldFlag_None ) \
|
||||
HANDLER(LumenRequestId, 641, ErrorInfo, FieldType_String, FieldFlag_None ) \
|
||||
HANDLER(LlnwLlid, 642, ErrorInfo, FieldType_String, FieldFlag_None ) \
|
||||
HANDLER(SupportingLimitedLicenses, 643, RunningApplicationInfo, FieldType_NumericU32, FieldFlag_None ) \
|
||||
HANDLER(RuntimeLimitedLicenseUpgrade, 644, RunningApplicationInfo, FieldType_NumericU8, FieldFlag_None ) \
|
||||
HANDLER(ServiceProfileRevisionKey, 645, ServiceProfileInfo, FieldType_NumericU64, FieldFlag_None ) \
|
||||
HANDLER(BluetoothAudioConnectionCount, 646, BluetoothAudioInfo, FieldType_NumericU8, FieldFlag_None ) \
|
||||
HANDLER(BluetoothHidPairingInfoCount, 647, BluetoothPairingCountInfo, FieldType_NumericU8, FieldFlag_None ) \
|
||||
HANDLER(BluetoothAudioPairingInfoCount, 648, BluetoothPairingCountInfo, FieldType_NumericU8, FieldFlag_None ) \
|
||||
HANDLER(BluetoothLePairingInfoCount, 649, BluetoothPairingCountInfo, FieldType_NumericU8, FieldFlag_None ) \
|
||||
|
||||
|
||||
19
libraries/libstratosphere/include/stratosphere/sprofile.hpp
Normal file
19
libraries/libstratosphere/include/stratosphere/sprofile.hpp
Normal file
@@ -0,0 +1,19 @@
|
||||
/*
|
||||
* Copyright (c) 2018-2020 Atmosphère-NX
|
||||
*
|
||||
* This program is free software; you can redistribute it and/or modify it
|
||||
* under the terms and conditions of the GNU General Public License,
|
||||
* version 2, as published by the Free Software Foundation.
|
||||
*
|
||||
* This program is distributed in the hope it will be useful, but WITHOUT
|
||||
* ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
|
||||
* FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for
|
||||
* more details.
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License
|
||||
* along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
*/
|
||||
#pragma once
|
||||
|
||||
#include <stratosphere/sprofile/sprofile_types.hpp>
|
||||
#include <stratosphere/sprofile/srv/sprofile_srv_api.hpp>
|
||||
@@ -0,0 +1,35 @@
|
||||
/*
|
||||
* Copyright (c) 2018-2020 Atmosphère-NX
|
||||
*
|
||||
* This program is free software; you can redistribute it and/or modify it
|
||||
* under the terms and conditions of the GNU General Public License,
|
||||
* version 2, as published by the Free Software Foundation.
|
||||
*
|
||||
* This program is distributed in the hope it will be useful, but WITHOUT
|
||||
* ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
|
||||
* FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for
|
||||
* more details.
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License
|
||||
* along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
*/
|
||||
#pragma once
|
||||
#include <vapours.hpp>
|
||||
|
||||
namespace ams::sprofile {
|
||||
|
||||
struct Identifier {
|
||||
u8 data[7];
|
||||
|
||||
friend bool operator==(const Identifier &lhs, const Identifier &rhs) {
|
||||
return std::memcmp(lhs.data, rhs.data, sizeof(lhs.data)) == 0;
|
||||
}
|
||||
|
||||
friend bool operator!=(const Identifier &lhs, const Identifier &rhs) {
|
||||
return !(lhs == rhs);
|
||||
}
|
||||
};
|
||||
static_assert(sizeof(Identifier) == 7);
|
||||
static_assert(util::is_pod<Identifier>::value);
|
||||
|
||||
}
|
||||
@@ -0,0 +1,24 @@
|
||||
/*
|
||||
* Copyright (c) 2018-2020 Atmosphère-NX
|
||||
*
|
||||
* This program is free software; you can redistribute it and/or modify it
|
||||
* under the terms and conditions of the GNU General Public License,
|
||||
* version 2, as published by the Free Software Foundation.
|
||||
*
|
||||
* This program is distributed in the hope it will be useful, but WITHOUT
|
||||
* ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
|
||||
* FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for
|
||||
* more details.
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License
|
||||
* along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
*/
|
||||
#pragma once
|
||||
#include <vapours.hpp>
|
||||
|
||||
namespace ams::sprofile::srv {
|
||||
|
||||
void Initialize();
|
||||
void StartIpcServer();
|
||||
|
||||
}
|
||||
Reference in New Issue
Block a user