[Zion] Don't ignore DriverManager Register return code.

This commit is contained in:
Drew Galbraith 2023-11-25 13:06:14 -08:00
parent 838ef01a2a
commit f9ce4a4a8e
2 changed files with 4 additions and 3 deletions

View File

@ -15,7 +15,8 @@ class DriverManager {
void WriteMessage(uint64_t irq_num, IpcMessage&& message);
glcr::ErrorCode RegisterListener(uint64_t irq_num, glcr::RefPtr<Port> port);
[[nodiscard]] glcr::ErrorCode RegisterListener(uint64_t irq_num,
glcr::RefPtr<Port> port);
private:
glcr::HashMap<uint64_t, glcr::RefPtr<Port>> driver_map_;

View File

@ -160,9 +160,9 @@ glcr::ErrorCode IrqRegister(ZIrqRegisterReq* req) {
auto& proc = gScheduler->CurrentProcess();
glcr::RefPtr<Port> port = glcr::MakeRefCounted<Port>();
*req->port_cap = proc.AddNewCapability(port);
DriverManager::Get().RegisterListener(req->irq_num, port);
return glcr::OK;
return DriverManager::Get().RegisterListener(req->irq_num, port);
}
glcr::ErrorCode EndpointCreate(ZEndpointCreateReq* req) {