Commit Graph

406 Commits

Author SHA1 Message Date
Michael Scire
a9322a7245 sf: prevent emitting mitm/defer code unless server in process supports it 2021-10-15 23:54:38 -07:00
Michael Scire
3bef5b7d5a ams: allow bootloader to merely approximate correct target firmware 2021-10-15 23:54:37 -07:00
Michael Scire
774622d93f loader: refactor to remove fake namespaces 2021-10-15 23:54:36 -07:00
Michael Scire
3218308524 loader: refactor ro manager/improve accuracy 2021-10-15 23:54:36 -07:00
Michael Scire
0abb1e474e spl: refactor for accuracy/move into libstrat 2021-10-15 23:54:36 -07:00
Michael Scire
11e9dcfe11 os: add FlushDataCache 2021-10-15 23:54:36 -07:00
Michael Scire
3e33fb6361 strat: use m_ for member variables 2021-10-15 23:54:35 -07:00
Michael Scire
3b5f56ab9f ams: replace most remaining operator & with std::addressof 2021-10-15 23:54:34 -07:00
Michael Scire
5c32ec11ea strat: refactor address taking of form &var[...] 2021-10-15 23:54:34 -07:00
Michael Scire
e2df2f98a3 strat: always use explicit result namespacing 2021-10-15 23:54:33 -07:00
Adubbz
ea0bb620f2 settings: implement KeyValueStore (#1659)
* settings: implement KeyValueStore and dependencies

* settings: update KeyValueStore for recent refactoring

* settings: address feedback
2021-10-15 23:54:33 -07:00
Michael Scire
2905319d46 strat: use ams::Main() instead of main(argc, argv) 2021-10-07 23:06:29 -07:00
Michael Scire
8a8631ebcb strat: build sysmodules with -Wextra/-Werror 2021-10-07 23:06:29 -07:00
Michael Scire
843dc8e521 libstrat: fix compilation without pre-compiled header/without lto 2021-10-07 23:06:28 -07:00
Michael Scire
fd1b6d4578 libstrat: enable -Wextra, -Werror
This caught an embarrassingly large number of bugs.
2021-10-07 23:06:28 -07:00
Michael Scire
782e449543 strat: remove map namespace, svc: add address space defs 2021-10-07 23:06:27 -07:00
Michael Scire
4ce6273f2b strat: use sf::NativeHandle for ipc templating 2021-10-07 23:06:27 -07:00
Michael Scire
d4221d822e sf: add NativeHandle type
TODO: figure out how to integrate this into templating...
2021-10-07 23:06:26 -07:00
Michael Scire
612b9e2f01 strat: prefer os::NativeHandle to Handle/svc::Handle where sensible 2021-10-07 23:06:26 -07:00
Michael Scire
09a9fdb2c3 pm: use svc::LimitableResource where relevant 2021-10-07 23:06:26 -07:00
Michael Scire
5a71876ca8 strat: use svc:: over ::svc 2021-10-07 23:06:26 -07:00
Michael Scire
002422d5dc ams: the copyright^H^H^H^H^H^H^Hmplex plane is the algebraic closure of the reals 2021-10-07 23:06:25 -07:00
Michael Scire
304b0f8016 os: remove ManagedHandle, refactor to use NativeHandle typename 2021-10-07 23:06:25 -07:00
Michael Scire
28756234d9 strat: automatic program id detection 2021-10-07 23:06:25 -07:00
Michael Scire
828506218f os: adopt nintendo ReaderWriter naming over ReadWrite 2021-10-07 23:06:24 -07:00
Michael Scire
a582429e6d os: amend io region api 2021-10-07 23:06:24 -07:00
Michael Scire
d1c6b77f13 os: implement SharedMemory, update AslrSpaceManager 2021-10-07 23:06:23 -07:00
Michael Scire
b690bc1472 os: fix AttachTransferMemory return type 2021-10-07 23:06:23 -07:00
Michael Scire
69a0ec03e9 strat: use consistent include style for lib headers 2021-10-07 23:06:23 -07:00
Michael Scire
6125281acd os: adopt multiwait naming over waitable 2021-10-07 23:06:23 -07:00
Michael Scire
fcb34b2c22 os: add IoRegion 2021-10-07 23:06:23 -07:00
Michael Scire
71b389c9e4 os: add tentative IoRegionType 2021-10-07 23:06:22 -07:00
Michael Scire
c68298a00e stratosphere: use SdkMutex/SdkRecursiveMutex over Mutex 2021-10-07 23:06:22 -07:00
Michael Scire
3ef8f0f73f os: implement Barrier 2021-10-07 23:06:21 -07:00
Michael Scire
389018db64 os: implement SdkRecursiveMutex 2021-10-07 23:06:21 -07:00
Michael Scire
94dd4ab3c5 ddsf: We can use LightEvent now 2021-10-07 23:06:20 -07:00
Michael Scire
6f53cbbe79 os: implement LightSemaphore 2021-10-07 23:06:20 -07:00
Michael Scire
41495ef51b os: implement LightMessageQueue 2021-10-07 23:06:19 -07:00
Michael Scire
c00d83204f os: refactor MessageQueue to use new MessageQueueHelper template 2021-10-07 23:06:19 -07:00
Michael Scire
3d6e8d5281 os: implement LightEvent 2021-10-07 23:06:19 -07:00
Michael Scire
57e380b2d6 os: implement ReadWriteBusyMutex 2021-10-07 23:06:18 -07:00
Michael Scire
6c98cd1ce2 os: implement BusyMutex 2021-10-07 23:06:18 -07:00
Michael Scire
b579a6d75e svc/kern/dd: remove MapDeviceAddressSpace() 2021-09-19 10:35:39 -07:00
Adubbz
4afce6965f ncm: updated to 13.0.0 2021-09-19 10:35:35 -07:00
Adubbz
66104b830a ncm: skeleton new commands 2021-09-19 10:35:34 -07:00
Michael Scire
6b66af37cd erpt: skeleton sprofile apis 2021-09-19 10:35:32 -07:00
Michael Scire
a669f3dcfa fusee/exo: update for recognition of 13.0.0 2021-09-19 10:35:31 -07:00
Michael Scire
2ab649f2b0 cs: fix launching of tio server 2021-09-19 10:35:30 -07:00
Michael Scire
ad9c7eb4dd cs: fix screenshot packet semantics 2021-09-19 10:35:30 -07:00
Michael Scire
c53eeb27f3 cs: implement TakeScreenShot command 2021-09-19 10:35:30 -07:00
Michael Scire
c31069cc88 cs: fix allocator aborts 2021-09-19 10:35:30 -07:00
Michael Scire
7bb3153938 osdbg: implement thread info api 2021-09-19 10:35:27 -07:00
Michael Scire
9eeafc6919 fix dmnt.gen2 title id (not sure how I typo'd this) 2021-09-19 10:35:26 -07:00
Michael Scire
f29660c335 boot2: launch dmnt.gen2 over dmnt, when using htc 2021-09-19 10:35:26 -07:00
Michael Scire
bd1fab8516 cs: implement GetFirmwareVersion command 2021-09-19 10:35:25 -07:00
Michael Scire
728191da43 scs: implement EventHandlerThread for shell 2021-09-19 10:35:25 -07:00
Michael Scire
a949c14c95 scs: implement DoShellServer 2021-09-19 10:35:25 -07:00
SciresM
277d2193e2 LogManager: implement system module, client api, logging api (#1617)
Some notes:

* Unless `atmosphere!enable_log_manager` is true, Nintendo's log manager will be used instead.
  * This prevents paying memory costs for LM when not enabling logging.
  * To facilitate this, Atmosphere's log manager has a different program id from Nintendo's.
  * `atmosphere!enable_htc` implies `atmosphere!enable_log_manager`.
* LogManager logs to tma, and the SD card (if `lm!enable_sd_card_logging` is true, which it is by default).
* Binary logs are saved to `lm!sd_card_log_output_directory`, which is `atmosphere/binlogs` by default.
2021-09-19 10:35:25 -07:00
Michael Scire
1b378d8eb1 exo/daybreak: advertise (and check against) supported hos version 2021-08-20 13:34:00 -07:00
Michael Scire
dc3f54a713 ams: std::optional -> util::optional 2021-07-12 01:59:51 -07:00
Michael Scire
eb667fea51 ams: basic support for 12.1.0 2021-07-06 07:28:33 -07:00
Michael Scire
1212bac110 fs.mitm: add OpenDataStorageWithProgramIndex support (theoretically, closes #1250) 2021-07-06 07:28:31 -07:00
Michael Scire
11ea38a7d7 ams: bump version to 0.19.4 2021-06-08 08:09:23 -07:00
Michael Scire
156a5ceba2 libstrat: fix override operator new to be noexcept (closes #1494) 2021-06-08 08:09:21 -07:00
Michael Scire
b5b55f60d8 sf/tipc: treat min/max as true min/max, rather than numeric 2021-05-12 22:47:21 -07:00
Michael Scire
9ac6f527e2 ams: update for 12.0.2 2021-05-12 09:09:44 -07:00
Michael Scire
1c5df03721 i2c: add aula pmic device code 2021-04-30 08:56:11 -07:00
Michael Scire
dc42da8456 boot: update all autogenerated parameters other than charge 2021-04-30 08:56:11 -07:00
Michael Scire
5deb52d1eb erpt: implement forced shutdown detection 2021-04-30 08:56:10 -07:00
Michael Scire
1e1b5971ce fs: properly implement OperateRangeWithBuffer, correct OperationId names. 2021-04-30 08:56:09 -07:00
Michael Scire
888b39fa50 ams: assume gcc 11 2021-04-29 03:04:54 -07:00
Michael Scire
12471d428d strat: compat with gcc 11 2021-04-29 03:04:54 -07:00
Michael Scire
b7dc7ad44d erpt: implement AppletActiveTimeInfoList 2021-04-29 03:04:52 -07:00
Michael Scire
ea3eb3c97e tipc: ports use objects in the object manager 2021-04-29 03:04:51 -07:00
Michael Scire
0904656559 sm: save 0x1000 in data costs by not aligning server manager to 0x1000 2021-04-29 03:04:51 -07:00
Michael Scire
7111b5cce6 strat: no longer materially constrained by sm session limit 2021-04-29 03:04:50 -07:00
Michael Scire
44279dbac4 fs: add (stubbed) OperateRangeWithBuffer implementation 2021-04-11 03:59:26 -07:00
Michael Scire
5921377678 erpt: add (stubbed, TODO after 0.19.0) support for 12.0.0 2021-04-11 03:59:26 -07:00
Michael Scire
ac6f1fecaf pgl: update to use tipc (untested) 2021-04-11 03:59:25 -07:00
Michael Scire
58e70ac441 tipc: Result is first raw data word, not last 2021-04-11 03:59:24 -07:00
Michael Scire
2fe065b590 tipc/sm: various fixes for issues 2021-04-11 03:59:24 -07:00
Michael Scire
2542f282e0 sm: reimplement using tipc instead of cmif (probably broken, untested) 2021-04-11 03:59:24 -07:00
Michael Scire
728bda9677 tipc: server processor fixes (compiles!) 2021-04-11 03:59:23 -07:00
Michael Scire
51416763fb tipc: implement ServerManager processing logic 2021-04-11 03:59:23 -07:00
Michael Scire
484bc20f16 tipc: implement framework/server support logic (except for actual processing) 2021-04-11 03:59:23 -07:00
Michael Scire
3f59907760 tipc: fix deserialization of buffers 2021-04-11 03:59:22 -07:00
Michael Scire
54c36042a8 tipc: hard-enforce boolean constraints in command processing generation 2021-04-11 03:59:22 -07:00
Michael Scire
5bb7a55fe3 tipc: implement service object interface generation 2021-04-11 03:59:22 -07:00
Michael Scire
434056a334 tipc: first draft object allocation logic 2021-04-11 03:59:21 -07:00
Michael Scire
8301b868fd tipc: fix compilation issues with core serialization routines 2021-04-11 03:59:21 -07:00
Michael Scire
7145b887bd tipc: tentative core serialization logic (missing imports, won't compile) 2021-04-11 03:59:21 -07:00
Michael Scire
4346c028a8 ams: add target firmware 12.0.0, fusee recognition 2021-04-11 03:59:20 -07:00
Michael Scire
9b47aa6e08 ams: prefer construct_at/destroy_at over placement new/explicit destructor 2021-04-11 03:59:04 -07:00
Michael Scire
1861791c1c ams: remove TYPED_STORAGE() macro in favor of template 2021-04-11 03:59:03 -07:00
Michael Scire
bae4c2c6d5 boot2: clean up pre-0.19.0 ams contents on upgrade 2021-04-11 03:59:02 -07:00
SciresM
e000dc9745 [tma2] [Ongoing] Continue implementing modules for tma2. (#1388)
* cs: add stub sysmodule to host command shell server

* cs: implement logic for main (linker error paradise, for now)

* cs: implement more of the system module's skeleton

* htcs: update client type names for libnx pr merge
2021-04-11 03:59:01 -07:00
SciresM
97d94180cf set.mitm: fake compatibility for usb!usb30_force_enabled on 9.0.0+ (#1391)
* set.mitm: fake compatibility for usb!usb30_force_enabled on 9.0.0+

* set.mitm: add value meaning comment for usb!usb30_force_enabled

* loader: pretend to be polite about patch ordering
2021-04-11 03:59:00 -07:00
Michael Scire
cc84810ddc htclow: fix ordering of channels, uninitialized bug in service json parse 2021-04-11 03:58:59 -07:00
Michael Scire
65a37c60cc tio: implement SdCardObserver (finishes sysmodule) 2021-04-11 03:58:57 -07:00
Michael Scire
b70fea933c tio: add stub sysmodule to host target io server 2021-04-11 03:58:56 -07:00
Michael Scire
fb16e8c316 socket: fix config size calculations 2021-04-11 03:58:55 -07:00
Michael Scire
7d528a30df htc: implement socket driver (socket api not really impl'd yet) 2021-04-11 03:58:54 -07:00
Michael Scire
d23bc85d38 htcs: fixes, echo server is now fully functional 2021-04-11 03:58:53 -07:00
Michael Scire
d5e748ec4f htcs: implement virtual socket collection 2021-04-11 03:58:52 -07:00
Michael Scire
2850786a0b htcs: hook up HtcsService to rpc client 2021-04-11 03:58:51 -07:00
Michael Scire
98b482a766 htcs: hook manager up to (unimplemented) manager impl 2021-04-11 03:58:49 -07:00
Michael Scire
099594469b htcs: hook service objects up to (unimplemented) manager apis 2021-04-11 03:58:49 -07:00
Michael Scire
1af323f5b8 htcfs: implement OpenDirectory/CloseDirectory 2021-04-11 03:58:47 -07:00
Michael Scire
249daa0222 sf: optimize argument parsing for const LargeData & 2021-04-11 03:58:46 -07:00
Michael Scire
116e4e88b3 htc: fix htcfs sf definition 2021-04-11 03:58:45 -07:00
Michael Scire
1af137ab1b htc: add htcfs server/service object skeletons 2021-04-11 03:58:44 -07:00
Michael Scire
3eaa1782fd htc: add htcfs service api definitions 2021-04-11 03:58:43 -07:00
Michael Scire
5199b3edaa htcs: add hipc server/service object skeletons 2021-04-11 03:58:43 -07:00
Michael Scire
93966fd4b1 htc: skeleton HtcsManagerImpl, implement HtcsMonitor 2021-04-11 03:58:43 -07:00
Michael Scire
0caf11755e htcs: add sf interface info/types 2021-04-11 03:58:42 -07:00
Michael Scire
8d6c9bb9ee htc: skeleton constructors for htcmisc 2021-04-11 03:58:38 -07:00
Michael Scire
6a99b7fcd5 htc: implement mux side of connecting (and more) 2021-04-11 03:58:38 -07:00
Michael Scire
fda4ddca62 htc: declare and begin impl of HtclowManagerImpl interface 2021-04-11 03:58:37 -07:00
Michael Scire
042de46692 htc: implement HtclowDriver 2021-04-11 03:58:35 -07:00
Michael Scire
b6d73580ed htc: begin skeletoning types for HtcmiscImpl 2021-04-11 03:58:35 -07:00
Michael Scire
53b04c5225 htc: hook up creation of the htc manager service object 2021-04-11 03:58:35 -07:00
Michael Scire
276c3f8434 htc: module id names, skeleton rest of main 2021-04-11 03:58:34 -07:00
Michael Scire
e5c573e354 rapidjson: add customization point for allocation/asserts 2021-04-11 03:58:33 -07:00
Michael Scire
5558da2740 rapidjson: import -master as ams::rapidjson 2021-04-11 03:58:32 -07:00
Michael Scire
c19e50bff1 htc: implement much of worker receive logic 2021-04-11 03:58:31 -07:00
Michael Scire
6a4247a6ed htc: free ourselves from the tyranny of numerical enums 2021-04-11 03:58:30 -07:00
Michael Scire
9fd6ed27af htc: implement htclow listener thread 2021-04-11 03:58:30 -07:00
Michael Scire
a56a4aed77 htc: implement complete usb driver 2021-04-11 03:58:29 -07:00
Michael Scire
7f16e202eb htc: implement (fixing linker errors) through HtclowManagerImpl::OpenDriver 2021-04-11 03:58:29 -07:00
Michael Scire
d664c8ed8a htclow: fix copyright headers, skeleton more manager types 2021-04-11 03:58:28 -07:00
Michael Scire
3d535e6103 htc: skeleton much of the type hierarchy for htclow manager 2021-04-11 03:58:28 -07:00
Michael Scire
d2102cb585 htc: skeleton some more of main 2021-04-11 03:58:28 -07:00
Michael Scire
1a5134d2d2 htc: skeleton main file/sysmodule dir 2021-04-11 03:58:27 -07:00
Michael Scire
2f17a76901 psc: fix pm module init 2021-02-15 19:51:58 -08:00
Michael Scire
89b7a83d3b usb: fix wrong command id for AppendConfigurationData 2021-02-15 19:51:58 -08:00
Michael Scire
570e5ceccb usb: add ds client api 2021-02-15 19:51:58 -08:00
Michael Scire
66212b7926 dns.mitm: support % in hosts file as stand-in for environment identifier 2021-02-02 12:16:30 -08:00
Michael Scire
fb48bd2766 dns.mitm: add GetAddrInfo redir, AtmosphereReloadHostsFile, debug logging control 2021-02-02 12:16:30 -08:00
Michael Scire
906a450ac3 dns.mitm: parse redirections from hosts file 2021-02-02 12:16:28 -08:00
Michael Scire
1314374890 dns: implement GetHostByName redirection (backend TODO) 2021-02-02 12:16:27 -08:00
Michael Scire
d8fd09fd08 dns: skeleton passthrough mitm 2021-02-02 12:16:27 -08:00
Michael Scire
f7863af736 dd: fix include, note gcc-11 TODO 2021-02-02 12:16:26 -08:00
Michael Scire
b209249e12 ams_mitm: update for new sf semantics 2021-02-02 12:16:24 -08:00
Michael Scire
0b2c4bb70e util::unique_lock, update loader to new sf semantics 2021-02-02 12:16:22 -08:00
Michael Scire
28d9b78ff8 ncm: update for new sf semantics 2021-02-02 12:16:22 -08:00
Michael Scire
29b3baf678 util::string_view, update pgl for new sf semantics 2021-02-02 12:16:21 -08:00
Michael Scire
b58f3d9174 ro: reduce memory usage by excising (unused) std::malloc 2021-02-02 12:16:21 -08:00
Michael Scire
af65f58109 ro: update for new sf semantics 2021-02-02 12:16:20 -08:00
Michael Scire
03654bacf6 sm, spl: update to use new sf semantics 2021-02-02 12:16:20 -08:00
Michael Scire
637c44f64d libstrat: convert to experimental new (super-accurate) sf allocation semantics 2021-02-02 12:16:20 -08:00