Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

[PATCH 1/4] diskfs: Add RPC for fsys_init to bootstrap if present

1 view
Skip to first unread message

Damien Zammit

unread,
Jul 28, 2020, 6:09:16 AM7/28/20
to bug-...@gnu.org, Damien Zammit
---
libdiskfs/boot-start.c | 13 +++++++++++++
1 file changed, 13 insertions(+)

diff --git a/libdiskfs/boot-start.c b/libdiskfs/boot-start.c
index 29b8acc6..fa59e1b2 100644
--- a/libdiskfs/boot-start.c
+++ b/libdiskfs/boot-start.c
@@ -518,7 +518,9 @@ diskfs_S_fsys_init (struct diskfs_control *pt,

if (diskfs_exec_server_task != MACH_PORT_NULL)
{
+ mach_port_t bootstrap;
process_t execprocess;
+
err = proc_task2proc (procserver, diskfs_exec_server_task, &execprocess);
assert_perror_backtrace (err);

@@ -533,6 +535,17 @@ diskfs_S_fsys_init (struct diskfs_control *pt,
execprocess, MACH_MSG_TYPE_COPY_SEND));
mach_port_deallocate (mach_task_self (), execprocess);

+ /* Give the real bootstrap filesystem an fsys_init RPC of its own */
+ err = task_get_bootstrap_port (mach_task_self (), &bootstrap);
+ assert_perror_backtrace (err);
+ if (bootstrap != MACH_PORT_NULL)
+ {
+ err = fsys_init (bootstrap, procserver, MACH_MSG_TYPE_COPY_SEND,
+ authhandle);
+ mach_port_deallocate (mach_task_self (), bootstrap);
+ assert_perror_backtrace (err);
+ }
+
/* We don't need this anymore. */
mach_port_deallocate (mach_task_self (), diskfs_exec_server_task);
diskfs_exec_server_task = MACH_PORT_NULL;
--
2.25.1


Samuel Thibault

unread,
Jul 30, 2020, 6:02:29 PM7/30/20
to Damien Zammit, bug-...@gnu.org
Applied, thanks!

Damien Zammit, le mar. 28 juil. 2020 20:08:34 +1000, a ecrit:
0 new messages