[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[PATCH 15/17] hurd: add proc_{get,set}_code
From: |
Justus Winter |
Subject: |
[PATCH 15/17] hurd: add proc_{get,set}_code |
Date: |
Thu, 15 Aug 2013 09:38:05 +0200 |
Add routines to set and query the processes start_code and end_code
locations. Any executable segments loaded from the ELF binary are in
this range.
* hurd/process.defs: Add proc_{get,set}_code.
* hurd/process_reply.defs: Add proc_{get,set}_code.
* hurd/process_request.defs: Add proc_{get,set}_code_request.
---
hurd/process.defs | 17 +++++++++++++++++
hurd/process_reply.defs | 7 +++++++
hurd/process_request.defs | 17 +++++++++++++++++
3 files changed, 41 insertions(+)
diff --git a/hurd/process.defs b/hurd/process.defs
index 055ad72..498faba 100644
--- a/hurd/process.defs
+++ b/hurd/process.defs
@@ -387,3 +387,20 @@ routine proc_mark_important (
routine proc_is_important (
process: process_t;
out essential: boolean_t);
+
+/* Set the processes start_code and end_code locations. Any
+ executable segments loaded from the ELF binary are in this
+ range. */
+routine proc_set_code (
+ process: process_t;
+ start_code: vm_address_t;
+ end_code: vm_address_t);
+
+/* Get the processes start_code and end_code locations. Any
+ executable segments loaded from the ELF binary are in this range.
+ If zero is returned for these values, the requested information has
+ never been set. */
+routine proc_get_code (
+ process: process_t;
+ out start_code: vm_address_t;
+ out end_code: vm_address_t);
diff --git a/hurd/process_reply.defs b/hurd/process_reply.defs
index 6f208eb..640b7ca 100644
--- a/hurd/process_reply.defs
+++ b/hurd/process_reply.defs
@@ -183,3 +183,10 @@ simpleroutine proc_is_important (
RETURN_CODE_ARG;
essential: boolean_t);
+skip; /* proc_set_code */
+
+simpleroutine proc_get_code (
+ reply_port: reply_port_t;
+ RETURN_CODE_ARG;
+ start_code: vm_address_t;
+ end_code: vm_address_t);
diff --git a/hurd/process_request.defs b/hurd/process_request.defs
index 5493fbc..7565f03 100644
--- a/hurd/process_request.defs
+++ b/hurd/process_request.defs
@@ -390,3 +390,20 @@ simpleroutine proc_mark_important_request (
simpleroutine proc_is_important_request (
process: process_t;
ureplyport reply: reply_port_t);
+
+/* Set the processes start_code and end_code locations. Any
+ executable segments loaded from the ELF binary are in this
+ range. */
+simpleroutine proc_set_code_request (
+ process: process_t;
+ ureplyport reply: reply_port_t;
+ start_code: vm_address_t;
+ end_code: vm_address_t);
+
+/* Get the processes start_code and end_code locations. Any
+ executable segments loaded from the ELF binary are in this range.
+ If zero is returned for these values, the requested information has
+ never been set. */
+simpleroutine proc_get_code_request (
+ process: process_t;
+ ureplyport reply: reply_port_t);
--
1.7.10.4
- Re: [PATCH 03/17] Add proc_set_init_task, make runsystem pid 1, (continued)
- [PATCH 06/17] proc: add proc_mark_important server code, Justus Winter, 2013/08/15
- [PATCH 07/17] hurd: add proc_mark_important, Justus Winter, 2013/08/15
- [PATCH 08/17] init: Mark all of inits children and init itself as important, Justus Winter, 2013/08/15
- [PATCH 09/17] libdiskfs: register libdiskfs-based translators as important, Justus Winter, 2013/08/15
- [PATCH 11/17] libtrivfs: register libtrivfs-based translators as important, Justus Winter, 2013/08/15
- [PATCH 10/17] libnetfs: register libnetfs-based translators as important, Justus Winter, 2013/08/15
- [PATCH 12/17] mach-defpager: register mach-defpager translators as important, Justus Winter, 2013/08/15
- [PATCH 13/17] trans: register symlink translators as important, Justus Winter, 2013/08/15
- [PATCH 15/17] hurd: add proc_{get,set}_code,
Justus Winter <=
- [PATCH 16/17] exec: keep track of the range where executable segments are mapped, Justus Winter, 2013/08/15
- [PATCH 14/17] proc: keep track of {start,end}_code, Justus Winter, 2013/08/15
- [PATCH 17/17] Build fixes: Build processUser.o and link against it, Justus Winter, 2013/08/15
- [PATCH 1/2] Hurd: make reboot() send messages to both pid 1 and 2, Justus Winter, 2013/08/15