diff options
Diffstat (limited to '')
-rw-r--r-- | src/core/hle/service/hid/hidbus/hidbus_base.h | 17 |
1 files changed, 11 insertions, 6 deletions
diff --git a/src/core/hle/service/hid/hidbus/hidbus_base.h b/src/core/hle/service/hid/hidbus/hidbus_base.h index d3960f506..ec41684e1 100644 --- a/src/core/hle/service/hid/hidbus/hidbus_base.h +++ b/src/core/hle/service/hid/hidbus/hidbus_base.h @@ -4,9 +4,14 @@ #pragma once #include <array> -#include "common/common_types.h" +#include <span> +#include "common/typed_address.h" #include "core/hle/result.h" +namespace Core { +class System; +} + namespace Kernel { class KEvent; class KReadableEvent; @@ -105,7 +110,7 @@ static_assert(sizeof(ButtonOnlyPollingDataAccessor) == 0x2F0, class HidbusBase { public: - explicit HidbusBase(KernelHelpers::ServiceContext& service_context_); + explicit HidbusBase(Core::System& system_, KernelHelpers::ServiceContext& service_context_); virtual ~HidbusBase(); void ActivateDevice(); @@ -133,7 +138,7 @@ public: void DisablePollingMode(); // Called on EnableJoyPollingReceiveMode - void SetTransferMemoryPointer(u8* t_mem); + void SetTransferMemoryAddress(Common::ProcessAddress t_mem); Kernel::KReadableEvent& GetSendCommandAsycEvent() const; @@ -150,7 +155,7 @@ public: } // Assigns a command from data - virtual bool SetCommand(const std::vector<u8>& data) { + virtual bool SetCommand(std::span<const u8> data) { return {}; } @@ -169,9 +174,9 @@ protected: JoyEnableSixAxisDataAccessor enable_sixaxis_data{}; ButtonOnlyPollingDataAccessor button_only_data{}; - u8* transfer_memory{nullptr}; - bool is_transfer_memory_set{}; + Common::ProcessAddress transfer_memory{}; + Core::System& system; Kernel::KEvent* send_command_async_event; KernelHelpers::ServiceContext& service_context; }; |