kernel/svc_types: refresh

This commit is contained in:
Liam 2022-11-03 10:22:05 -04:00
parent 770f23db34
commit 4eece4d35d
19 changed files with 562 additions and 136 deletions

View file

@ -31,7 +31,7 @@ ServiceContext::~ServiceContext() {
Kernel::KEvent* ServiceContext::CreateEvent(std::string&& name) {
// Reserve a new event from the process resource limit
Kernel::KScopedResourceReservation event_reservation(process,
Kernel::LimitableResource::Events);
Kernel::LimitableResource::EventCountMax);
if (!event_reservation.Succeeded()) {
LOG_CRITICAL(Service, "Resource limit reached!");
return {};

View file

@ -34,8 +34,8 @@ void Controller::CloneCurrentObject(Kernel::HLERequestContext& ctx) {
// once this is a proper process
// Reserve a new session from the process resource limit.
Kernel::KScopedResourceReservation session_reservation(&process,
Kernel::LimitableResource::Sessions);
Kernel::KScopedResourceReservation session_reservation(
&process, Kernel::LimitableResource::SessionCountMax);
ASSERT(session_reservation.Succeeded());
// Create the session.