Remove duplicated docs/update them for changed parameters.
This commit is contained in:
parent
c2588403c0
commit
22c86824a4
|
@ -25,11 +25,6 @@ public:
|
||||||
|
|
||||||
std::string name; ///< Name of address arbiter object (optional)
|
std::string name; ///< Name of address arbiter object (optional)
|
||||||
|
|
||||||
/**
|
|
||||||
* Wait for kernel object to synchronize
|
|
||||||
* @param wait Boolean wait set if current thread should wait as a result of sync operation
|
|
||||||
* @return Result of operation, 0 on success, otherwise error code
|
|
||||||
*/
|
|
||||||
ResultVal<bool> WaitSynchronization() override {
|
ResultVal<bool> WaitSynchronization() override {
|
||||||
// TODO(bunnei): ImplementMe
|
// TODO(bunnei): ImplementMe
|
||||||
ERROR_LOG(OSHLE, "(UNIMPLEMENTED)");
|
ERROR_LOG(OSHLE, "(UNIMPLEMENTED)");
|
||||||
|
|
|
@ -52,11 +52,6 @@ public:
|
||||||
std::string name; ///< Name of archive (optional)
|
std::string name; ///< Name of archive (optional)
|
||||||
FileSys::Archive* backend; ///< Archive backend interface
|
FileSys::Archive* backend; ///< Archive backend interface
|
||||||
|
|
||||||
/**
|
|
||||||
* Synchronize kernel object
|
|
||||||
* @param wait Boolean wait set if current thread should wait as a result of sync operation
|
|
||||||
* @return Result of operation, 0 on success, otherwise error code
|
|
||||||
*/
|
|
||||||
ResultVal<bool> SyncRequest() override {
|
ResultVal<bool> SyncRequest() override {
|
||||||
u32* cmd_buff = Service::GetCommandBuffer();
|
u32* cmd_buff = Service::GetCommandBuffer();
|
||||||
FileCommand cmd = static_cast<FileCommand>(cmd_buff[0]);
|
FileCommand cmd = static_cast<FileCommand>(cmd_buff[0]);
|
||||||
|
@ -114,11 +109,6 @@ public:
|
||||||
return MakeResult<bool>(false);
|
return MakeResult<bool>(false);
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
|
||||||
* Wait for kernel object to synchronize
|
|
||||||
* @param wait Boolean wait set if current thread should wait as a result of sync operation
|
|
||||||
* @return Result of operation, 0 on success, otherwise error code
|
|
||||||
*/
|
|
||||||
ResultVal<bool> WaitSynchronization() override {
|
ResultVal<bool> WaitSynchronization() override {
|
||||||
// TODO(bunnei): ImplementMe
|
// TODO(bunnei): ImplementMe
|
||||||
ERROR_LOG(OSHLE, "(UNIMPLEMENTED)");
|
ERROR_LOG(OSHLE, "(UNIMPLEMENTED)");
|
||||||
|
@ -137,11 +127,6 @@ public:
|
||||||
FileSys::Path path; ///< Path of the file
|
FileSys::Path path; ///< Path of the file
|
||||||
std::unique_ptr<FileSys::File> backend; ///< File backend interface
|
std::unique_ptr<FileSys::File> backend; ///< File backend interface
|
||||||
|
|
||||||
/**
|
|
||||||
* Synchronize kernel object
|
|
||||||
* @param wait Boolean wait set if current thread should wait as a result of sync operation
|
|
||||||
* @return Result of operation, 0 on success, otherwise error code
|
|
||||||
*/
|
|
||||||
ResultVal<bool> SyncRequest() override {
|
ResultVal<bool> SyncRequest() override {
|
||||||
u32* cmd_buff = Service::GetCommandBuffer();
|
u32* cmd_buff = Service::GetCommandBuffer();
|
||||||
FileCommand cmd = static_cast<FileCommand>(cmd_buff[0]);
|
FileCommand cmd = static_cast<FileCommand>(cmd_buff[0]);
|
||||||
|
@ -208,11 +193,6 @@ public:
|
||||||
return MakeResult<bool>(false);
|
return MakeResult<bool>(false);
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
|
||||||
* Wait for kernel object to synchronize
|
|
||||||
* @param wait Boolean wait set if current thread should wait as a result of sync operation
|
|
||||||
* @return Result of operation, 0 on success, otherwise error code
|
|
||||||
*/
|
|
||||||
ResultVal<bool> WaitSynchronization() override {
|
ResultVal<bool> WaitSynchronization() override {
|
||||||
// TODO(bunnei): ImplementMe
|
// TODO(bunnei): ImplementMe
|
||||||
ERROR_LOG(OSHLE, "(UNIMPLEMENTED)");
|
ERROR_LOG(OSHLE, "(UNIMPLEMENTED)");
|
||||||
|
@ -231,11 +211,6 @@ public:
|
||||||
FileSys::Path path; ///< Path of the directory
|
FileSys::Path path; ///< Path of the directory
|
||||||
std::unique_ptr<FileSys::Directory> backend; ///< File backend interface
|
std::unique_ptr<FileSys::Directory> backend; ///< File backend interface
|
||||||
|
|
||||||
/**
|
|
||||||
* Synchronize kernel object
|
|
||||||
* @param wait Boolean wait set if current thread should wait as a result of sync operation
|
|
||||||
* @return Result of operation, 0 on success, otherwise error code
|
|
||||||
*/
|
|
||||||
ResultVal<bool> SyncRequest() override {
|
ResultVal<bool> SyncRequest() override {
|
||||||
u32* cmd_buff = Service::GetCommandBuffer();
|
u32* cmd_buff = Service::GetCommandBuffer();
|
||||||
DirectoryCommand cmd = static_cast<DirectoryCommand>(cmd_buff[0]);
|
DirectoryCommand cmd = static_cast<DirectoryCommand>(cmd_buff[0]);
|
||||||
|
@ -273,11 +248,6 @@ public:
|
||||||
return MakeResult<bool>(false);
|
return MakeResult<bool>(false);
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
|
||||||
* Wait for kernel object to synchronize
|
|
||||||
* @param wait Boolean wait set if current thread should wait as a result of sync operation
|
|
||||||
* @return Result of operation, 0 on success, otherwise error code
|
|
||||||
*/
|
|
||||||
ResultVal<bool> WaitSynchronization() override {
|
ResultVal<bool> WaitSynchronization() override {
|
||||||
// TODO(bunnei): ImplementMe
|
// TODO(bunnei): ImplementMe
|
||||||
ERROR_LOG(OSHLE, "(UNIMPLEMENTED)");
|
ERROR_LOG(OSHLE, "(UNIMPLEMENTED)");
|
||||||
|
@ -313,7 +283,6 @@ ResultCode CloseArchive(FileSys::Archive::IdCode id_code) {
|
||||||
/**
|
/**
|
||||||
* Mounts an archive
|
* Mounts an archive
|
||||||
* @param archive Pointer to the archive to mount
|
* @param archive Pointer to the archive to mount
|
||||||
* @return Result of operation
|
|
||||||
*/
|
*/
|
||||||
ResultCode MountArchive(Archive* archive) {
|
ResultCode MountArchive(Archive* archive) {
|
||||||
FileSys::Archive::IdCode id_code = archive->backend->GetIdCode();
|
FileSys::Archive::IdCode id_code = archive->backend->GetIdCode();
|
||||||
|
|
|
@ -30,11 +30,6 @@ public:
|
||||||
std::vector<Handle> waiting_threads; ///< Threads that are waiting for the event
|
std::vector<Handle> waiting_threads; ///< Threads that are waiting for the event
|
||||||
std::string name; ///< Name of event (optional)
|
std::string name; ///< Name of event (optional)
|
||||||
|
|
||||||
/**
|
|
||||||
* Wait for kernel object to synchronize
|
|
||||||
* @param wait Boolean wait set if current thread should wait as a result of sync operation
|
|
||||||
* @return Result of operation, 0 on success, otherwise error code
|
|
||||||
*/
|
|
||||||
ResultVal<bool> WaitSynchronization() override {
|
ResultVal<bool> WaitSynchronization() override {
|
||||||
bool wait = locked;
|
bool wait = locked;
|
||||||
if (locked) {
|
if (locked) {
|
||||||
|
|
|
@ -15,7 +15,6 @@ namespace Kernel {
|
||||||
* Changes whether an event is locked or not
|
* Changes whether an event is locked or not
|
||||||
* @param handle Handle to event to change
|
* @param handle Handle to event to change
|
||||||
* @param locked Boolean locked value to set event
|
* @param locked Boolean locked value to set event
|
||||||
* @return Result of operation, 0 on success, otherwise error code
|
|
||||||
*/
|
*/
|
||||||
ResultCode SetEventLocked(const Handle handle, const bool locked);
|
ResultCode SetEventLocked(const Handle handle, const bool locked);
|
||||||
|
|
||||||
|
@ -23,21 +22,18 @@ ResultCode SetEventLocked(const Handle handle, const bool locked);
|
||||||
* Hackish function to set an events permanent lock state, used to pass through synch blocks
|
* Hackish function to set an events permanent lock state, used to pass through synch blocks
|
||||||
* @param handle Handle to event to change
|
* @param handle Handle to event to change
|
||||||
* @param permanent_locked Boolean permanent locked value to set event
|
* @param permanent_locked Boolean permanent locked value to set event
|
||||||
* @return Result of operation, 0 on success, otherwise error code
|
|
||||||
*/
|
*/
|
||||||
ResultCode SetPermanentLock(Handle handle, const bool permanent_locked);
|
ResultCode SetPermanentLock(Handle handle, const bool permanent_locked);
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Signals an event
|
* Signals an event
|
||||||
* @param handle Handle to event to signal
|
* @param handle Handle to event to signal
|
||||||
* @return Result of operation, 0 on success, otherwise error code
|
|
||||||
*/
|
*/
|
||||||
ResultCode SignalEvent(const Handle handle);
|
ResultCode SignalEvent(const Handle handle);
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Clears an event
|
* Clears an event
|
||||||
* @param handle Handle to event to clear
|
* @param handle Handle to event to clear
|
||||||
* @return Result of operation, 0 on success, otherwise error code
|
|
||||||
*/
|
*/
|
||||||
ResultCode ClearEvent(Handle handle);
|
ResultCode ClearEvent(Handle handle);
|
||||||
|
|
||||||
|
|
|
@ -27,22 +27,12 @@ public:
|
||||||
std::vector<Handle> waiting_threads; ///< Threads that are waiting for the mutex
|
std::vector<Handle> waiting_threads; ///< Threads that are waiting for the mutex
|
||||||
std::string name; ///< Name of mutex (optional)
|
std::string name; ///< Name of mutex (optional)
|
||||||
|
|
||||||
/**
|
|
||||||
* Synchronize kernel object
|
|
||||||
* @param wait Boolean wait set if current thread should wait as a result of sync operation
|
|
||||||
* @return Result of operation, 0 on success, otherwise error code
|
|
||||||
*/
|
|
||||||
ResultVal<bool> SyncRequest() override {
|
ResultVal<bool> SyncRequest() override {
|
||||||
// TODO(bunnei): ImplementMe
|
// TODO(bunnei): ImplementMe
|
||||||
locked = true;
|
locked = true;
|
||||||
return MakeResult<bool>(false);
|
return MakeResult<bool>(false);
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
|
||||||
* Wait for kernel object to synchronize
|
|
||||||
* @param wait Boolean wait set if current thread should wait as a result of sync operation
|
|
||||||
* @return Result of operation, 0 on success, otherwise error code
|
|
||||||
*/
|
|
||||||
ResultVal<bool> WaitSynchronization() override {
|
ResultVal<bool> WaitSynchronization() override {
|
||||||
// TODO(bunnei): ImplementMe
|
// TODO(bunnei): ImplementMe
|
||||||
bool wait = locked;
|
bool wait = locked;
|
||||||
|
|
|
@ -13,7 +13,6 @@ namespace Kernel {
|
||||||
/**
|
/**
|
||||||
* Releases a mutex
|
* Releases a mutex
|
||||||
* @param handle Handle to mutex to release
|
* @param handle Handle to mutex to release
|
||||||
* @return Result of operation, 0 on success, otherwise error code
|
|
||||||
*/
|
*/
|
||||||
ResultCode ReleaseMutex(Handle handle);
|
ResultCode ReleaseMutex(Handle handle);
|
||||||
|
|
||||||
|
|
|
@ -16,11 +16,6 @@ public:
|
||||||
static Kernel::HandleType GetStaticHandleType() { return Kernel::HandleType::SharedMemory; }
|
static Kernel::HandleType GetStaticHandleType() { return Kernel::HandleType::SharedMemory; }
|
||||||
Kernel::HandleType GetHandleType() const override { return Kernel::HandleType::SharedMemory; }
|
Kernel::HandleType GetHandleType() const override { return Kernel::HandleType::SharedMemory; }
|
||||||
|
|
||||||
/**
|
|
||||||
* Wait for kernel object to synchronize
|
|
||||||
* @param wait Boolean wait set if current thread should wait as a result of sync operation
|
|
||||||
* @return Result of operation, 0 on success, otherwise error code
|
|
||||||
*/
|
|
||||||
ResultVal<bool> WaitSynchronization() override {
|
ResultVal<bool> WaitSynchronization() override {
|
||||||
// TODO(bunnei): ImplementMe
|
// TODO(bunnei): ImplementMe
|
||||||
ERROR_LOG(OSHLE, "(UNIMPLEMENTED)");
|
ERROR_LOG(OSHLE, "(UNIMPLEMENTED)");
|
||||||
|
@ -48,11 +43,6 @@ SharedMemory* CreateSharedMemory(Handle& handle, const std::string& name) {
|
||||||
return shared_memory;
|
return shared_memory;
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
|
||||||
* Creates a shared memory object
|
|
||||||
* @param name Optional name of shared memory object
|
|
||||||
* @return Handle of newly created shared memory object
|
|
||||||
*/
|
|
||||||
Handle CreateSharedMemory(const std::string& name) {
|
Handle CreateSharedMemory(const std::string& name) {
|
||||||
Handle handle;
|
Handle handle;
|
||||||
CreateSharedMemory(handle, name);
|
CreateSharedMemory(handle, name);
|
||||||
|
@ -86,12 +76,6 @@ ResultCode MapSharedMemory(u32 handle, u32 address, MemoryPermission permissions
|
||||||
return RESULT_SUCCESS;
|
return RESULT_SUCCESS;
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
|
||||||
* Gets a pointer to the shared memory block
|
|
||||||
* @param handle Shared memory block handle
|
|
||||||
* @param offset Offset from the start of the shared memory block to get pointer
|
|
||||||
* @return Pointer to the shared memory block from the specified offset
|
|
||||||
*/
|
|
||||||
ResultVal<u8*> GetSharedMemoryPointer(Handle handle, u32 offset) {
|
ResultVal<u8*> GetSharedMemoryPointer(Handle handle, u32 offset) {
|
||||||
SharedMemory* shared_memory = Kernel::g_object_pool.Get<SharedMemory>(handle);
|
SharedMemory* shared_memory = Kernel::g_object_pool.Get<SharedMemory>(handle);
|
||||||
if (shared_memory == nullptr) return InvalidHandle(ErrorModule::Kernel);
|
if (shared_memory == nullptr) return InvalidHandle(ErrorModule::Kernel);
|
||||||
|
|
|
@ -32,7 +32,6 @@ Handle CreateSharedMemory(const std::string& name="Unknown");
|
||||||
* @param address Address in system memory to map shared memory block to
|
* @param address Address in system memory to map shared memory block to
|
||||||
* @param permissions Memory block map permissions (specified by SVC field)
|
* @param permissions Memory block map permissions (specified by SVC field)
|
||||||
* @param other_permissions Memory block map other permissions (specified by SVC field)
|
* @param other_permissions Memory block map other permissions (specified by SVC field)
|
||||||
* @return Result of operation, 0 on success, otherwise error code
|
|
||||||
*/
|
*/
|
||||||
ResultCode MapSharedMemory(Handle handle, u32 address, MemoryPermission permissions,
|
ResultCode MapSharedMemory(Handle handle, u32 address, MemoryPermission permissions,
|
||||||
MemoryPermission other_permissions);
|
MemoryPermission other_permissions);
|
||||||
|
|
|
@ -34,11 +34,6 @@ public:
|
||||||
inline bool IsWaiting() const { return (status & THREADSTATUS_WAIT) != 0; }
|
inline bool IsWaiting() const { return (status & THREADSTATUS_WAIT) != 0; }
|
||||||
inline bool IsSuspended() const { return (status & THREADSTATUS_SUSPEND) != 0; }
|
inline bool IsSuspended() const { return (status & THREADSTATUS_SUSPEND) != 0; }
|
||||||
|
|
||||||
/**
|
|
||||||
* Wait for kernel object to synchronize
|
|
||||||
* @param wait Boolean wait set if current thread should wait as a result of sync operation
|
|
||||||
* @return Result of operation, 0 on success, otherwise error code
|
|
||||||
*/
|
|
||||||
ResultVal<bool> WaitSynchronization() override {
|
ResultVal<bool> WaitSynchronization() override {
|
||||||
if (status != THREADSTATUS_DORMANT) {
|
if (status != THREADSTATUS_DORMANT) {
|
||||||
Handle thread = GetCurrentThreadHandle();
|
Handle thread = GetCurrentThreadHandle();
|
||||||
|
|
|
@ -75,11 +75,6 @@ public:
|
||||||
m_handles.erase(std::remove(m_handles.begin(), m_handles.end(), handle), m_handles.end());
|
m_handles.erase(std::remove(m_handles.begin(), m_handles.end(), handle), m_handles.end());
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
|
||||||
* Synchronize kernel object
|
|
||||||
* @param wait Boolean wait set if current thread should wait as a result of sync operation
|
|
||||||
* @return Result of operation, 0 on success, otherwise error code
|
|
||||||
*/
|
|
||||||
ResultVal<bool> SyncRequest() override {
|
ResultVal<bool> SyncRequest() override {
|
||||||
u32* cmd_buff = GetCommandBuffer();
|
u32* cmd_buff = GetCommandBuffer();
|
||||||
auto itr = m_functions.find(cmd_buff[0]);
|
auto itr = m_functions.find(cmd_buff[0]);
|
||||||
|
@ -108,11 +103,6 @@ public:
|
||||||
return MakeResult<bool>(false); // TODO: Implement return from actual function
|
return MakeResult<bool>(false); // TODO: Implement return from actual function
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
|
||||||
* Wait for kernel object to synchronize
|
|
||||||
* @param wait Boolean wait set if current thread should wait as a result of sync operation
|
|
||||||
* @return Result of operation, 0 on success, otherwise error code
|
|
||||||
*/
|
|
||||||
ResultVal<bool> WaitSynchronization() override {
|
ResultVal<bool> WaitSynchronization() override {
|
||||||
// TODO(bunnei): ImplementMe
|
// TODO(bunnei): ImplementMe
|
||||||
ERROR_LOG(OSHLE, "unimplemented function");
|
ERROR_LOG(OSHLE, "unimplemented function");
|
||||||
|
|
Reference in New Issue