aboutsummaryrefslogtreecommitdiff
path: root/src/core
AgeCommit message (Collapse)Author
2019-02-27Merge pull request #2170 from lioncash/emu-windowbunnei
core/frontend/emu_window: Make ClipToTouchScreen a const member function
2019-02-27Merge pull request #2161 from lioncash/handle-tablebunnei
kernel/handle_table: Allow process capabilities to limit the handle table size
2019-02-27core/frontend/emu_window: Make ClipToTouchScreen a const member functionLioncash
This member function doesn't modify instance state, so it can have the const specifier applied to it.
2019-02-27audio_core/audio_renderer: Name previously unknown parameters of ↵Lioncash
AudioRendererParameter Provides names for previously unknown entries (aside from the two u8 that appear to be padding bytes, and a single word that also appears to be reserved or padding). This will be useful in subsequent changes when unstubbing behavior related to the audio renderer services.
2019-02-27common/math_util: Move contents into the Common namespaceLioncash
These types are within the common library, so they should be within the Common namespace.
2019-02-26common/vector_math: Move Vec[x] types into the Common namespaceLioncash
These types are within the common library, so they should be using the Common namespace.
2019-02-26service/vi: Unstub GetDisplayServiceLioncash
This function is also supposed to check its given policy type with the permission of the service itself. This implements the necessary machinery to unstub these functions. Policy::User seems to just be basic access (which is probably why vi:u is restricted to that policy), while the other policy seems to be for extended abilities regarding which displays can be managed and queried, so this is assumed to be for a background compositor (which I've named, appropriately, Policy::Compositor).
2019-02-26core/ipc_helper: Allow popping all signed value types with RequestParserLioncash
There's no real reason this shouldn't be allowed, given some values sent via a request can be signed. This also makes it less annoying to work with popping enum values, given an enum class with no type specifier will work out of the box now. It's also kind of an oversight to allow popping s64 values, but nothing else.
2019-02-26service/vi: Remove use of a module classLioncash
This didn't really provide much benefit here, especially since the subsequent change requires that the behavior for each service's GetDisplayService differs in a minor detail. This also arguably makes the services nicer to read, since it gets rid of an indirection in the class hierarchy.
2019-02-25Merge pull request #2156 from FreddyFunk/patch-1bunnei
file_sys/vfs_vector: Fix ignored offset on Write
2019-02-25kernel/handle_table: Make local variables as const where applicableLioncash
Makes immutable state explicit.
2019-02-25kernel/handle_table: Allow process capabilities to limit the handle table sizeLioncash
The kernel allows restricting the total size of the handle table through the process capability descriptors. Until now, this functionality wasn't hooked up. With this, the process handle tables become properly restricted. In the case of metadata-less executables, the handle table will assume the maximum size is requested, preserving the behavior that existed before these changes.
2019-02-25kernel/handle-table: In-class initialize data membersLioncash
Directly initializes members where applicable.
2019-02-25kernel/handle_table: Resolve truncation warningsLioncash
Avoids implicit truncation warnings from u32 -> u16 (the truncation is desirable behavior here).
2019-02-25service/vi: Update IManagerDisplayService's function tableLioncash
Amends it to add the 7.0.0+ CreateStrayLayer function.
2019-02-25file_sys/vfs_vector: Fix ignored offset on WriteFrederic L
2019-02-21service/nvflinger: Store BufferQueue instances as regular data membersLioncash
The NVFlinger service is already passed into services that need to guarantee its lifetime, so the BufferQueue instances will already live as long as they're needed. Making them std::shared_ptr instances in this case is unnecessary.
2019-02-21service/vi/vi_layer: Convert Layer struct into a classLioncash
Like the previous changes made to the Display struct, this prepares the Layer struct for changes to its interface. Given Layer will be given more invariants in the future, we convert it into a class to better signify that.
2019-02-21service/nvflinger: Move display specifics over to vi_displayLioncash
With the display and layer structures relocated to the vi service, we can begin giving these a proper interface before beginning to properly support the display types. This converts the display struct into a class and provides it with the necessary functions to preserve behavior within the NVFlinger class.
2019-02-20Merge pull request #2130 from lioncash/system_enginebunnei
video_core: Remove usages of System::GetInstance() within the engines
2019-02-20Fixes Unicode Key File Directories (#2120)Jungy
* Fixes Unicode Key File Directories Adds code so that when loading a file it converts to UTF16 first, to ensure the files can be opened. Code borrowed from FileUtil::Exists. * Update src/core/crypto/key_manager.cpp Co-Authored-By: Jungorend <Jungorend@users.noreply.github.com> * Update src/core/crypto/key_manager.cpp Co-Authored-By: Jungorend <Jungorend@users.noreply.github.com> * Using FileUtil instead to be cleaner. * Update src/core/crypto/key_manager.cpp Co-Authored-By: Jungorend <Jungorend@users.noreply.github.com>
2019-02-19service/nvflinger: Relocate definitions of Layer and Display to the vi serviceLioncash
These are more closely related to the vi service as opposed to the intermediary nvflinger. This also places them in their relevant subfolder, as future changes to these will likely result in subclassing to represent various displays and services, as they're done within the service itself on hardware. The reasoning for prefixing the display and layer source files is to avoid potential clashing if two files with the same name are compiled (e.g. if 'display.cpp/.h' or 'layer.cpp/.h' is added to another service at any point), which MSVC will actually warn against. This prevents that case from occurring. This also presently coverts the std::array introduced within f45c25aabacc70861723a7ca1096a677bd987487 back to a std::vector to allow the forward declaration of the Display type. Forward declaring a type within a std::vector is allowed since the introduction of N4510 (http://www.open-std.org/jtc1/sc22/wg21/docs/papers/2015/n4510.html) by Zhihao Yuan.
2019-02-16Corrections, documenting and fixes.Fernando Sahmkow
2019-02-16address_arbiter: Use nested namespaces where applicableLioncash
A fairly trivial change. Other sections of the codebase use nested namespaces instead of separate namespaces here. This one must have just been overlooked.
2019-02-15video_core: Remove usages of System::GetInstance() within the enginesLioncash
Avoids the use of the global accessor in favor of explicitly making the system a dependency within the interface.
2019-02-15Use u128 on Clock Cycles calculation.Fernando Sahmkow
2019-02-15Correct CNTPCT to use Clock Cycles instead of Cpu Cycles.Fernando Sahmkow
2019-02-15core_timing: Convert core timing into a classLioncash
Gets rid of the largest set of mutable global state within the core. This also paves a way for eliminating usages of GetInstance() on the System class as a follow-up. Note that no behavioral changes have been made, and this simply extracts the functionality into a class. This also has the benefit of making dependencies on the core timing functionality explicit within the relevant interfaces.
2019-02-13Merge pull request #2115 from lioncash/localbunnei
core_timing: Make EmptyTimedCallback a local variable
2019-02-12threadsafe_queue: Remove NeedSize template parameterLioncash
The necessity of this parameter is dubious at best, and in 2019 probably offers completely negligible savings as opposed to just leaving this enabled. This removes it and simplifies the overall interface.
2019-02-12core_timing: Make EmptyTimedCallback a local variableLioncash
Given this is only used in one place, it can be moved closest to its usage site.
2019-02-12core_timing: Rename CoreTiming namespace to Core::TimingLioncash
Places all of the timing-related functionality under the existing Core namespace to keep things consistent, rather than having the timing utilities sitting in its own completely separate namespace.
2019-02-08nvdisp_disp0: change drawing message log level from Warning to TraceTobias
This is a leftover from the early yuzu days. We shouldn't log every time when we are drawing by default, so let's change the log level to Trace.
2019-02-06Merge pull request #2091 from FearlessTobi/port-4603bunnei
Port citra-emu/citra#4603: "gdbstub: only let Execute breakpoints write/restore BKPT opcodes into target memory"
2019-02-06gl_shader_cache: Link loading screen with disk shader cache loadReinUsesLisp
2019-02-06gl_shader_disk_cache: Pass core system as argument and guard against games ↵ReinUsesLisp
without title ids
2019-02-06settings: Hide shader cache behind a settingReinUsesLisp
2019-02-06rasterizer_interface: Add disk cache entry for the rasterizerReinUsesLisp
2019-02-06gdbstub: only let Execute breakpoints write/restore BKPT opcodes into target ↵Dimitri ALBORA
memory
2019-02-06remove all occurance of specifying endianness inside BitFieldWeiyi Wang
This commit it automatically generated by command in zsh: sed -i -- 's/BitField<\(.*\)_le>/BitField<\1>/g' **/*(D.) BitField is now aware to endianness and default to little endian. It expects a value representation type without storage specification for its template parameter.
2019-02-05service/nvflinger,service/vi: Handle failure cases with exposed APILioncash
Converts many of the Find* functions to return a std::optional<T> as opposed to returning the raw return values directly. This allows removing a few assertions and handles error cases like the service itself does.
2019-02-05service/nvflinger: Mark FindVsyncEvent() as a const member functionLioncash
This member function doesn't actually modify instance state, so it can be marked as a const member function.
2019-02-05service/nvflinger: Rename GetVsyncEvent() to FindVsyncEvent()Lioncash
This was missed within #2075. Renames the member function to make it consistent with the rest of the Find* functions.
2019-02-01Merge pull request #2073 from lioncash/opusbunnei
hwopus: Implement DecodeInterleaved (the newest variant)
2019-01-31kernel: Remove the Timer classLioncash
A holdover from citra, the Horizon kernel on the switch has no prominent kernel object that functions as a timer. At least not to the degree of sophistication that this class provided. As such, this can be removed entirely. This class also wasn't used at all in any meaningful way within the core, so this was just code sitting around doing nothing. This also allows removing a few things from the main KernelCore class that allows it to use slightly less resources overall (though very minor and not anything really noticeable).
2019-01-31Merge pull request #2072 from lioncash/servicebunnei
service: Update function tables
2019-01-31Merge pull request #2077 from lioncash/virtbunnei
kernel/wait_object: Devirtualize functions related to manipulating the thread list directly
2019-01-30kernel/wait_object: Devirtualize functions related to manipulating the ↵Lioncash
thread list directly No inheritors of the WaitObject class actually make use of their own implementations of these functions, so they can be made non-virtual. It's also kind of sketchy to allow overriding how the threads get added to the list anyways, given the kernel itself on the actual hardware doesn't seem to customize based off this.
2019-01-30kernel/timer: Remove unnecessary WakeupAllWaitingThreads() overrideLioncash
This implementation just calls the base class variant of the function, so this isn't necessary.
2019-01-30kernel/readable_event: Remove unnecessary WakeupAllWaitingThreads() overrideLioncash
This just calls the base variant of the function, so it can be removed.