summaryrefslogtreecommitdiff
path: root/src/core (follow)
Commit message (Collapse)AuthorAgeFilesLines
...
| * | XCI: Add function for checking the existence of the program NCAGravatar Lioncash2018-10-163-7/+8
| |/ | | | | | | | | | | The only reason the getter existed was to check whether or not the program NCA was null. Instead, we can just provide a function to query for the existence of it, instead of exposing it entirely.
* | Merge pull request #1444 from ogniK5377/better-hidGravatar bunnei2018-10-1722-648/+1720
|\ \ | | | | | | "Better Hid" Rework Part 1
| * | Using dual joycons as the default controllerGravatar David Marcec2018-10-183-77/+59
| | | | | | | | | | | | Reason for the change is to allow both docked and undocked mode to work
| * | WipGravatar David Marcec2018-10-122-3/+23
| | |
| * | Dynamically decide handheld variant based on supported npad id priorityGravatar David Marcec2018-10-123-19/+62
| | | | | | | | | | | | Kirby input still doesn't work, should fix a lot of other games
| * | Added BeginPermitVibrationSession and EndPermitVibrationSessionGravatar David Marcec2018-10-113-2/+26
| | | | | | | | | | | | Used by Mario Party
| * | Added GetLedPattern and HandheldVariantGravatar David Marcec2018-10-103-6/+63
| | | | | | | | | | | | HandheldVariant is for specific games which expect handheld controllers to be at position 8(kirby), however this doesn't fix all games as some games require handhelds to be at position 0(snipperclips)
| * | Kirby expects handheld controllers to be at position 8Gravatar David Marcec2018-10-101-2/+8
| | |
| * | Added the ability to "disconnect" individual npadsGravatar David Marcec2018-10-103-16/+40
| | | | | | | | | | | | Fixes arms
| * | Removed unneeded forward declarationsGravatar David Marcec2018-10-102-13/+2
| | |
| * | Addressed changes for better hidGravatar David Marcec2018-10-1019-167/+238
| | |
| * | "Better Hid" rework part 1Gravatar David Marcec2018-10-1022-644/+1500
| | |
* | | Merge pull request #1497 from bunnei/flush-framebuffersGravatar bunnei2018-10-172-3/+3
|\ \ \ | | | | | | | | Implement flushing in the rasterizer cache
| * | | config: Rename use_accurate_framebuffers -> use_accurate_gpu_emulation.Gravatar bunnei2018-10-162-3/+3
| | |/ | |/| | | | | | | - This will be used as a catch-all for slow-but-accurate GPU emulation paths.
* | | Merge pull request #1498 from lioncash/aslrGravatar bunnei2018-10-174-28/+44
|\ \ \ | | | | | | | | svc: Clarify enum values for AddressSpaceBaseAddr and AddressSpaceSize in svcGetInfo()
| * | | svc: Clarify enum values for AddressSpaceBaseAddr and AddressSpaceSize in ↵Gravatar Lioncash2018-10-144-28/+44
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | svcGetInfo() So, one thing that's puzzled me is why the kernel seemed to *not* use the direct code address ranges in some cases for some service functions. For example, in svcMapMemory, the full address space width is compared against for validity, but for svcMapSharedMemory, it compares against 0xFFE00000, 0xFF8000000, and 0x7FF8000000 as upper bounds, and uses either 0x200000 or 0x8000000 as the lower-bounds as the beginning of the compared range. Coincidentally, these exact same values are also used in svcGetInfo, and also when initializing the user address space, so this is actually retrieving the ASLR extents, not the extents of the address space in general.
* | | | Merge pull request #1509 from DarkLordZach/device-save-dataGravatar bunnei2018-10-171-1/+12
|\ \ \ \ | |_|/ / |/| | | savedata_factory: Add DeviceSaveData and fix TemporaryStorage
| * | | savedata_factory: Add TemporaryStorage SaveDataSpaceIdGravatar Zach Hilman2018-10-161-1/+4
| | | | | | | | | | | | | | | | Required for TemporaryStorage saves (in addition to SaveDataType)
| * | | savedata_factory: Add support for DeviceSaveDataGravatar Zach Hilman2018-10-161-0/+8
| | | | | | | | | | | | | | | | Uses the same path as SaveData except with UID 0. Adds a warning if UID is not 0.
* | | | Merge pull request #1443 from DarkLordZach/lower-loader-logs-1Gravatar bunnei2018-10-162-3/+9
|\ \ \ \ | | | | | | | | | | content_archive/patch_manager: Lower log levels to eliminate some unnecessary logs
| * | | | patch_manager: Move non-Program RomFS patch log to DebugGravatar Zach Hilman2018-10-121-2/+8
| | | | | | | | | | | | | | | | | | | | Normal Program-type patches will still be logged to aid in debugging, but for others (mainly Control), it was moved to Debug.
| * | | | content_archive: Move get key log to Trace levelGravatar Zach Hilman2018-10-121-1/+1
| | | | | | | | | | | | | | | | | | | | Avoids printing live keys in the general log.
* | | | | Implement VI ConvertScalingMode (#1475)Gravatar David2018-10-161-1/+49
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * Implement VI ConvertScalingMode * Fixed push enum * Scale mode now uses Nintendo scale mode as an enum as well
* | | | | Merge pull request #1502 from lioncash/uniqueGravatar bunnei2018-10-1611-56/+71
|\ \ \ \ \ | | | | | | | | | | | | core: Convert shared_ptr instances into unique_ptr instances where applicable for System and Cpu
| * | | | | core_cpu: Make Cpu scheduler instances unique_ptrs instead of shared_ptrsGravatar Lioncash2018-10-159-27/+45
| | | | | |
| * | | | | core: Make the live Cpu instances unique_ptrs instead of shared_ptrsGravatar Lioncash2018-10-151-9/+9
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | There's no need for shared ownership here, as the only owning class instance of those Cpu instances is the System class itself. We can also make the thread_to_cpu map use regular pointers instead of shared_ptrs, given that the Cpu instances will always outlive the cases where they're used with that map.
| * | | | | core: Make the exclusive monitor a unique_ptr instead of a shared_ptrGravatar Lioncash2018-10-155-15/+13
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Like the barrier, this is owned entirely by the System and will always outlive the encompassing state, so shared ownership semantics aren't necessary here.
| * | | | | core: Make CPUBarrier a unique_ptr instead of a shared_ptrGravatar Lioncash2018-10-153-11/+10
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This will always outlive the Cpu instances, since it's destroyed after we destroy the Cpu instances on shutdown, so there's no need for shared ownership semantics here.
* | | | | | file_sys/registered_cache: Use unique_ptr and regular pointers instead of ↵Gravatar Lioncash2018-10-1610-42/+41
| |_|/ / / |/| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | shared_ptrs where applicable The data retrieved in these cases are ultimately chiefly owned by either the RegisteredCache instance itself, or the filesystem factories. Both these should live throughout the use of their contained data. If they don't, it should be considered an interface/design issue, and using shared_ptr instances here would mask that, as the data would always be prolonged after the main owner's lifetime ended. This makes the lifetime of the data explicit and makes it harder to accidentally create cyclic references. It also makes the interface slightly more flexible than the previous API, as a shared_ptr can be created from a unique_ptr, but not the other way around, so this allows for that use-case if it ever becomes necessary in some form.
* | | | | Merge pull request #1473 from lioncash/cmakeGravatar bunnei2018-10-151-2/+2
|\ \ \ \ \ | | | | | | | | | | | | web_service: Make linkage of web_service-related externals and the library private
| * | | | | core/CMakeLists: Make all web_service-related libraries privateGravatar Lioncash2018-10-101-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Now that all external dependencies are hidden, we can remove json-headers from the publically linked libraries, as the use of this library is now completely hidden from external users of the web_service library. We can also make the web_services library private as well, considering it's not a requirement. If a library needs to link in web_service, it should be done explicitly -- not via indirect linking.
| * | | | | core/CMakeLists: Use target_compile_definitions instead of add_definitions ↵Gravatar Lioncash2018-10-101-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | for specifying ENABLE_WEB_SERVICE Avoids introducing the definition to the whole directory space and localizes it to being added to the library that needs it.
* | | | | | file_sys/control_metadata: Get rid of magic constantsGravatar Lioncash2018-10-151-3/+6
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | These are just the size of the data being passed in, so we can specify that via the size() member function.
* | | | | | Merge pull request #1494 from DarkLordZach/aoc-signature-fixesGravatar bunnei2018-10-153-3/+20
|\ \ \ \ \ \ | | | | | | | | | | | | | | aoc: Fix various bugs in current AOC implementation
| * | | | | | aoc: Read DLC base title ID from RegisteredCacheGravatar Zach Hilman2018-10-143-2/+18
| | | | | | | | | | | | | | | | | | | | | Falls back to title ID + 0x1000, which is what HOS does.
| * | | | | | aoc: Return size in ListAddOnContentGravatar Zach Hilman2018-10-131-1/+2
| | | | | | |
* | | | | | | Merge pull request #1499 from lioncash/nroGravatar bunnei2018-10-157-28/+39
|\ \ \ \ \ \ \ | | | | | | | | | | | | | | | | nro/nso: Minor error handling changes
| * | | | | | | nso: Return an optional address from LoadModuleGravatar Lioncash2018-10-155-16/+29
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | If a malformed NSO is attempted to be loaded, we shouldn't continue onwards. We should be reporting an error and bailing out.
| * | | | | | | nso: Make LoadModule take a VfsFile by const referenceGravatar Lioncash2018-10-143-11/+9
| | | | | | | |
| * | | | | | | nro: Make LoadNro take a VfsFile by const referenceGravatar Lioncash2018-10-142-6/+6
| | |_|_|_|/ / | |/| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This function doesn't need to care about ownership semantics, so we can just pass it a reference to the file itself, rather than a std::shared_ptr alias.
* | | | | | | crypto: Various crypto fixes for quickstart guideGravatar Zach Hilman2018-10-141-2/+2
| |_|_|/ / / |/| | | | |
* | | | | | Merge pull request #1486 from lioncash/fileGravatar bunnei2018-10-144-63/+72
|\ \ \ \ \ \ | | | | | | | | | | | | | | key_manager/partition_data_manager: Minor changes
| * | | | | | partition_data_manager: Reserve and insert data within output vector in ↵Gravatar Lioncash2018-10-131-20/+16
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | DecryptPackage2() We can just reserve the memory then perform successive insertions instead of needing to use memcpy. This also avoids the need to zero out the output vector's memory before performing the insertions. We can also std::move the output std::vector into the destination so that we don't need to make a completely new copy of the vector, getting rid of an unnecessary allocation. Additionally, we can use iterators to determine the beginning and end ranges of the std::vector instances that comprise the output vector, as the end of one range just becomes the beginning for the next successive range, and since std::vector's iterator constructor copies data within the range [begin, end), this is more straightforward and gets rid of the need to have an offset variable that keeps getting incremented to determine where to do the next std::memcpy.
| * | | | | | partition_data_manager: Remove unused std::map instance within DecryptPackage2()Gravatar Lioncash2018-10-131-2/+0
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Aside from emplacing elements into the map, the map itself is never actually queried for contained data.
| * | | | | | partition_data_manager: Take package2_keys by const referenceGravatar Lioncash2018-10-132-2/+3
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | These are only ever read from, so we don't need to make a copy of all the keys here.
| * | | | | | partition_data_manager: Move IV data to where it's needed in DecryptPackage2()Gravatar Lioncash2018-10-131-3/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Given it's only used in one spot and has a fairly generic name, we can just specify it directly in the function call. This also the benefit of automatically moving it.
| * | | | | | partition_data_manager: Remove commented out codeGravatar Lioncash2018-10-131-2/+0
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Commented out code shouldn't be left in without a reason indicating why in a comment.
| * | | | | | key_manager/partition_data_manager: Silence truncation compiler warningsGravatar Lioncash2018-10-134-10/+15
| | | | | | |
| * | | | | | partition_data_manager: Dehardcode array boundsGravatar Lioncash2018-10-132-7/+12
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Instead, we can make it part of the type and make named variables for them, so they only require one definition (and if they ever change for whatever reason, they only need to be changed in one spot).
| * | | | | | partition_data_manager: Take VirtualFile by const reference in constructorGravatar Lioncash2018-10-132-2/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Given the VirtualFile instance isn't stored into the class as a data member, or written to, this can just be turned into a const reference, as the constructor doesn't need to make a copy of it.