History log of /barrelfish-master/lib/barrelfish/spawn_client.c
Revision Date Author Comments
# 9bd8d1d5 03-Apr-2019 Reto Achermann <reto.achermann@inf.ethz.ch>

replacing umlaute and fixing address in headers Haldeneggsteig -> Universitaetsstrasse

Signed-off-by: Reto Achermann <reto.achermann@inf.ethz.ch>


# 7fccf211 09-Oct-2017 Roni Häcki <roni.haecki@inf.ethz.ch>

proc_mgmt: get status query implemented

Signed-off-by: Roni Häcki <roni.haecki@inf.ethz.ch>


# f5700f6b 09-Oct-2017 Roni Häcki <roni.haecki@inf.ethz.ch>

proc_mgmt: getting domain list implemented

Signed-off-by: Roni Häcki <roni.haecki@inf.ethz.ch>


# 23d2c2be 09-Oct-2017 Roni Häcki <roni.haecki@inf.ethz.ch>

proc_mgmt: implementation spawn_wait() with nohang flag

Signed-off-by: Roni Häcki <roni.haecki@inf.ethz.ch>


# dec56e53 06-Oct-2017 Roni Häcki <roni.haecki@inf.ethz.ch>

proc_mgmt: merged proc management client with spawnd client

Signed-off-by: Roni Häcki <roni.haecki@inf.ethz.ch>


# 05cfd061 05-Oct-2017 Roni Häcki <roni.haecki@inf.ethz.ch>

libbarrelfish: started merging proc_mgmt_client and spawn_client

The arugments for spawn_* calls change from domainid_t to
a cap to do any kind of referencing a process.

Signed-off-by: Roni Häcki <roni.haecki@inf.ethz.ch>


# 0d01b285 09-Jun-2017 Razvan Damachi <razvan.damachi@gmail.com>

Refactor process manager to enable spawnd discovery.

The process manager now allocates a special LMP endpoint for monitor.0 and
gives said endpoint to monitor.0 as part of the export_cb. After monitor.0
spawns spawnd, it uses that endpoint to send the new spawnd's iref to the
process manager. The latter then binds with spawnd, to keep track of its state.

For app cores, a similar workflow applies, except inter-monitor communication
is now performed. Namely, the new app core's monitor sends the new app core's
spawnd to monitor.0, which forwards it to the process manager. The latter then
binds with the app core's spawnd just the same.

Diagrams for the discovery protocol can be found at https://goo.gl/eJE37u.

Signed-off-by: Razvan Damachi <razvan.damachi@gmail.com>


# 72f5137d 03-May-2017 Gerd Zellweger <mail@gerdzellweger.com>

Removed if/octopus_defs.h from public header file.

Referenced in definitions.h and trigger.h.

trigger.h is problematic because it provides helper functions for
types definied in the interface. Clients that want to use trigger.h
now have to make sure to include the interface file.

Signed-off-by: Gerd Zellweger <mail@gerdzellweger.com>


# 244ab29c 27-Feb-2017 Adam Turowski <adam.turowski@inf.ethz.ch>

flounder: merging rpc client with a binding layer

Signed-off-by: Adam Turowski <adam.turowski@inf.ethz.ch>


# 628bb6bd 21-Dec-2016 Adam Turowski <adam.turowski@inf.ethz.ch>

flounder,waitsets: adding chanstate dependency in order to wait for a specific chanstate with minimal side effects

Signed-off-by: Adam Turowski <adam.turowski@inf.ethz.ch>


# eadd9d4c 26-Jul-2016 Adam Turowski <adam.turowski@inf.ethz.ch>

Adjustments of IPC to match new convention (static buffers).
(Flounder) Fixing a token passing in 32-bit architectures.

Signed-off-by: Adam Turowski <adam.turowski@inf.ethz.ch>


# 983d8656 08-Jul-2016 Simon Gerber <simon.gerber@inf.ethz.ch>

T258: fish: only create master inherit cnode once

Signed-off-by: Simon Gerber <simon.gerber@inf.ethz.ch>


# cd66fb54 15-Jun-2015 Moritz Hoffmann <moritz.hoffmann@inf.ethz.ch>

T119: kernel, spawnd, fish: Use dispatcher invocations to dump capability information

Signed-off-by: Moritz Hoffmann <moritz.hoffmann@inf.ethz.ch>


# d13f768d 04-Dec-2014 Simon Gerber <simon.gerber@inf.ethz.ch>

Fixed libbarrelfish spawn_client() and fish_arm to use standard functionality.


# 877b0021 21-Nov-2014 Gerd Zellweger <mail@gerdzellweger.com>

Return number of instance spawned in spawn_on_all_cores.

This also allows to remove the get_num_cores call in the
monitor and is the more sane approach anyways with dynamic
cores.


# b25a6d8f 21-Nov-2014 Gerd Zellweger <mail@gerdzellweger.com>

Change spawn_program_on_all_cores implementation.

We can no longer rely on monitor giving us core count.


# e361b666 05-Nov-2014 Simon Gerber <simon.gerber@inf.ethz.ch>

Cleaned up remaining debug printfs.


# 64a32dec 31-Oct-2014 Simon Gerber <simon.gerber@inf.ethz.ch>

tmp: debugging pandaboard fish not able to spawn domains.


# eed1a729 31-Oct-2014 Simon Gerber <simon.gerber@inf.ethz.ch>

Revert "Trying to debug why fish can't connect to spawnd."

This reverts commit c5a533a3b4e8ef2a330337f8ef00b8af7516c54d.

Removes a bunch of debug printfs.


# 72abd214 31-Oct-2014 Simon Gerber <simon.gerber@inf.ethz.ch>

Revert "Debugging pandaboard lockups."

This reverts commit c9508d8dec6fa9b6fdbd0ca7d59ab82d19ddb094.

Remove a bunch of printfs that we don't need anymore.

Conflicts:
usr/monitor/include/monitor_debug.h
usr/monitor/monitor_server.c
usr/monitor/queue.c


# cbf4d6a9 20-Oct-2014 Simon Gerber <simon.gerber@inf.ethz.ch>

fixed merge errors in usr/spawnd/service.c


# b9af8f7e 28-Aug-2014 Reto Achermann <acreto@student.ethz.ch>

spawn: added handling of spawn flags

Added a spawnflags parameter to the command line and forwarding of
spawnflags to spawnd

Added a spawn flag SPAWN_FLAGS_OMP for parsing openMP functions.


# 7b1c61d7 03-Aug-2014 Reto Achermann <acreto@student.ethz.ch>

Reverted and applied Simon's xcore patch

diff --git a/lib/barrelfish/spawn_client.c
b/lib/barrelfish/spawn_client.c
index 6365801..05ccb30 100644
--- a/lib/barrelfish/spawn_client.c
+++ b/lib/barrelfish/spawn_client.c
@@ -21,6 +21,7 @@
#include <barrelfish/spawn_client.h>
#include <barrelfish/cpu_arch.h>
#include <if/spawn_rpcclient_defs.h>
+#include <if/monitor_defs.h>
#include <vfs/vfs_path.h>

extern char **environ;
@@ -189,6 +190,13 @@ errval_t spawn_program_with_caps(coreid_t coreid,
const char *path,
path = pathbuf;
}

+ // XXX: HACK: change waitset on monitor binding temporarily so we
get UMP
+ // cap transfer notifications!
+ struct monitor_binding *mb = get_monitor_binding();
+ struct waitset *mon_ws = mb->waitset;
+ mb->change_waitset(mb, &cl->rpc_waitset);
+
+
if (capref_is_null(inheritcn_cap) && capref_is_null(argcn_cap)) {
err = cl->vtbl.spawn_domain(cl, path, argstr, argstrlen,
envstr, envstrlen,
@@ -203,13 +211,15 @@ errval_t spawn_program_with_caps(coreid_t coreid,
const char *path,
if (err_is_fail(err)) {
USER_PANIC_ERR(err, "error sending spawn request");
} else if (err_is_fail(msgerr)) {
- return msgerr;
+ goto out;
}

if (ret_domainid != NULL) {
*ret_domainid = domain_id;
}

+out:
+ mb->change_waitset(mb, mon_ws);
return msgerr;
}


# 8fe3cbd7 02-Aug-2014 Reto Achermann <acreto@student.ethz.ch>

spawn_with_cap: workaround

Added a workaround to spawn_with_cap to take just one capability in
order to make UMP spawning with one argcap work.


# c9508d8d 03-Apr-2014 Simon Gerber <simon.gerber@inf.ethz.ch>

Debugging pandaboard lockups.


# c5a533a3 28-Mar-2014 Simon Gerber <simon.gerber@inf.ethz.ch>

Trying to debug why fish can't connect to spawnd.


# d2d9862d 20-Mar-2014 Simon Gerber <simon.gerber@inf.ethz.ch>

turn off monitor and spawn client debugging.


# a1a50bef 19-Mar-2014 Simon Gerber <simon.gerber@inf.ethz.ch>

Hacked x-core cap transfer to short-circuit on null caps.


# 11c2c36d 18-Mar-2014 Simon Gerber <simon.gerber@inf.ethz.ch>

fixed stuff + more output.


# 25b83541 17-Mar-2014 Simon Gerber <simon.gerber@inf.ethz.ch>

monitor debug stuff + other debug msgs.


# de906f69 28-Feb-2014 Simon Peter <simpeter@cs.washington.edu>

The Arrakis backport to Barrelfish.

Here are the macro changes:
* Made lwIP an optional network stack
* Moved lwIP headers out of the general include directory
* Parallel hake
* CPU-virtualized ("arrakis") applications
* libarrakis is a new libOS that uses CPU features directly
* arrakismon is a new monitor for Arrakis apps
* QEMU Multiboot support instead of GRUB (enables KVM)
* e10k virtual function driver
* Software virtual->physical mapping (substitutes IOMMU)
* To be replaced soon with an Intel IOMMU driver
* Better GDB and stack tracing support
* New POSIX support
* pthreads, inet_*(), usleep(), syslimits.h, sigaction(), mman.h,
* resource.h, sendmsg(), recvmsg(), mkfifo(), syslog.h, sysexits.h,
* fcntl(), getegid(), getgid(), pipe(), rlimits
* epoll support
* Separate waitset for interrupts
* Thread TLS key and ID support
* Moved PCRE headers to include/, where they usually are
* Intel performance counters support
* Handle boot-time RAM overflow (for machines with >=64GB RAM)
* Arranet network stack
* Fix for build of lib/barrelfish/arch/x86_64/dispatch.c without -O2
* New comandline options to pci daemon:
* maxvfs=x, x is number of virtual functions to create for each
* device supporting it
* skb_bridge_program=x, x is SKB bridge programming script to use
* bridge_bios is a script that uses the BIOS pre-set values, like Linux
* Correctly build machine-optimized newlib parts
* Library versions of e1000 and e10k drivers
* Support for virtualization in e10k driver
* e10k datacenter control plane daemon
* Modified hellotest to be both a Barrelfish and an Arrakis application

I've decided not to include the lwIP 1.4.1 code, as the port is
not finished and who wants to use lwIP anyway with the Arrakis
network stack and mTCP being released soon. If you want this,
let me know (it's hugely superior to lwIP 1.3.1).

I've made the code backwards-compatible with Barrelfish. The
default should do what Barrelfish does. One can specify
commandline options to the PCI daemon and e10k driver to
configure I/O virtualization and the optional arrakismon allows
loading CPU-virtualized "arrakis" programs.

There are more pending changes, such as support for hardware
rate limiting and weighted round robin packet scheduling, but
I'd like these to go in first, before I push the rest.


# 8529d22b 22-Oct-2013 Gerd Zellweger <mail@gerdzellweger.com>

Refactor alloc_inheritcn_* to alloc_inheritcn_with_caps.

Instead of having an alloc_inheritcn_* function for each possible
capref in the inherit cnode.


# 8f3a5619 26-Mar-2013 Kornilios Kourtis <kkourt@inf.ethz.ch>

add a spawn_wait_coreid() function

Patch by Mateusz Olczak <mateusz@olczak.se>


# 1d66c9ae 25-Oct-2012 Raphael Fuchs <raphaelfuchs@student.ethz.ch>

Refactor: Make 'cpu_type_to_archstr' a static inline function and move it to
header file where the enum cputype is defined.


# 4cd63be2 27-Jul-2012 Samuel Hitz <samuel.hitz@gmail.com>

various adjustments to tests and benchmarks to get the to run with arm_gem5, adjusted cpu clock to 1GHz, since a lot of configurations inside gem5 assume 1Ghz clock


# ed27dfea 22-Jun-2012 Raphael Fuchs <raphaelfuchs@student.ethz.ch>

Adding functionality to inherit capabilities and pass capabilities as arguments.

The function 'spawn_domain_with_fdcap' was used to spawn a domain and
inherit the file descriptors of the current domain. A similar inheritance
mechanism is needed for session capabilities.

To this end, the function was renamed to 'spawn_domain_with_caps'. It no longer
expects an fdcap as one of the arguments but a CNode containing all the
capabilities, that should be inherited by the newly spawned domain. The layout
of this CNode is convention an defined in include/barrelfish/spawn_client.h.
Spawnd knows about these capabilities and copies them to the appropriate places.
For example, if the fdcap is present in the inherit CNode, spawnd copies it to
the corresponding slot in the task CNode.

Moreover, we need the ability to pass arbitrary capabilities to a domain at
startup for example to start a device driver. Spawnd does not have to know about
these capabilities. Which capabilities are passed in which order is an agreement
between spawner and spawnee. To this end, this patch adds another CNode argument
to the function 'spawn_domain_with_caps'. If a domain wants to pass certain
capabilites to another domain it therefore creates a CNode and places the
capabilities in this Cnode and the passes this CNode as an argument to
'spawn_domain_with_caps'. Spawnd makes this CNode available to the spawnee in
the ARGCN slot of the root CNode as either a CNode (if spawner and spawnee are
on the same core) or a ForeignCNode (if on different cores).

The first method of inheriting capabilities and the second method of passing
capabilities are intentionally kept as two arguments because of the following
reasons:
* To account for the difference in their handling. Spawnd knows about the
inherited capabilities and places each of them to appropriate places in the
spawnee's CSpace. As a result they are available early-on, i.e. before the
library initialization code for this domain runs.
* Putting both kinds of capabilities in a single flat CNode, would require
recompilation of the whole OS after adding a new capability, that should be
inherited.


# 1000eeb4 25-Apr-2012 Antoine Kaufmann <antoinek@student.ethz.ch>

Added spawn_wait_core() to wait for a domain on another core to terminate
Note that I'm not really sure if that is the way to go, or if it is just
a work around, but for now it does the job.
---
include/barrelfish/spawn_client.h | 2 ++
lib/barrelfish/spawn_client.c | 13 +++++++++++--
2 files changed, 13 insertions(+), 2 deletions(-)


# 1231090d 28-Mar-2012 Gerd Zellweger <zgerd@student.ethz.ch>

Fix broken spawn on all cores function to make ump_bench tests work again.


# 5b82322b 12-Feb-2012 Gerd Zellweger <zgerd@student.ethz.ch>

Adjusted some error values in code to remove references to chips in
name service loop-up.

--HG--
branch : octopus.chips-remove


# 70c30847 23-Jan-2012 Andrew Baumann <andrew.baumann@microsoft.com>

remove support for Beehive

see the mailing list discussion at the end of December 2011 for motivation


# d9ab9875 06-Sep-2011 akhi akhi@inf.ethz.ch <akhi akhi@inf.ethz.ch>

Remove the dependency from fish on memclient and ramclient by moving the
required functionality into lib/barrelfish.

This ensures that there is no duplicate flounder code generation for the two
clients in fish.


# c686c28d 04-Aug-2011 Simon Peter <speter@inf.ethz.ch>

Fixed spawn_program_on_all_cores() to check first whether a spawnd is
running before trying to spawn a program on that core.


# 559955b4 02-Aug-2011 Simon Peter <speter@inf.ethz.ch>

Merge from ASPLOS tree.


# 9299dcef 08-Jul-2011 Stefan Kästle <stefan.kaestle@inf.ethz.ch>

Initial version of public stable barrelfish repository.