aboutsummaryrefslogtreecommitdiff
path: root/include
diff options
context:
space:
mode:
authorKimplul <kimi.h.kuparinen@gmail.com>2023-10-09 14:57:18 +0300
committerKimplul <kimi.h.kuparinen@gmail.com>2023-10-09 16:15:06 +0300
commit9c9d589ea310f1290e4d6d2019fc8b51d9a86e42 (patch)
tree81694631f4e848728774c22256baf6cded4f910d /include
parentb2f0f82e18665cb754b93d9795a6f1fb9dfc7c93 (diff)
downloadkmi-9c9d589ea310f1290e4d6d2019fc8b51d9a86e42.tar.gz
kmi-9c9d589ea310f1290e4d6d2019fc8b51d9a86e42.zip
move rpc stack handling to arch-specific code
+ Fairly considerable speedup, as we don't have to look up the rpc pte every time separately, instead cacheing them. Adds an architecture specific limitation to total rpc stack size, though.
Diffstat (limited to 'include')
-rw-r--r--include/arch/tcb.h7
-rw-r--r--include/kmi/tcb.h2
2 files changed, 8 insertions, 1 deletions
diff --git a/include/arch/tcb.h b/include/arch/tcb.h
index f4c80c6..af12e0b 100644
--- a/include/arch/tcb.h
+++ b/include/arch/tcb.h
@@ -25,4 +25,11 @@
*/
void tcb_assign(struct tcb *t);
+void setup_rpc_stack(struct tcb *t);
+size_t max_rpc_size();
+
+vm_t rpc_position(struct tcb *t);
+void mark_rpc_valid(struct tcb *t, vm_t top);
+void mark_rpc_invalid(struct tcb *t, vm_t bottom);
+
#endif /* KMI_ARCH_TCB_H */
diff --git a/include/kmi/tcb.h b/include/kmi/tcb.h
index 4f2eb1b..ba71dd3 100644
--- a/include/kmi/tcb.h
+++ b/include/kmi/tcb.h
@@ -99,7 +99,7 @@ struct tcb {
vm_t regs;
/** Arch-specific data. */
- struct arch_tcbd tcbd;
+ struct arch_tcbd arch;
/** Memory mapping data. */
struct mem_region_root sp_r;