1. 27 Nov, 2018 2 commits
    • Lioncash's avatar
      svc: Implement svcGetResourceLimitLimitValue() · 1d6399c2
      Lioncash authored
      This kernel service function retrieves the maximum allowable value for
      a provided resource category for a given resource limit instance. Given
      we already have the functionality added to the resource limit instance
      itself, it's sufficient to just hook it up.
      
      The error scenarios for this are:
      
      1. If an invalid resource category type is provided, then ERR_INVALID_ENUM is returned.
      
      2. If an invalid handle is provided, then ERR_INVALID_HANDLE is returned (bad thing goes in, bad thing goes out, as one would expect).
      
      If neither of the above error cases occur, then the out parameter is
      provided with the maximum limit value for the given category and success
      is returned.
      1d6399c2
    • Lioncash's avatar
      svc: Implement svcCreateResourceLimit() · 4ef2af8c
      Lioncash authored
      This function simply creates a ResourceLimit instance and attempts to
      create a handle for it within the current process' handle table. If the
      kernal fails to either create the ResourceLimit instance or create a
      handle for the ResourceLimit instance, it returns a failure code
      (OUT_OF_RESOURCE, and HANDLE_TABLE_FULL respectively). Finally, it exits
      by providing the output parameter with the handle value for the
      ResourceLimit instance and returning that it was successful.
      
      Note: We do not return OUT_OF_RESOURCE because, if yuzu runs out of
      available memory, then new will currently throw. We *could* allocate the
      kernel instance with std::nothrow, however this would be inconsistent
      with how all other kernel objects are currently allocated.
      4ef2af8c
  2. 26 Nov, 2018 6 commits
  3. 25 Nov, 2018 6 commits
  4. 24 Nov, 2018 17 commits
  5. 23 Nov, 2018 9 commits