Michael Scire
76957e502d
kern: add build-define for logging to iram ringbuffer
2020-09-17 08:26:08 -07:00
Michael Scire
e36fe62fca
kern: lps driver fixes, sleep confirmed working on 1.0.0
2020-09-07 10:43:35 -07:00
Michael Scire
870b589379
kern: fix c/p error
2020-09-07 10:43:35 -07:00
Michael Scire
acdce230da
kern: add debug logging on smmu error interrupt
2020-09-07 10:43:35 -07:00
Michael Scire
34dc062c11
kern: finish 1.x lps driver
2020-09-07 10:43:35 -07:00
Michael Scire
ab2568ddfb
kern: add most of 1.x lps driver
2020-09-07 10:43:35 -07:00
Michael Scire
4dc728824f
kern: skeleton legacy lps driver
2020-09-07 10:43:35 -07:00
Michael Scire
cc6b8ea4d1
exo/kern: 1.0.0 requires access to bpmp smmu regs, userland (am) needs to map bpmp exception vectors
2020-09-07 10:43:35 -07:00
Michael Scire
49af4fae32
kern: begin 1.0.0 backwards compat changes (kips run, full boot fails)
2020-09-07 10:43:35 -07:00
Michael Scire
e8ffbe630f
kern: support 2-pool layout on 2.x-4.x instead of modern 4-pool layout
2020-09-07 10:43:35 -07:00
Michael Scire
ce95af89ef
kern: change terminology metadata -> management
2020-09-07 10:43:35 -07:00
Michael Scire
1983f86875
kern: revamp KMemoryRegionType to better encode derivation hierarchies
2020-09-07 10:43:35 -07:00
Michael Scire
d50c7c5c79
kern: PMC must be user-mappable for 1.0.0 compat
2020-09-07 10:43:35 -07:00
Michael Scire
496f93ccdb
kern: expose mesosphere meta over GetInfo instead of GetSystemInfo
2020-09-07 10:43:35 -07:00
Michael Scire
79c9bed528
kern/pm: support for 5.x under mesosphere
2020-09-07 10:43:35 -07:00
Michael Scire
47f2e93a42
kern: add version bounds checking
2020-08-18 15:17:40 -07:00
Michael Scire
1a262c1063
kern: improve resource region size definitions/calculations
2020-08-18 15:17:40 -07:00
Michael Scire
79201428b0
kern: resolve NonSecure definition TODO
2020-08-18 15:17:40 -07:00
Michael Scire
a75c16226e
kern: correct thread termination atomicity
2020-08-18 15:17:40 -07:00
Michael Scire
e5d30217d3
kern: fix reference leak in KThread::GetThreadFromId callers
2020-08-18 15:17:40 -07:00
Michael Scire
f77a4fbf98
kern: non-loop cas-weak -> cas-strong
2020-08-18 15:17:40 -07:00
Michael Scire
717265a54c
kern: fix bug in KScheduler::ClearPreviousThread
2020-08-18 15:17:40 -07:00
fincs
8e688de570
kern: move SetupPoolPartitionMemoryRegions into board specific implementation
2020-08-18 15:17:40 -07:00
Michael Scire
3c85e37667
kern: use std::atomic_ref instead of reinterpret_cast to std::atomic
2020-08-18 15:17:40 -07:00
Michael Scire
48e8562033
kern: use common GIC implementation for arm/arm64
2020-08-18 15:17:40 -07:00
Michael Scire
f07bd0e337
kern: correct flushing of init arguments
2020-08-18 15:17:40 -07:00
Michael Scire
4a35904d73
kern: simplify SetupForIpcClient cleanup
2020-08-18 15:17:40 -07:00
Michael Scire
b8c2782ede
kern: SvcLegacyGetFutureThreadInfo
2020-08-18 15:17:40 -07:00
Michael Scire
3ec9a9e59f
kern: rename CacheHelper operation for accuracy
2020-08-18 15:17:40 -07:00
Michael Scire
595c6dbe8f
kern: KPageTableBase::WriteDebugMemory stores/invalidates cache
2020-08-18 15:17:40 -07:00
Michael Scire
b5f2698bf0
kern: fix multicore instruction cache invalidation
2020-08-18 15:17:40 -07:00
Michael Scire
f058536b59
kern: add tracing for irq/scheduling
2020-08-18 15:17:40 -07:00
Michael Scire
8e5c0a9663
kern: cleanup some KMemoryManager functions
2020-08-18 15:17:40 -07:00
Michael Scire
1b63002f91
kern: refactor KMemoryLayout
2020-08-18 15:17:40 -07:00
Michael Scire
c3fa3bd5d6
kern: N reduced the slabheap gap size in 10.0.0
2020-08-18 15:17:40 -07:00
Michael Scire
e1bd6fb874
kern: fix missing scheduler updates in KLightLock/Exception, fix RequestScheduleOnInterrupt
2020-08-18 15:17:40 -07:00
Michael Scire
920b017677
kern: implement svc trace
2020-08-18 15:17:40 -07:00
Michael Scire
f9d68db3f6
kern: SvcChangeKernelTraceState
2020-08-18 15:17:40 -07:00
Michael Scire
89f1c0ce33
kern: remove stray log in SetHeapSize
2020-08-18 15:17:40 -07:00
Michael Scire
73798cb812
kern: build with -Wextra
2020-08-17 14:20:24 -07:00
Michael Scire
51b5c3d87d
ams: avoid UB infinite loops
2020-08-13 17:28:29 -07:00
Michael Scire
29358dc593
kernel_ldr: use unoptimized memcpy before mmu bringup ( closes #1102 )
...
Before the MMU is up, all reads/writes must be aligned; the optimized
memcpy implementation does not guarantee all reads/writes it performs
are aligned.
This commit splits the libc impl to be separate for kernel/kernel_ldr,
and so now only kernel will use the optimized impl. This is safe,
as the MMU is brought up before kernel begins executing.
2020-08-02 14:40:28 -07:00
Michael Scire
3fd4002bc9
kern: complete final SVC stubs (KernelDebug/Trace debug-impl still TODO)
2020-07-31 14:50:52 -07:00
Michael Scire
5d462c626c
kern: SvcReturnFromException
2020-07-31 14:50:52 -07:00
Michael Scire
8cd81b3092
kern: fix dynamic calculation of slab heap size
2020-07-31 14:50:52 -07:00
Michael Scire
5c4fbf5c67
kern SvcGetDebugThreadContext, SvcSetDebugThreadContext
2020-07-31 14:50:52 -07:00
Michael Scire
3afd723b92
kern: SvcGetDebugThreadParam
2020-07-31 14:50:52 -07:00
Michael Scire
e1f3bb10a5
kern: clean up majority of TODOs
2020-07-31 14:50:52 -07:00
Michael Scire
bea550ebce
kern: resolve final non-user-exception MESOSPHERE_UNIMPLEMENTED
2020-07-31 14:50:52 -07:00
Michael Scire
85f533e6c4
kern: SvcGetDebugEventInfo64From32
2020-07-31 14:50:52 -07:00
Michael Scire
c9f8252577
kern: resolve MESOSPHERE_UNIMPLEMENTEDs other than UserException
2020-07-31 14:50:52 -07:00
Michael Scire
325802e29d
kern: Add real SvcBreak implementation
2020-07-31 14:50:52 -07:00
Michael Scire
4c3c910774
kern: SvcBreakDebugProcess, SvcTerminateDebugProcess
2020-07-31 14:50:52 -07:00
Michael Scire
b88e09de5b
kern: SvcSetHardwareBreakPoint
2020-07-31 14:50:52 -07:00
Michael Scire
b143f1e05f
kern: Svc(Legacy)ContinueDebugEvent
2020-07-31 14:50:52 -07:00
Michael Scire
3289b45408
kern: Add 4.x InitialProcessIdRange to SvcGetInfo
2020-07-31 14:50:52 -07:00
Michael Scire
91fa0d651f
kern: SvcQueryPhysicalAddress
2020-07-31 14:50:52 -07:00
Michael Scire
9bc2c0c0c5
kern: style parity for return in GetThreadList
2020-07-31 14:50:52 -07:00
Michael Scire
96c3dfee14
kern: SvcGetThreadList
2020-07-31 14:50:52 -07:00
Michael Scire
51084c0837
kern: SvcGetLastThreadInfo, SvcGetDebugFutureThreadInfo
2020-07-31 14:50:52 -07:00
Michael Scire
0993ae0685
kern: SvcFlushDataCache, SvcFlushEntireDataCache
2020-07-31 14:50:52 -07:00
Michael Scire
f6f43300e0
kern: SvcReadDebugProcessMemory, SvcWriteDebugProcessMemory
2020-07-31 14:50:52 -07:00
Michael Scire
008bfc27f3
kern: automatic PC alignment on ERET is implementation defined
2020-07-31 14:50:52 -07:00
Michael Scire
7352d87b20
kern: switch memset to optimized impl
2020-07-31 14:50:52 -07:00
Michael Scire
9ddb4194b3
kern: use optimized memcmp/memcpy implementations
2020-07-31 14:50:52 -07:00
Michael Scire
3f17a34b67
SvcQueryDebugProcessMemory
2020-07-31 14:50:52 -07:00
Michael Scire
5de853b662
kern: fix ARM vs THUMB mode selection on 32-bit entry
2020-07-31 14:50:52 -07:00
Michael Scire
36a3909a24
kern: fix whoops in light ipc
2020-07-31 14:50:52 -07:00
Michael Scire
8922bbd108
kern: SendSyncRequestLight, ReplyAndReceiveLight
2020-07-31 14:50:52 -07:00
Michael Scire
2db6760461
kern: fix bug in server handle cleanup
2020-07-31 14:50:52 -07:00
Michael Scire
bb7f320f7f
kern: fix nonsensical copy/pasted comments in QueryMemory
2020-07-31 14:50:52 -07:00
Michael Scire
94a170c437
kern: QueryMemory64From32, QueryProcessMemory64From32
2020-07-31 14:50:52 -07:00
Michael Scire
7cf0432569
kern: add KCodeMemory code left out of previous commit
2020-07-31 14:50:52 -07:00
Michael Scire
39b22cee8c
kern: implement KCodeMemory (and SVCs)
2020-07-31 14:50:52 -07:00
Michael Scire
3fb3beeaff
kern: SvcGetSystemTick
2020-07-31 14:50:52 -07:00
Michael Scire
4bb9ef061a
kern: implement SvcGetThreadContext3
2020-07-31 14:50:52 -07:00
Michael Scire
f70ee67753
kern: correct behavior when setting activity/core mask for pinned thread
2020-07-31 14:50:52 -07:00
Michael Scire
787964f7e7
kern: implement thread pinning/SvcSynchronizePreemptionState
2020-07-31 14:50:52 -07:00
Michael Scire
b1f38be3ae
kern: fix building under release config
2020-07-31 14:50:52 -07:00
Michael Scire
9dc3e025fc
kern: Map L1/L2 blocks when possible
2020-07-31 14:50:52 -07:00
Michael Scire
4ac94e9179
kern: improve KLightLock accuracy
2020-07-31 14:50:52 -07:00
Michael Scire
1448068b69
kern: fix assertion in KThread::(Try)Suspend
2020-07-31 14:50:52 -07:00
Michael Scire
0af44d2875
kern: fix bug in page table mapping calculations
2020-07-31 14:50:52 -07:00
Michael Scire
840ab0785c
kern: SvcMapPhysicalMemoryUnsafe, SvcUnmapPhysicalMemoryUnsafe
2020-07-31 14:50:52 -07:00
Michael Scire
583899ede3
kern: General system stability improvements to enhance the user's experience.
2020-07-31 14:50:52 -07:00
Michael Scire
893b046111
kern: update interrupt manager
2020-07-31 14:50:52 -07:00
Michael Scire
1b9acc4a6a
kern: SvcUnmapPhysicalMemory, cleanup thread pinning
2020-07-31 14:50:52 -07:00
Michael Scire
cbecda2a27
kern: SvcQueryProcessMemory64, notification SvcBreaks
2020-07-31 14:50:52 -07:00
Michael Scire
5ecc80a5f6
kern: implement SvcMapPhysicalMemory
2020-07-31 14:50:52 -07:00
Michael Scire
695b82b945
kern: finish SvcGetInfo
2020-07-31 14:50:52 -07:00
Michael Scire
fd9b986938
kern: Implement SecureMemory (system resource)
2020-07-31 14:50:52 -07:00
Michael Scire
9231646f33
kern: implement SvcSleepSystem
2020-07-31 14:50:52 -07:00
Michael Scire
418de7b0dc
kern: SvcInvalidateProcessDataCache
2020-07-31 14:50:52 -07:00
Michael Scire
46935fea80
kern: fix resource leak bugs
2020-07-31 14:50:52 -07:00
Michael Scire
11d5353827
kern: SvcMapProcessCodeMemory, SvcUnmapProcessCodeMemory
2020-07-31 14:50:52 -07:00
Michael Scire
240e6227e9
kern: Fix bug when reducing heap size
2020-07-31 14:50:52 -07:00
Michael Scire
1d4d637818
kern SvcGetCurrentProcessorNumber, SvcSetProcessActivity, half of SvcSetThreadActivity
2020-07-31 14:50:52 -07:00
Michael Scire
23eed522d3
kern: SvcGetThreadCoreMask, SvcSetThreadCoreMask
2020-07-31 14:50:52 -07:00
Michael Scire
c622539b95
kern: SvcSetMemoryPermission
2020-07-31 14:50:52 -07:00
Michael Scire
d87a9f011c
kern: implement transfer memory (and SVCs)
2020-07-31 14:50:52 -07:00