| Age | Commit message (Collapse) | Author |
|
A non-existent parameter was left in some formatting calls (the logging
macro for which only does anything meaningful on debug builds)
|
|
Changed logging to be "Log before execution", Added more error logging, all services/svc should now log on some level
|
|
The opposite of the getter functions, this function sets the limit value
for a particular ResourceLimit resource category, with the restriction
that the new limit value must be equal to or greater than the current
resource value. If this is violated, then ERR_INVALID_STATE is returned.
e.g.
Assume:
current[Events] = 10;
limit[Events] = 20;
a call to this service function lowering the limit value to 10 would be
fine, however, attempting to lower it to 9 in this case would cause an
invalid state error.
|
|
This kernel service function is essentially the exact same as
svcGetResourceLimitLimitValue(), with the only difference being that it
retrieves the current value for a given resource category using the
provided resource limit handle, rather than retrieving the limiting
value of that resource limit instance.
Given these are exactly the same and only differ on returned values, we
can extract the existing code for svcGetResourceLimitLimitValue() to
handle both values.
|
|
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.
|
|
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.
|
|
|
|
|
|
|
|
|
|
services should now log on some level
|
|
|
|
These don't depend on class state, and are effectively implementation
details, so they can go into the cpp file .
|
|
The previous handle table size is a holdover from Citra. The actual
handle table construct on Horizon only allows for a maximum of 1024
entries.
|
|
We don't need to potentially inline the teardown logic of all of the
handle instances.
|
|
kernel/shared_memory: Make data members private, plus minor interface changes
|
|
<random> isn't necesary directly within the header and can be placed in
the cpp file where its needed. Avoids propagating random generation
utilities via a header file.
|
|
am: Implement HLE software keyboard applet
|
|
Cleans out the citra/3DS-specific implementation details that don't
apply to the Switch. Sets the stage for implementing ResourceLimit
instances properly.
While we're at it, remove the erroneous checks within CreateThread() and
SetThreadPriority(). While these are indeed checked in some capacity,
they are not checked via a ResourceLimit instance.
In the process of moving out Citra-specifics, this also replaces the
system ResourceLimit instance's values with ones from the Switch.
|
|
reference rather than as a pointer
Both member functions assume the passed in target process will not be
null. Instead of making this assumption implicit, we can change the
functions to be references and enforce this at the type-system level.
|
|
GetPointer()
Given this doesn't mutate instance state, we can provide a
const-qualified variant as well.
|
|
Keeps the interface consistent with the regular Create() function.
|
|
Makes the interface nicer to use in terms of 64-bit code, as it makes it
less likely for one to get truncation warnings (and also makes sense in
the context of the rest of the interface where 64-bit types are used for
sizes and offsets
|
|
Rather than allow unfettered access to the class internals, we hide all
members by default and create and API that other code can operate
against.
|
|
ldr_ro: Complete LDR:RO implementation
|
|
svc: ResetSignal is not stubbed
|
|
https://user-images.githubusercontent.com/20753089/48677874-b8e01c80-eb7b-11e8-8043-b99faa29022c.PNG
|
|
|
|
Seems to be used and created identically to SharedMemory, so just reuse that.
|
|
|
|
Similar to PR 1706, which cleans up the error codes for the filesystem
code, but done for the kernel error codes. This removes the ErrCodes
namespace and specifies the errors directly. This also fixes up any
straggling lines of code that weren't using the named error codes where
applicable.
|
|
Implement SetMemoryPermission
|
|
kernel/thread: Deduplicate scheduler switching code
|
|
Credits to Subv
|
|
svc: Use proper random entropy generation algorithm
|
|
The code in both places was the same verbatim, so we can extract it to a
function to deduplicate the logic.
|
|
Now that we've moved all of the heap-related stuff to the VMManager
class, we can unstub this function, as the necessary members are visible
now.
|
|
class and into the vm manager
Avoids a breach of responsibilities in the interface and keeps the
direct code for memory management within the VMManager class.
|
|
|
|
|
|
* svcBreak now dumps information from the debug buffer passed
info1 and info2 seem to somtimes hold an address to a buffer, this is usually 4 bytes or the size of the int and contains an error code. There's other circumstances where it can be something different so we hexdump these to examine them at a later date.
* Addressed comments
|
|
|
|
|
|
Cleans up unused includes and trims off some dependencies on externals.
|
|
* get rid of boost::optional
* Remove optional references
* Use std::reference_wrapper for optional references
* Fix clang format
* Fix clang format part 2
* Adressed feedback
* Fix clang format and MacOS build
|
|
hle_ipc: Make GetDomainMessageHeader return a regular pointer
|
|
Gets rid of the need to call the getter and then check for null.
|
|
Nothing requires the shared owner ship here, so we can just return a
plain pointer.
|
|
|
|
Nothing from this enum is intended to be used outside of this function.
|