Ignore:
File:
1 edited

Legend:

Unmodified
Added
Removed
  • uspace/srv/devman/devman.c

    r96b02eb9 r463e734  
    498498 * @param phone         The phone to the driver.
    499499 */
    500 void set_driver_phone(driver_t *driver, sysarg_t phone)
     500void set_driver_phone(driver_t *driver, ipcarg_t phone)
    501501{
    502502        fibril_mutex_lock(&driver->driver_mutex);
     
    678678}
    679679
     680static FIBRIL_MUTEX_INITIALIZE(add_device_guard);
     681
    680682/** Pass a device to running driver.
    681683 *
     
    685687void add_device(int phone, driver_t *drv, node_t *node, dev_tree_t *tree)
    686688{
     689        fibril_mutex_lock(&add_device_guard);
     690
    687691        /*
    688692         * We do not expect to have driver's mutex locked as we do not
     
    692696            node->name);
    693697       
    694         sysarg_t rc;
     698        ipcarg_t rc;
    695699        ipc_call_t answer;
    696700       
     
    715719        /* Wait for answer from the driver. */
    716720        async_wait_for(req, &rc);
     721
     722        fibril_mutex_unlock(&add_device_guard);
    717723
    718724        switch(rc) {
     
    760766                start_driver(drv);
    761767        }
     768        fibril_mutex_unlock(&drv->driver_mutex);
     769       
     770        fibril_mutex_lock(&drv->driver_mutex);
    762771        bool is_running = drv->state == DRIVER_RUNNING;
    763772        fibril_mutex_unlock(&drv->driver_mutex);
Note: See TracChangeset for help on using the changeset viewer.