summaryrefslogtreecommitdiff
path: root/libdiskfs/boot-start.c
AgeCommit message (Collapse)Author
2010-08-01Fix libdiskfs bootstrap race conditionJeremie Koenig
exec_exec() probably triggers a call to file_exec(), so the exec server port needs to be cached earlier. * libdiskfs/boot-start.c: Move caching the exec server port to just after initializing it.
2002-03-262002-03-25 Neal H Walfield <neal@cs.uml.edu>Neal H. Walfield
* peropen-make.c (diskfs_make_peropen): Instead of returning the peropen, return as error_t and return the peropen in the new parameter *PPO. * diskfs.h (diskfs_make_peropen): Change declaration to reflect new semantics. * boot-start.c (diskfs_start_bootstrap): Check the return value of diskfs_make_peropen using the new semantics. (diskfs_S_exec_startup_get_info): Likewise. (diskfs_execboot_fsys_startup): Likewise. (diskfs_S_fsys_init): Likewise. * dir-lookup.c (diskfs_S_dir_lookup): Likewise. * dir-mkfile.c (diskfs_S_dir_mkfile): Likewise. * file-exec.c (diskfs_S_file_exec): Likewise. * file-reparent.c (diskfs_S_file_reparent): Likewise. * fsys-getfile.c (diskfs_S_fsys_getfile): Likewise. * fsys-getroot.c (diskfs_S_fsys_getroot): Likewise. * trans-callback.c (_diskfs_translator_callback2_fn): Likewise. * init-startup.c (diskfs_startup_diskfs): Likewise.
2002-01-022002-01-02 Roland McGrath <roland@frob.com>Roland McGrath
* boot-start.c (diskfs_start_bootstrap) [KERN_INVALID_LEDGER]: Pass extra arguments to task_create for OSF variant.
2001-08-202001-08-20 Roland McGrath <roland@frob.com>Roland McGrath
* opts-std-startup.c: diskfs_boot_flags -> diskfs_boot_command_line. (OPT_BOOT_CMDLINE): Renamed from OPT_BOOTFLAGS. (startup_options): --bootflags -> --multiboot-command-line (parse_startup_opt): Parse it. * diskfs.h: diskfs_boot_flags -> diskfs_boot_command_line. (diskfs_boot_filesystem): New macro. * init-main.c (diskfs_init_main): Use it. * init-init.c (diskfs_init_diskfs): Likewise. * console.c (diskfs_console_stdio): Likewise. * boot-start.c (_diskfs_boot_privports): Likewise. (diskfs_start_bootstrap): Split boot_command_line into words and pass those arguments to init instead of diskfs_bootflags. * diskfs.h: Declare it. * boot-start.c (diskfs_start_bootstrap, start_execserver): Use it. * boot-start.c (diskfs_boot_init_program): New variable. * diskfs.h: Declare it. * boot-start.c (default_init): Variable removed. (diskfs_start_bootstrap): Use diskfs_boot_init_program instead of default_init or prompting under -i. * opts-std-startup.c (OPT_BOOT_INIT_PROGRAM): New macro. (startup_options): Add --boot-init-program. (parse_startup_opt): Parse it.
2000-03-172000-03-17 Thomas Bushnell, BSG <tb@mit.edu>Thomas Bushnell
* boot-start.c (diskfs_S_fsys_init, diskfs_start_bootstrap): Don't use MOVE_SEND in Hurd RPC. * file-exec.c (diskfs_S_file_exec): Don't use MAKE_SEND in Hurd RPC. * init-startup.c (diskfs_startup_diskfs, _diskfs_init_completed): Likewise.
2000-03-172000-03-17 Roland McGrath <roland@baalperazim.frob.com>Roland McGrath
* boot-start.c (diskfs_start_bootstrap): Use ports_get_send_right. (diskfs_execboot_fsys_startup): Use ports_get_send_right. (diskfs_S_fsys_init): Use ports_get_send_right. (start_execserver): Use ports_get_send_right.
1999-07-111999-07-11 Roland McGrath <roland@baalperazim.frob.com>Roland McGrath
* boot-start.c (diskfs_S_exec_startup_get_info): Typo in last change.
1999-07-111999-07-09 Thomas Bushnell, BSG <tb@mit.edu>Thomas Bushnell
* boot-start.c (diskfs_S_exec_startup_get_info): Use mmap instead of vm_allocate. (diskfs_S_fsys_init): Likewise. * file-get-trans.c (diskfs_S_file_get_translator): Likewise. * file-getfh.c (diskfs_S_file_getfh): Likewise. * io-read.c (diskfs_S_io_read): Likewise.
1999-06-041999-06-02 Roland McGrath <roland@baalperazim.frob.com>Roland McGrath
* boot-start.c (diskfs_start_bootstrap): Pass environment collected from `environ' on to init. The kernel can send more parameters through this way without us knowing about them specifically.
1998-12-301998-12-27 Roland McGrath <roland@baalperazim.frob.com>Roland McGrath
Use a struct hurd_port for the cached exec server port, so it is properly reference-counted and locked. * boot-start.c (diskfs_exec): Variable removed. (diskfs_start_bootstrap): Make it a local here. Install that port in _diskfs_exec_portcell. (diskfs_S_fsys_init): Use _diskfs_exec_portcell instead of diskfs_exec. * init-init.c (_diskfs_exec_portcell): New variable. (diskfs_init_diskfs): Initialize it. * priv.h: Declare it. * diskfs.h (diskfs_exec, diskfs_exec_ctl): Remove decls. * file-exec.c (diskfs_S_file_exec): Use _diskfs_exec_portcell instead of diskfs_exec.
1998-12-271998-12-27 Roland McGrath <roland@baalperazim.frob.com>Roland McGrath
* boot-start.c (diskfs_start_bootstrap): Twiddle boot-time messages.
1998-12-271998-12-27 Roland McGrath <roland@baalperazim.frob.com>Roland McGrath
* boot-start.c (_diskfs_boot_privports): Renamed from diskfs_*. * priv.h: Declare it. * console.c (diskfs_console_stdio): Change caller.
1998-12-271998-12-27 Roland McGrath <roland@baalperazim.frob.com>Roland McGrath
* opts-std-startup.c (startup_options): Move -C above "Boot options:", give it a docstring. Docstrings for --bootflags, --boot-command. (_diskfs_boot_command): New variable. (startup_options, parse_startup_opt): New option --boot-command, consumes remaining args to set _diskfs_boot_command. * priv.h: Declare _diskfs_boot_command. * boot-start.c (diskfs_start_bootstrap): If diskfs_exec_server_task is null, assume we are running as the boot command and have a root with /servers/exec. If _diskfs_boot_command is set, start that command in place of init. If can't lookup initname, print error msg and loop to prompt. Put a newline before "Init name" prompt. After starting exec server, try to set active trans on /servers/exec. (diskfs_boot_getpriv): New function: if _hurd_host_priv is null, use fsys_getpriv on our bootstrap port. (parent_task): New static variable, set there with fsys_getpriv call. (diskfs_S_fsys_init): If diskfs_exec_server_task is null, don't do anything with it; instead register parent_task as our child and send an fsys_init to our parent on our bootstrap port. * console.c (diskfs_console_stdio): Call diskfs_boot_privports before get_privileged_ports if diskfs_boot_flags is set.
1998-11-291998-11-25 Mark Kettenis <kettenis@phys.uva.nl>Roland McGrath
* boot-start.c (diskfs_S_fsys_init): Call _hurd_proc_init with new args set to zero.
1998-08-10Sun Aug 9 21:09:24 1998 Jose M. Moya <josem@gnu.org>Thomas Bushnell
* diskfs.h (struct node): Add filemod_reqs member. (struct modreq): Rename struct dirmod to reqmod as it is used for directory and file notifications. (diskfs_notice_filechange): Add prototype. * dir-chg.c (diskfs_S_dir_notice_changes): Check nowait_dir_changed return value for errors. (diskfs_notice_dirchange): Remove requests when the notification fails. * file-chg.c (diskfs_S_file_notice_changes): Implement. (diskfs_notice_filechange): New function. * node-make.c (diskfs_make_node): Initialize filemod_reqs. * node-drop.c (free_modreqs): New function. (diskfs_drop_node): Free filemod_reqs. * file-chauthor.c (dithkfth_TH_file_chauthor): Add file notifications. * file-chflags.c (diskfs_S_file_chflags): Likewise. * file-chmod.c (diskfs_S_file_chmod): Likewise. * file-chown.c (diskfs_S_file_chown): Likewise. * file-set-size.c (diskfs_S_file_set_size): Likewise. * io-prenotify.c (diskfs_S_io_prenotify): Likewise. * io-write.c (diskfs_S_io_write): Likewise. * node-rdwr.c (diskfs_node_rdwr): Likewise.
1997-02-14(diskfs_execboot_fsys_startup, diskfs_S_fsys_init,Miles Bader
diskfs_S_exec_startup_get_info, diskfs_start_bootstrap): Pass a prototype peropen instead of the dotdotport and depth to diskfs_make_peropen.
1997-02-06(diskfs_start_bootstrap, diskfs_S_exec_startup_get_info,Miles Bader
diskfs_execboot_fsys_startup, diskfs_S_fsys_init): Supply DEPTH argument to diskfs_make_peropen.
1996-11-13Thu Nov 7 01:03:11 1996 Thomas Bushnell, n/BSG <thomas@gnu.ai.mit.edu>Thomas Bushnell
* protid-rele.c (diskfs_protid_rele): Free CRED->user. Wed Nov 6 17:55:17 1996 Thomas Bushnell, n/BSG <thomas@gnu.ai.mit.edu> * diskfs.h (diskfs_isuid, diskfs_groupmember, diskfs_isowner, diskfs_access, diskfs_checkdirmod): Delete functions. * fsys-getroot.c (diskfs_S_fsys_getroot): Replace PSEUDOCRED with a real iouser and specify that in the relevant calls. * io-restrict-auth.c (diskfs_S_io_restrict_auth): Reworked to use idvecs. * file-chmod.c (diskfs_S_file_chmod): diskfs_isuid -> idvec_contains. * file-chown.c (diskfs_S_file_chown): Likewise. * file-getcontrol.c (diskfs_S_file_getcontrol): Likewise. * file-chmod.c (diskfs_S_file_chmod): diskfs_groupmember -> idvec_contains. * file-chown.c (diskfs_S_file_chown): Likewise. * node-create.c (diskfs_create_node): Likewise. * dir-lookup.c (diskfs_S_dir_lookup): diskfs_isowner -> fshelp_isowner. * file-chflags.c (diskfs_S_file_chflags): Likewise. * file-chmod.c (diskfs_S_file_chmod): Likewise. * file-chown.c (diskfs_S_file_chown): Likewise. * file-get-transcntl.c (diskfs_S_file_get_translator_cntl): Likewise. * file-set-trans.c (diskfs_S_file_set_translator): Likewise. * file-utimes.c (diskfs_S_file_utimes): Likewise. * fsys-getroot.c (diskfs_S_fsys_getroot): Likewise. * lithp.h (dithkfth_ithowner): Deleted macro. (fthhelp_ithowner, uther): New macros. * file-chauthor.c (dithkfth_TH_file_chauthor): dthkfth_ithowner -> fthhelp_ithowner. * dir-lookup.c (diskfs_S_dir_lookup): diskfs_access -> fshelp_access. * dir-mkfile.c (diskfs_S_dir_mkfile): Likewise. * file-access.c (diskfs_S_file_check_access): Likewise. * file-exec.c (diskfs_S_file_exec): Likewise (in dead code). * fsys-getroot.c (diskfs_S_fsys_getroot): Likewise. * ifsock.c (diskfs_S_ifsock_getsockaddr): Likewise. * lookup.c (diskfs_lookup): Likewise. (diskfs_lookup): diskfs_checkdirmod -> fshelp_checkdirmod. * dir-lookup.c (diskfs_S_dir_lookup): New arg format for fshelp_fetch_root. * fsys-getroot.c (diskfs_S_fsys_getroot): Likewise. * diskfs.h, protid-make.c (diskfs_create_protid): Delete args `uids', `gids', `nuids', and `ngids'. Replace with new arg `user'. All callers changed. (diskfs_finish_protid): Likewise. * file-inv-trans.c (diskfs_S_file_invoke_translator): Use CRED->user instead of old fields. * io-restrict-auth.c (diskfs_S_io_restrict_auth): Likewise. * node-create.c (diskfs_create_node): Likewise. * file-exec.c (diskfs_S_file_exec): Likewise. Use idvec_merge instead of idvec_merge_ids, now that it's convenient. * io-reauthenticate.c (diskfs_S_io_reauthenticate): Use new iohelp_reauthenticate. Tue Nov 5 21:10:18 1996 Thomas Bushnell, n/BSG <thomas@gnu.ai.mit.edu> * diskfs.h: Include <idvec.h>. (struct protid): Delete members `uids', `gids', `nuids' and `ngids'. New member `user'.
1996-09-05*** empty log message ***Thomas Bushnell
1996-07-08(diskfs_S_fsys_init): Don't use unsafe MOVE_SEND in call to exec_init.Michael I. Bushnell
1996-06-13(diskfs_S_fsys_init): Build version string correctly.Michael I. Bushnell
1996-04-30(diskfs_S_fsys_init): diskfs_init_completed -> _diskfs_init_completed.Michael I. Bushnell
1996-04-11(diskfs_start_bootstrap): Print helpful message before doing anythingMichael I. Bushnell
else.
1996-01-27(diskfs_start_bootstrap, diskfs_S_exec_startup_get_info,Miles Bader
diskfs_execboot_fsys_startup, diskfs_S_fsys_init): Use diskfs_create_protid instead of diskfs_make_protid, and deal with an error return. (start_execserver, diskfs_start_bootstrap): Use ports_create_port instead of ports_allocate_port.
1995-12-20(diskfs_S_fsys_init): Call proc_mark_exec on EXECPROCESS.Roland McGrath
1995-11-18(diskfs_S_exec_startup_get_info): Renamed from diskfs_S_exec_startup,Roland McGrath
slightly different protocol. Unused exec server stubs removed.
1995-11-02(diskfs_execboot_fsys_startup): Add FLAGS arg; use.Miles Bader
1995-10-19(diskfs_execboot_fsys_startup):Miles Bader
Open exec's realnode read-only for now, since we know it doesn't matter and having gratuitously writable nodes around prevents us from starting up or going read-only. (diskfs_S_fsys_init): Don't make the cwdir/crdir right with O_WRITE.
1995-10-13(saved_argv): Variable removed.Miles Bader
(diskfs_argv): New variable. Should get set by default arg parser. (diskfs_start_bootstrap): Get rid of ARGV argument. (diskfs_S_fsys_init): Use DISKFS_ARGV instead of SAVED_ARGV. (diskfs_execboot_fsys_startup): Fix args to dir_lookup. Declare PATHBUF and RETRY. (diskfs_S_fsys_init): Put the contents of diskfs_init_completed in here, freeing that routine for user-use.
1995-10-12(diskfs_execboot_fsys_startup): Use dir_lookup instead ofRoland McGrath
hurd_file_name_lookup to open /servers/exec.
1995-10-09(diskfs_execboot_fsys_startup): Fix typo in last change.Roland McGrath
1995-10-09(diskfs_execboot_fsys_startup): Pass back a port to /servers/exec in *REAL.Roland McGrath
1995-10-07(diskfs_S_fsys_getpriv): Use get_privileged_ports to get the privileged ports.Miles Bader
(diskfs_start_bootstrap): Use diskfs_boot_flags instead of diskfs_bootflagarg. (diskfs_start_bootstrap, start_execserver): Look for flags directly in diskfs_boot_flags, instead of using the old diskfs_bootflags. (diskfs_S_exec_startup): Use get_console to get the console device. (get_console): New function.
1995-09-17(diskfs_S_exec_startup): Don't pass an argument string.Roland McGrath
Set *FLAGS to EXEC_STACK_ARGS.
1995-07-22(start_execserver): Tyo.Michael I. Bushnell
1995-07-21(diskfs_start_bootstrap): Free initial reference created by diskfs_make_protid.Michael I. Bushnell
(diskfs_S_exec_startup): Likewise. (diskfs_S_fsys_init): Likewise.
1995-07-21(start_execserver): Free initial reference created by ports_allocate_port.Michael I. Bushnell
1995-07-21(diskfs_start_bootstrap): Free initial reference created byMichael I. Bushnell
ports_allocate_port.
1995-06-26(diskfs_S_fsys_getpriv): New parms REPLY and REPLYTYPE.Michael I. Bushnell
1995-06-09Provide unused attributes where appropriate.Michael I. Bushnell
1995-06-09(diskfs_start_bootstrap): Use new args for ports_allocate_port.Michael I. Bushnell
(start_execserver): Likewise. (diskfs_S_exec_startup): Use ports_lookup_port and ports_port_deref instead of ports_check_port_type and ports_done_with_port. (diskfs_execboot_fsys_startup): Likewise. (diskfs_S_fsys_init): Likewise. (diskfs_S_fsys_getpriv): Likewise.
1995-05-13(start_execserver): Don't create and load a task; the exec server file isRoland McGrath
no longer linked into the filesystem. Just set the bootstrap port of diskfs_execserver_task and resume it.
1995-03-07(diskfs_S_fsys_init): Use assert_perror instead of assert whereMichael I. Bushnell
appropriate. (diskfs_start_bootstrap): Likewise.
1994-12-11(start_execserver): Fix braino in last change.Roland McGrath
1994-12-11(start_execserver): When aligning bss size for vm_allocate, don't includeRoland McGrath
bss start alignment fixup offset.
1994-10-29entered into RCSRoland McGrath
1994-10-25Formerly boot-start.c.~34~Michael I. Bushnell
1994-10-07Formerly boot-start.c.~33~Roland McGrath
1994-10-07Formerly boot-start.c.~32~Roland McGrath
1994-10-06Formerly boot-start.c.~31~Michael I. Bushnell