Commit Graph

15203 Commits

Author SHA1 Message Date
Morph 53d62eb9bd key_manager: Create the keys directory if it does not exist 2021-02-04 06:05:50 -05:00
bunnei 0c275a6464 Merge pull request #5870 from german77/hanheldfix2
config: Always update handheld config
2021-02-03 19:02:59 -08:00
german 5809b8941e Add footer types and address comments 2021-02-03 20:17:08 -06:00
german 5c9d8e8f39 Fix npad struct to match switchbrew 2021-02-03 20:17:08 -06:00
german 1f204e5930 Adds missing controller types and properties 2021-02-03 20:17:08 -06:00
bunnei 65bd33b7c6 Merge pull request #5863 from ogniK5377/disable-reverb
audren: Disable reverb for the time being
2021-02-03 18:05:54 -08:00
german ebf3784c75 Always update handheld config 2021-02-03 17:48:04 -06:00
bunnei 297e909002 Merge pull request #5848 from ogniK5377/k-resourcelimit
kernel: Rewrite resource limit to be more accurate
2021-02-03 14:53:25 -08:00
Chloe Marcec 6ff08eb44f Simplify limitableresource names 2021-02-03 12:55:16 +11:00
bunnei 6f37a78056 Merge pull request #5842 from german77/userfix
acc: Fix error when second user is selected
2021-02-02 15:43:51 -08:00
bunnei cac3881076 Merge pull request #5841 from german77/username
Avoid overwriting username
2021-02-02 15:04:09 -08:00
german e0c83e305a Prevent over scheduling audio events and terminate properly the motion update event 2021-02-02 10:17:10 -06:00
Morph 922d1556a0 IApplicationFunctions: Implement GetHealthWarningDisappearedSystemEvent 2021-02-02 10:47:38 -05:00
Morph c21d343b04 settings: Log the cache, config, and mod load directories 2021-02-02 04:01:05 -05:00
lat9nq 255834538c video_core: host_shaders: Don't pass --quiet to glslangValidator if unavailable
Prevents CMake from calling `glslangValidator` with `--quiet` when it is
not available, i.e. on older downstream versions from Ubuntu.
2021-02-01 23:39:54 -05:00
bunnei 57d0ac56cc Merge pull request #5861 from german77/HandheldFix
hid: Only update motion for npad and prevent over scheduling events
2021-02-01 18:46:26 -08:00
Chloe Marcec 1c1940200a Compile error 2021-02-02 13:23:34 +11:00
Chloe Marcec 4d7f0c4c07 Address issues 2021-02-02 13:23:00 +11:00
MerryMage 6f76ed25df arm_dynarmic_32: Print out CPSR.T on exception 2021-02-01 18:35:33 +00:00
bunnei eee513213d Merge pull request #5859 from Morph1984/nifm
nifm: Stub GetCurrentNetworkProfile and GetCurrentIpConfigInfo
2021-01-31 21:31:14 -08:00
Ameer J a57a3172ce Merge pull request #5856 from Morph1984/nifm-fix-getappletinfo-stub
nifm: Fix GetAppletInfo stub
2021-01-31 23:33:11 -05:00
Chloe Marcec 6619834395 audren: Disable reverb for the time being
As this is causing issues in a few games, it's best to have it disabled until it's completely implemented
2021-02-01 14:41:58 +11:00
bunnei 179fb1e2f0 Merge pull request #5858 from Morph1984/IsGamePlayRecordingSupported-stub
am/IApplicationFunctions: Stub IsGamePlayRecordingSupported
2021-01-31 18:04:04 -08:00
german 963ce4f5ab Only update motion for npad and prevent over scheduling events 2021-01-31 18:52:38 -06:00
bunnei 693ea6362b Merge pull request #5860 from Morph1984/prepo-transmission-stub
prepo: Stub RequestImmediateTransmission and GetTransmissionStatus
2021-01-31 12:26:00 -08:00
Morph a777002e4c Merge pull request #5846 from ameerj/analog-join
analog_from_button: Fix update_thread.join exception
2021-01-31 23:06:06 +08:00
Morph 200c8bce5a nifm: Stub GetCurrentIpConfigInfo
- Used by Lets Sing 12
2021-01-31 07:36:37 -05:00
Morph af32dc3653 prepo: Stub GetTransmissionStatus 2021-01-31 07:07:11 -05:00
Morph 343ee0fc1f prepo: Stub RequestImmediateTransmission
- Used by Animal Crossing: New Horizons
2021-01-31 07:04:35 -05:00
Morph 130ca0ca61 nifm: Stub GetCurrentNetworkProfile
- Used by Minecraft Bedrock Edition
- Used by Bloons TD 5
2021-01-31 06:56:29 -05:00
Morph 9b855feeec nifm: Add several structs 2021-01-31 06:56:29 -05:00
Morph 5bf0587bee am/IApplicationFunctions: Stub IsGamePlayRecordingSupported
Used by RetroArch
2021-01-31 03:11:03 -05:00
Morph 18c2915be2 bsd: Fix EventFd stub 2021-01-31 02:57:56 -05:00
bunnei bd51df8969 Merge pull request #5855 from Morph1984/bsd-fix-getsockopt-stub
bsd: Fix GetSockOpt stub
2021-01-30 23:21:21 -08:00
Morph 3bd2f586a1 nifm: Fix GetAppletInfo stub 2021-01-31 02:19:36 -05:00
Morph e2b1734183 Merge pull request #5851 from ameerj/pop-inv-stub
am: Stub TryPopFromFriendInvitationStorageChannel
2021-01-31 14:18:40 +08:00
Morph e1ad1c2552 bsd: Fix GetSockOpt stub 2021-01-31 01:08:56 -05:00
ameerj 6b81524050 bsd: Stub EventFd
Used by Family Feud
2021-01-30 21:47:32 -05:00
ameerj 86e8b00299 am: Stub TryPopFromFriendInvitationStorageChannel
Used by Family Feud
2021-01-30 21:43:55 -05:00
Chloe Marcec 7a8501243d fix compile error 2021-01-30 21:51:22 +11:00
Chloe Marcec dea89a59c9 cleanup commenting 2021-01-30 21:20:35 +11:00
Chloe Marcec 3edb06af11 Drop m_ from lock 2021-01-30 21:19:49 +11:00
Chloe Marcec a69befa745 Move to GetGlobalTimeNs, fix GetTotalPhysicalMemoryAvailable 2021-01-30 21:03:10 +11:00
Chloe Marcec 68a52e9050 kernel: Rewrite resource limit to be more accurate
Matches closer to hardware
2021-01-30 20:40:49 +11:00
bunnei aba77ea06a Merge pull request #5779 from bunnei/kthread-rewrite
Rewrite KThread to be more accurate
2021-01-29 23:06:40 -08:00
bunnei 15108fcea7 Merge pull request #5795 from ReinUsesLisp/bytes-to-map-end
video_core/memory_manager: Add BytesToMapEnd
2021-01-29 22:56:29 -08:00
Morph 4128ce3e12 Merge pull request #5838 from german77/prepostub
prepo: Stub GetSystemSessionId
2021-01-30 14:19:59 +08:00
german 11815a3499 Stub GetSystemSessionId 2021-01-29 18:41:28 -06:00
bunnei bef8c080a2 Merge pull request #5805 from german77/HandheldFix
Fix connect and disconnect controller events
2021-01-29 16:39:01 -08:00
ameerj 37e544492e analog_from_button: Fix update_thread.join exception
This commit aims to address an exception that occurs when trying to join the Analog object's update_thread.

By using an atomic bool for the status of the update thread, we ensure its value is consistent across the threads accessing it.
2021-01-29 18:41:22 -05:00
bunnei 46f2ca41a4 Merge pull request #5809 from ogniK5377/FlushAudioOutBuffers
audout: FlushAudioOutBuffers
2021-01-28 21:54:46 -08:00
bunnei 189340d654 hle: kernel: KLightLock: Fix several bugs. 2021-01-28 21:53:21 -08:00
bunnei 4bb6de297f common: common_funcs: Change R_UNLESS to LOG_ERROR. 2021-01-28 21:51:16 -08:00
bunnei 1ebbfe8e3b arm: dynarmic: Reintroduce JIT checks on SaveContext/LoadContext. 2021-01-28 21:50:39 -08:00
bunnei d09ade6cab hle: kernel: KThread: Release thread resource on thread exit. 2021-01-28 21:49:47 -08:00
bunnei a96667d30c yuzu: debugger: Ignore HLE threads. 2021-01-28 21:42:27 -08:00
bunnei 38ae7c53c0 hle: kernel: process: Add state lock. 2021-01-28 21:42:26 -08:00
bunnei 1a1bef5154 hle: kernel: threading: Fix bug with host thread naming. 2021-01-28 21:42:26 -08:00
bunnei bb41b9d462 hle: kernel: k_scheduler_lock: Cleanup. 2021-01-28 21:42:26 -08:00
bunnei 2f34533f47 core: arm: Remove unnecessary JIT checks. 2021-01-28 21:42:26 -08:00
bunnei d685f12dbc common: common_funcs: Log error on R_UNLESS. 2021-01-28 21:42:26 -08:00
bunnei cf3a05cf8c hle: kernel: Allocate a dummy KThread for each host thread, and use it for scheduling. 2021-01-28 21:42:26 -08:00
bunnei 0b307a12f3 hle: kernel: k_scheduler: Use atomics for current_thread, etc. 2021-01-28 21:42:26 -08:00
bunnei 9b0a981710 hle: kernel: k_scheduler: Fix for single core mode. 2021-01-28 21:42:26 -08:00
bunnei 67d28075dd kernel: Fix build errors. 2021-01-28 21:42:26 -08:00
bunnei f6ea864471 core: cpu_manager: Remove unused variable. 2021-01-28 21:42:26 -08:00
bunnei 177b4da4e7 hle: kernel: KScheduler: Introduce thread context_guard. 2021-01-28 21:42:26 -08:00
bunnei f34dd04d09 hle: kernel: Recode implementation of KThread to be more accurate. 2021-01-28 21:42:26 -08:00
bunnei 25cece3cea kernel: svc_types: Add ThreadActivity. 2021-01-28 21:42:26 -08:00
bunnei 589ecb9a75 kernel: KSchedulerPriorityQueue: Lowest priority should be LowestThreadPriority. 2021-01-28 21:42:26 -08:00
bunnei 4440a59cb6 kernel: k_light_lock: Simplify EmuThreadHandle implementation. 2021-01-28 21:42:26 -08:00
bunnei 86206c81c2 hle: kernel: TimeManager: Simplify to not rely on previous EmuThreadHandle implementation. 2021-01-28 21:42:26 -08:00
bunnei 7351708eea common: common_funcs: Add useful kernel macro R_SUCCEED_IF. 2021-01-28 21:42:26 -08:00
bunnei eb3a02a3fd core: hle: kernel: object: Implement Finalize() virtual method. 2021-01-28 21:42:26 -08:00
bunnei 3cefddbb47 core: hle: kernel: svc_results: Populate with several missing error codes. 2021-01-28 21:42:26 -08:00
bunnei ddfa48d704 core: hle: kernel: Implement KLightLock. 2021-01-28 21:42:26 -08:00
bunnei 54620961fb core: hle: kernel: Implement KThreadQueue. 2021-01-28 21:42:25 -08:00
bunnei 39987beb17 common: common_funcs: Add a few more useful macros for kernel code. 2021-01-28 21:42:25 -08:00
bunnei 4ba9d6f969 hle: kernel: KThread: Clean up thread priorities. 2021-01-28 21:42:25 -08:00
bunnei 0ae0bc4340 hle: kernel: KThread: Reorganize thread priority defaults. 2021-01-28 21:42:25 -08:00
bunnei eb396cd021 hle: kernel: KThread: Fix ThreadType definition. 2021-01-28 21:42:25 -08:00
bunnei d49e29d866 hle: kernel: Move single core "phantom mode" out of KThread.
- This is a workaround that does not belong in a kernel primitive.
2021-01-28 21:42:25 -08:00
bunnei e74f682506 hle: kernel: KThread: Remove thread types that do not exist. 2021-01-28 21:42:25 -08:00
bunnei db342cc6f0 arm: arm_dynarmic: Skip calls when JIT is invalid.
- This can happen if called from an idle or suspension thread.
2021-01-28 21:42:25 -08:00
bunnei 3d70b4a4ea core: hle: kernel: Rename Thread to KThread. 2021-01-28 21:42:25 -08:00
german f970b836e5 Fix user changing to 0 if valid 2021-01-28 21:02:25 -06:00
bunnei 9f626d9b94 Merge pull request #5837 from german77/socketstub
sockets: Stub GetSockOpt
2021-01-28 16:28:11 -08:00
german f4442c3456 Avoid overwritting username 2021-01-28 16:58:53 -06:00
LC a4a8cae837 Merge pull request #5836 from ReinUsesLisp/unaligned-constr-sched
vk_scheduler: Fix unaligned placement new expressions
2021-01-28 10:53:15 -05:00
LC a42f1dc30b Merge pull request #5840 from Morph1984/prepo-fix
prepo: Fix BufferDescriptorX invalid buffer index errors and add New variants of SaveReport
2021-01-28 10:52:44 -05:00
LC b925efd12b Merge pull request #5835 from Morph1984/cleanup-sixaxis-fusion
hid: Cleanup SixAxisFusionParameters
2021-01-28 10:51:04 -05:00
Morph 83f6fc1a5f hid: Add static_assert for Parameter size 2021-01-28 09:41:43 -05:00
Morph 7e9385d035 prepo: Fix BufferDescriptorX invalid buffer errors and add "New" variants of SaveReport
The second input buffer could be optional when prepo/srepo is called, test for the availability of the second buffer prior to reading from it.
2021-01-28 01:32:24 -05:00
Morph afa0d5efb3 hle_ipc: Add Can(Read, Write)Buffer
Allows us to test whether a buffer can be read from or written to memory
2021-01-28 01:32:24 -05:00
german 7cb9b24f6d Stub GetSockOpt 2021-01-27 23:18:20 -06:00
ReinUsesLisp 4f807afdc4 vk_scheduler: Fix unaligned placement new expressions
We were accidentaly creating an object in an unaligned memory address.
Fix this by manually aligning the offset.
2021-01-27 22:28:22 -03:00
bunnei a0042f8350 Merge pull request #5786 from ReinUsesLisp/glsl-cbuf
gl_shader_decompiler: Fix constant buffer size calculation
2021-01-27 15:27:53 -08:00
Rodrigo Locatti b8b0524a9b vulkan_device: Blacklist Intel from float16 math (#5798)
Astral Chain crashes Intel's SPIR-V compiler when using fp16.
Disable this while the vendor works on a fix.
2021-01-27 13:31:32 -08:00
bunnei dc5a3313a1 Merge pull request #5778 from ReinUsesLisp/shader-dir
renderer_opengl: Avoid precompiled cache and force NV GL cache directory
2021-01-27 11:34:21 -08:00
Morph d6cb14fbf3 npad: Remove unused device handle parameter 2021-01-27 13:05:31 -05:00
bunnei 07d3a4d538 Merge pull request #5812 from german77/StubSixaxisFusion
HID: Stub Set/Get/Reset SixaxisSensorFusionParameters
2021-01-26 15:58:04 -08:00
bunnei 504d6d523c Merge pull request #5810 from ogniK5377/stereo-vision
hle: Implement remaining services for Stereo Vision
2021-01-26 15:01:01 -08:00
bunnei e002d6a5d4 Merge pull request #5824 from ogniK5377/IPsmSession
psm: IPsmSession
2021-01-26 11:11:29 -08:00
bunnei 1b697f4525 Merge pull request #5774 from ogniK5377/mii-raw-random
mii: Fix BuildRandomStoreData & Cleanup raw_data
2021-01-25 16:41:20 -08:00
bunnei f2624c4eea Merge pull request #5771 from ogniK5377/lm-rework
lm: Recode LM service
2021-01-25 10:18:09 -08:00
Chloe Marcec df783fc0cd Omit system reference 2021-01-25 23:13:37 +11:00
Chloe Marcec 5d4edf4d30 psm: IPsmSession
Used by homebrew menu
2021-01-25 21:37:51 +11:00
bunnei 229aac6d73 Merge pull request #5799 from ogniK5377/event-register-unregister
nvdrv: Unregister already registered events
2021-01-24 23:19:10 -08:00
bunnei fcb5b0762e Merge pull request #5785 from ReinUsesLisp/buffer-dma
video_core/memory_manager: Flush destination buffer on CopyBlock
2021-01-24 22:57:00 -08:00
ReinUsesLisp 6dac6f07c2 Revert "Start of Integer flags implementation"
This reverts #4713. The implementation in that PR is not accurate.
It does not reflect the behavior seen in hardware.
2021-01-25 02:48:03 -03:00
ReinUsesLisp 8778d4a743 vk_graphics_pipeline: Fix narrowing conversion on MSVC 2021-01-24 21:41:29 -03:00
LC 04da2ac057 Merge pull request #5807 from ReinUsesLisp/vc-warnings
video_core: Silence the remaining gcc warnings and enforce them
2021-01-24 17:36:43 -05:00
Rodrigo Locatti bc244a3231 Merge pull request #5363 from ReinUsesLisp/vk-image-usage
vk_texture_cache: Support image store on sRGB images with VkImageViewUsageCreateInfo
2021-01-24 18:44:51 -03:00
bunnei 9b37211cd5 Merge pull request #5151 from comex/xx-vfs
vfs_real: When moving files or directories, don't assume file opening will succeed
2021-01-24 13:42:51 -08:00
ReinUsesLisp 1d3c309eac vk_texture_cache: Support image store on sRGB images with VkImageViewUsageCreateInfo
Vulkan 1.0 didn't support creating sRGB image views on an ABGR8 VkImage
with storage usage bits. VK_KHR_maintenance2 addressed this allowing to
reduce the usage bits on a VkImageView.

To allow image store on non-sRGB image views when the VkImage is created
with sRGB, always create VkImages without sRGB and add the sRGB format
on the view.
2021-01-24 18:16:43 -03:00
ReinUsesLisp 1aa67cb31c vulkan_device: Lift VK_EXT_extended_dynamic_state blacklist on RDNA
It seems to be safe to use this on new drivers.
2021-01-24 20:21:11 -03:00
ReinUsesLisp ae349957c3 cmake: Enforce -Warray-bounds and -Wmissing-field-initializers globally 2021-01-24 17:31:29 -03:00
bunnei 1118154fda Merge pull request #5796 from ReinUsesLisp/vertex-a-bypass-vk
vk_pipeline_cache: Properly bypass VertexA shaders
2021-01-24 11:22:58 -08:00
german 264bcb9e1d Stub Set/Get/Reset SixaxisSensorFusionParameters 2021-01-24 11:28:52 -06:00
Chloe Marcec 3aa402b373 Print Process ID and Thread ID as hex 2021-01-25 02:47:40 +11:00
Chloe Marcec dba86775cb hle: Implement remaining services for Stereo Vision
Used by Zelda Breath of the Wild, Super Mario Odyssey and Nintendo Labo
2021-01-25 00:34:01 +11:00
LC b523bc3952 Merge pull request #5808 from ReinUsesLisp/glslang-quiet
host_shaders/cmake: Pass --quiet to glslang to keep it quiet
2021-01-24 05:01:10 -05:00
Chloe Marcec b467478dcf audout: FlushAudioOutBuffers
Fixes Devil May Cry
2021-01-24 19:13:34 +11:00
ReinUsesLisp 459be8c220 host_shaders/cmake: Pass --quiet to glslang to keep it quiet
Silences noisy builds on toolchains.
2021-01-24 04:55:23 -03:00
ReinUsesLisp bd946059c0 video_core/cmake: Enforce -Warray-bounds and -Wmissing-field-initializers 2021-01-24 04:42:41 -03:00
bunnei 79efa66bff Merge pull request #5806 from bunnei/am-stub
hle: service: am: Stub ILibraryAppletAccessor::PresetLibraryAppletGpuTimeSliceZero.
2021-01-23 23:37:05 -08:00
ReinUsesLisp 7afc85ba3a video_core: Silence -Wmissing-field-initializers warnings 2021-01-24 04:32:19 -03:00
ReinUsesLisp 928831c1cc maxwell_3d: Silence array bounds warnings 2021-01-24 04:31:41 -03:00
ReinUsesLisp 9d882e0000 maxwell_to_vk: Silence -Wextra warnings about using different enum types 2021-01-24 04:03:36 -03:00
german c806340f31 Fix connect and disconnect controller events 2021-01-23 22:59:44 -06:00
comex 6ea2d44f1e vfs_real: When moving files or directories, don't assume file opening will succeed
Found this via a warning, but it's a substantive fix.

Since this is only for a cache, it should be safe to silently drop the
entry if opening fails.  I think.
2021-01-23 16:19:29 -05:00
Levi Behunin 5a513f7bd6 shader_ir: Fix comment typo 2021-01-23 13:16:37 -05:00
Morph 6b5e5ad224 sdl_impl: Set the maximum vibration duration to 1 second 2021-01-23 08:06:07 -05:00
Chloe Marcec 586c1cee87 Simplify condition 2021-01-23 22:12:05 +11:00
Chloe Marcec 8687476cd1 nvdrv: Unregister already registered events 2021-01-23 22:02:14 +11:00
LC 964cd9e0f3 Merge pull request #5797 from ReinUsesLisp/nsight-aftermath-build
nsight_aftermath_tracker: Fix build issues when enabled
2021-01-23 05:40:50 -05:00
Chloe Marcec 1a88d8b4e6 Clamp string reads to buffer size 2021-01-23 18:24:57 +11:00
ReinUsesLisp 80f235a8cc video_core/cmake: Properly generate fatal errors on Aftermath
Fix "message(ERROR ..." to "message(FATAL_ERROR ..." to properly stop
cmake when Nsight Aftermath can't be configured.
2021-01-23 04:15:30 -03:00
ReinUsesLisp fd5e76dc87 nsight_aftermath_tracker: Fix build issues when enabled
Fixes a bunch of build errors when Nsight Aftermath is properly enabled.
2021-01-23 04:13:39 -03:00
bunnei a2d9c802e5 Merge pull request #5776 from ogniK5377/lbl
lbl: Implement most of lbl
2021-01-22 23:13:23 -08:00
ReinUsesLisp 23a5aed188 vk_pipeline_cache: Properly bypass VertexA shaders
The VertexA stage is not yet implemented, but Vulkan is adding its
descriptors, causing a discrepancy in the pushed descriptors and the
template. This generally ends up in a driver side crash.

Bypass the VertexA stage for now.
2021-01-23 03:59:59 -03:00
bunnei ececdde128 Merge pull request #4713 from behunin/int-flags
Start of Integer flags implementation
2021-01-22 21:57:14 -08:00
bunnei 4c09659091 Merge pull request #5765 from ogniK5377/StoreSaveDataThumbnail-stub
acc: Stub StoreSaveDataThumbnail
2021-01-22 21:51:54 -08:00
ReinUsesLisp 0e885adf4a video_core/memory_manager: Add BytesToMapEnd
Track map address sizes in a flat ordered map and add a method to query
the number of bytes until the end of a map in a given address.
2021-01-22 18:31:12 -03:00
bunnei 16a6a7f9d9 common: Add missing include to bit_util.h 2021-01-21 15:30:28 -08:00
ReinUsesLisp ff383ffbcd gl_shader_decompiler: Fix constant buffer size calculation
The divide logic was wrong and can cause an uniform buffer size
overflow.
2021-01-21 19:47:41 -03:00
bunnei 58ee0b9f4e Merge pull request #5781 from lioncash/bits
bit_util: Unify implementations of MostSignificantBit32/MostSignificantBit64
2021-01-21 14:45:40 -08:00
ReinUsesLisp 220ba5933c video_core/memory_manager: Remove unused CopyBlockUnsafe
This function was not being used.
2021-01-21 19:16:06 -03:00
ReinUsesLisp 85390839b0 video_core/memory_manager: Flush destination buffer on CopyBlock
When we copy into a buffer, it might contain data modified from the GPU
on the same pages. Because of this, we have to flush the contents before
writing new data.

An alternative approach would be to write the data in place, but games
can also write data in other ways, invalidating our contents.

Fixes geometry in Zombie Panic in Wonderland DX.
2021-01-21 19:16:06 -03:00
ReinUsesLisp 5c2fdf4e60 video_core/memory_manager: Add GPU address based flush method
Allow flushing rasterizer contents based on a GPU address.
2021-01-21 19:16:05 -03:00