Ignore:
Timestamp:
Mar 12, 2021, 11:14:36 PM (5 years ago)
Author:
Peter A. Buhr <pabuhr@…>
Branches:
ADT, arm-eh, ast-experimental, enum, forall-pointer-decay, jacob/cs343-translation, master, new-ast-unique-expr, pthread-emulation, qualifiedEnum
Children:
5f39135, b0d5c0c
Parents:
2d019af (diff), df65c0c (diff)
Note: this is a merge changeset, the changes displayed below correspond to the merge itself.
Use the (diff) links above to see all the changes relative to each parent.
Message:

Merge branch 'master' of plg.uwaterloo.ca:software/cfa/cfa-cc

File:
1 edited

Legend:

Unmodified
Added
Removed
  • libcfa/src/concurrency/kernel/startup.cfa

    r2d019af r41ca6fa  
    7373static void __kernel_first_resume( processor * this );
    7474static void __kernel_last_resume ( processor * this );
    75 static void init(processor & this, const char name[], cluster & _cltr);
     75static void init(processor & this, const char name[], cluster & _cltr, void (*fnc) (void *), void * arg);
    7676static void deinit(processor & this);
    7777static void doregister( struct cluster & cltr );
     
    198198                ( this.terminated ){};
    199199                ( this.runner ){};
    200                 init( this, "Main Processor", *mainCluster );
     200                init( this, "Main Processor", *mainCluster, 0p, 0p );
    201201                kernel_thread = pthread_self();
    202202
     
    452452}
    453453
    454 static void init(processor & this, const char name[], cluster & _cltr) with( this ) {
     454static void init(processor & this, const char name[], cluster & _cltr, void (*fnc) (void *), void * arg) with( this ) {
    455455        this.name = name;
    456456        this.cltr = &_cltr;
     
    464464        this.io.dirty   = false;
    465465
     466        this.init.fnc = fnc;
     467        this.init.arg = arg;
     468
    466469        this.idle = eventfd(0, 0);
    467470        if (idle < 0) {
     
    513516}
    514517
    515 void ?{}(processor & this, const char name[], cluster & _cltr) {
     518void ?{}(processor & this, const char name[], cluster & _cltr, void (*fnc) (void *), void * arg) {
    516519        ( this.terminated ){};
    517520        ( this.runner ){};
    518521
    519522        disable_interrupts();
    520                 init( this, name, _cltr );
     523                init( this, name, _cltr, fnc, arg );
    521524        enable_interrupts( __cfaabi_dbg_ctx );
    522525
Note: See TracChangeset for help on using the changeset viewer.