aboutsummaryrefslogtreecommitdiff
path: root/src/core/hle/service/time/time.cpp
AgeCommit message (Collapse)Author
2024-01-24Rework time service to fix time passing offline.Kelebek1
2023-06-07time: Use compile time division for TimeSpanType conversionMorph
2023-03-01service: move hle_ipc from kernelLiam
2023-02-21service: refactor server architectureLiam
Converts services to have their own processes
2022-06-26core: Replace all instances of ResultCode with Resultgerman77
2022-04-23general: Convert source file copyright comments over to SPDXMorph
This formats all copyright comments according to SPDX formatting guidelines. Additionally, this resolves the remaining GPLv2 only licensed files by relicensing them to GPLv2.0-or-later.
2021-11-03core: Remove unused includesameerj
2021-10-07service: Reduce header include overheadMorph
2021-07-14service: Append service name prefix to common filenamesMorph
2021-06-02general: Replace RESULT_SUCCESS with ResultSuccessMorph
Transition to PascalCase for result names.
2021-05-05hle: kernel: Migrate KClientPort to KAutoObject.bunnei
2021-05-05hle: kernel: Migrate KSession, KClientSession, and KServerSession to ↵bunnei
KAutoObject.
2021-05-05hle: kernel: Refactor IPC interfaces to not use std::shared_ptr.bunnei
2021-04-19time: Write buffer before pushing RESULT_SUCCESS in GetClockSnapshotMorph
2021-04-19time: Fix GetClockSnapshotFromSystemClockContextMorph
This removes an incorrect alignment usage and corrects the positions of the popped parameters. - Fixes Super Kirby Clash crashing on boot
2021-04-11Merge pull request #6170 from Morph1984/more-time-fixesbunnei
service: time: Setup the network clock with the local clock context
2021-04-08service: time: Setup the network clock with the local clock contextMorph
Setting the network time allows some time based events using the network clock to not reset.
2021-04-07service: time: Fix CalculateStandardUserSystemClockDifferenceByUserMorph
CalculateStandardUserSystemClockDifferenceByUser passes in the ClockSnapshots through 2 input buffers and not as raw arguments. Fix this by reading the 2 input buffers instead of popping raw arguments.
2021-03-13Merge pull request #6054 from Morph1984/time-GetClockSnapshotbunnei
time: Assign the current time point to the ClockSnapshot
2021-03-10time: Fix CalculateSpanBetween implementationMorph
CalculateSpanBetween passes in the ClockSnapshots through 2 input buffers and not as raw arguments. Fix this by reading the 2 input buffers instead of popping raw arguments. Partially fixes Super Smash Bros. Ultimate's Spirit Board
2021-03-10time: Assign the current time point to the ClockSnapshotMorph
Fixes the timer in Super Smash Bros Ultimate's Spirit Board.
2021-01-28core: hle: kernel: Rename Thread to KThread.bunnei
2020-12-06hle: kernel: Rewrite scheduler implementation based on Mesopshere.bunnei
2020-11-26service: Eliminate usages of the global system instanceLioncash
Completely removes all usages of the global system instance within the services code by passing in the using system instance to the services.
2020-10-12service: time: Update current time with changes to RTC setting.bunnei
- This can be used to advance time, e.g. for Pokemon Sword/Shield pokejobs.
2020-08-03ipc: Allow all trivially copyable objects to be passed directly into ↵David
WriteBuffer (#4465) * ipc: Allow all trivially copyable objects to be passed directly into WriteBuffer With the support of C++20, we can use concepts to deduce if a type is an STL container or not. * More agressive concept for stl containers * Add -fconcepts * Move to common namespace * Add Common::IsBaseOf
2020-07-11Merge pull request #4203 from VolcaEM/servicesbunnei
service: Update function tables
2020-06-29service: Update function tablesVolcaEM
2020-06-27General: Recover Prometheus project from harddrive failure Fernando Sahmkow
This commit: Implements CPU Interrupts, Replaces Cycle Timing for Host Timing, Reworks the Kernel's Scheduler, Introduce Idle State and Suspended State, Recreates the bootmanager, Initializes Multicore system.
2020-04-19service/time: Remove reliance on the global system accessorLioncash
Eliminates usages of the global system accessor and instead passes the existing system instance into the interfaces.
2020-04-14service: time: Implement CalculateStandardUserSystemClockDifferenceByUser.bunnei
- Used by Animal Crossing: New Horizons.
2020-03-27services: time: Implement CalculateSpanBetween.bunnei
- Used by Super Smash Bros. Ultimate.
2020-02-11Core: Set all hardware emulation constants in a single file.Fernando Sahmkow
2020-01-04service: time: Implement GetStandardLocalSystemClock.bunnei
2020-01-04service: time: Implement GetClockSnapshotFromSystemClockContext.bunnei
2020-01-04service: time: Implement IsStandardNetworkSystemClockAccuracySufficient.bunnei
2020-01-04service: time: Rewrite implementation of glue services.bunnei
2019-11-24Merge pull request #3094 from lioncash/tablesbunnei
service: Update function tables
2019-11-12service: Update function tablesLioncash
Keeps the function tables up to date. Updated based off information from Switchbrew.
2019-11-12service: Resolve sign conversion errorsLioncash
These are fairly trivial to resolve and most of the changes entail using RESULT_UNKNOWN over ResultCode(-1).
2019-09-22Deglobalize System: TimeDavid Marcec
2019-06-26Addressed issuesDavid Marcec
2019-06-26Implement Time::GetSharedMemoryNativeHandleDavid Marcec
This PR attempts to implement the shared memory provided by GetSharedMemoryNativeHandle. There is still more work to be done however that requires a rehaul of the current time module to handle clock contexts. This PR is mainly to get the basic functionality of the SharedMemory working and allow the use of addition to it whilst things get improved on. Things to note: Memory Barriers are used in the SharedMemory and a better solution would need to be done to implement this. Currently in this PR I’m faking the memory barriers as everything is sync and single threaded. They work by incrementing the counter and just populate the two data slots. On data reading, it will read the last added data. Specific values in the shared memory would need to be updated periodically. This isn't included in this PR since we don't actively do this yet. In a later PR when time is refactored this should be done. Finally, as we don't handle clock contexts. When time is refactored, we will need to update the shared memory for specific contexts. This PR does this already however since the contexts are all identical and not separated. We're just updating the same values for each context which in this case is empty. Tiime:SetStandardUserSystemClockAutomaticCorrectionEnabled, Time:IsStandardUserSystemClockAutomaticCorrectionEnabled are also partially implemented in this PR. The reason the implementation is partial is because once again, a lack of clock contexts. This will be improved on in a future PR. This PR closes issue #2556
2019-06-04core/core_timing_util: Amend casing of cyclesTo* functionsLioncash
Makes the casing consistent with all of our general function naming conventions.
2019-06-04core/core_timing_util: Use std::chrono types for specifying time unitsLioncash
Makes the interface more type-safe and consistent in terms of return values.
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-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-01-07settings: Use std::chrono::seconds instead of s64 for RTCZach Hilman
2019-01-07time: Use custom RTC settings if applicable for gameZach Hilman
2018-12-29service/time: Minor cleanup to GetClockSnapshot()Lioncash
Moves some variables closer to their actual usage sites.