summaryrefslogtreecommitdiffstats
path: root/src/core/hle/kernel/hle_ipc.cpp
diff options
context:
space:
mode:
authorbunnei <bunneidev@gmail.com>2017-10-19 03:38:01 +0200
committerbunnei <bunneidev@gmail.com>2017-10-19 03:38:01 +0200
commitb283cf734807e63e4bbee1a085553cb653648944 (patch)
treea098b2d72e435f6f3661a2c4aae15574e49b7b41 /src/core/hle/kernel/hle_ipc.cpp
parentservice: Add CreatePort function (that does not register/install). (diff)
downloadyuzu-b283cf734807e63e4bbee1a085553cb653648944.tar
yuzu-b283cf734807e63e4bbee1a085553cb653648944.tar.gz
yuzu-b283cf734807e63e4bbee1a085553cb653648944.tar.bz2
yuzu-b283cf734807e63e4bbee1a085553cb653648944.tar.lz
yuzu-b283cf734807e63e4bbee1a085553cb653648944.tar.xz
yuzu-b283cf734807e63e4bbee1a085553cb653648944.tar.zst
yuzu-b283cf734807e63e4bbee1a085553cb653648944.zip
Diffstat (limited to 'src/core/hle/kernel/hle_ipc.cpp')
-rw-r--r--src/core/hle/kernel/hle_ipc.cpp25
1 files changed, 11 insertions, 14 deletions
diff --git a/src/core/hle/kernel/hle_ipc.cpp b/src/core/hle/kernel/hle_ipc.cpp
index 35cac68f1..fc05c44b4 100644
--- a/src/core/hle/kernel/hle_ipc.cpp
+++ b/src/core/hle/kernel/hle_ipc.cpp
@@ -66,28 +66,25 @@ void HLERequestContext::ParseCommandBuffer(u32_le* src_cmdbuf, bool incoming) {
rp.Skip(handle_descriptor_header->num_handles_to_move, false);
}
- // Padding to align to 16 bytes
- rp.AlignWithPadding();
-
- if (command_header->num_buf_x_descriptors) {
- UNIMPLEMENTED();
+ for (int i = 0; i < command_header->num_buf_x_descriptors; ++i) {
+ buffer_x_desciptors.push_back(rp.PopRaw<IPC::BufferDescriptorX>());
}
- if (command_header->num_buf_a_descriptors) {
- UNIMPLEMENTED();
+ for (int i = 0; i < command_header->num_buf_a_descriptors; ++i) {
+ buffer_a_desciptors.push_back(rp.PopRaw<IPC::BufferDescriptorABW>());
}
- if (command_header->num_buf_b_descriptors) {
- UNIMPLEMENTED();
+ for (int i = 0; i < command_header->num_buf_b_descriptors; ++i) {
+ buffer_b_desciptors.push_back(rp.PopRaw<IPC::BufferDescriptorABW>());
}
- if (command_header->num_buf_w_descriptors) {
- UNIMPLEMENTED();
+ for (int i = 0; i < command_header->num_buf_w_descriptors; ++i) {
+ buffer_w_desciptors.push_back(rp.PopRaw<IPC::BufferDescriptorABW>());
}
if (command_header->buf_c_descriptor_flags !=
IPC::CommandHeader::BufferDescriptorCFlag::Disabled) {
UNIMPLEMENTED();
}
- if (incoming && Session()->IsDomain()) {
- domain_message_header = std::make_unique<IPC::DomainMessageHeader>(rp.PopRaw<IPC::DomainMessageHeader>());
+ // Padding to align to 16 bytes
+ rp.AlignWithPadding();
}
data_payload_header =
@@ -123,7 +120,7 @@ ResultCode HLERequestContext::WriteToOutgoingCommandBuffer(u32_le* dst_cmdbuf, P
HandleTable& dst_table) {
ParseCommandBuffer(&cmd_buf[0], false);
size_t untranslated_size = data_payload_offset + command_header->data_size;
- std::copy_n(cmd_buf.begin(), untranslated_size, dst_cmdbuf);
+ std::copy_n(cmd_buf.begin(), 64, dst_cmdbuf);
if (command_header->enable_handle_descriptor) {
size_t command_size = untranslated_size + handle_descriptor_header->num_handles_to_copy +