aboutsummaryrefslogtreecommitdiffstats
path: root/drivers
diff options
context:
space:
mode:
Diffstat (limited to 'drivers')
-rw-r--r--drivers/net/ehea/ehea.h2
-rw-r--r--drivers/net/ehea/ehea_main.c18
2 files changed, 10 insertions, 10 deletions
diff --git a/drivers/net/ehea/ehea.h b/drivers/net/ehea/ehea.h
index 93b7fb246960..f07af2c3bcbe 100644
--- a/drivers/net/ehea/ehea.h
+++ b/drivers/net/ehea/ehea.h
@@ -421,7 +421,7 @@ struct ehea_fw_handle_entry {
421struct ehea_fw_handle_array { 421struct ehea_fw_handle_array {
422 struct ehea_fw_handle_entry *arr; 422 struct ehea_fw_handle_entry *arr;
423 int num_entries; 423 int num_entries;
424 struct semaphore lock; 424 struct mutex lock;
425}; 425};
426 426
427struct ehea_bcmc_reg_entry { 427struct ehea_bcmc_reg_entry {
diff --git a/drivers/net/ehea/ehea_main.c b/drivers/net/ehea/ehea_main.c
index a3b3b165445a..4ae65e876487 100644
--- a/drivers/net/ehea/ehea_main.c
+++ b/drivers/net/ehea/ehea_main.c
@@ -2453,7 +2453,7 @@ static int ehea_up(struct net_device *dev)
2453 if (port->state == EHEA_PORT_UP) 2453 if (port->state == EHEA_PORT_UP)
2454 return 0; 2454 return 0;
2455 2455
2456 down(&ehea_fw_handles.lock); 2456 mutex_lock(&ehea_fw_handles.lock);
2457 2457
2458 ret = ehea_port_res_setup(port, port->num_def_qps, 2458 ret = ehea_port_res_setup(port, port->num_def_qps,
2459 port->num_add_tx_qps); 2459 port->num_add_tx_qps);
@@ -2517,7 +2517,7 @@ out:
2517 up(&ehea_bcmc_regs.lock); 2517 up(&ehea_bcmc_regs.lock);
2518 2518
2519 ehea_update_firmware_handles(); 2519 ehea_update_firmware_handles();
2520 up(&ehea_fw_handles.lock); 2520 mutex_unlock(&ehea_fw_handles.lock);
2521 2521
2522 return ret; 2522 return ret;
2523} 2523}
@@ -2573,7 +2573,7 @@ static int ehea_down(struct net_device *dev)
2573 2573
2574 ehea_free_interrupts(dev); 2574 ehea_free_interrupts(dev);
2575 2575
2576 down(&ehea_fw_handles.lock); 2576 mutex_lock(&ehea_fw_handles.lock);
2577 2577
2578 port->state = EHEA_PORT_DOWN; 2578 port->state = EHEA_PORT_DOWN;
2579 2579
@@ -2586,7 +2586,7 @@ static int ehea_down(struct net_device *dev)
2586 dev->name, ret); 2586 dev->name, ret);
2587 2587
2588 ehea_update_firmware_handles(); 2588 ehea_update_firmware_handles();
2589 up(&ehea_fw_handles.lock); 2589 mutex_unlock(&ehea_fw_handles.lock);
2590 2590
2591 return ret; 2591 return ret;
2592} 2592}
@@ -3343,7 +3343,7 @@ static int __devinit ehea_probe_adapter(struct of_device *dev,
3343 ehea_error("Invalid ibmebus device probed"); 3343 ehea_error("Invalid ibmebus device probed");
3344 return -EINVAL; 3344 return -EINVAL;
3345 } 3345 }
3346 down(&ehea_fw_handles.lock); 3346 mutex_lock(&ehea_fw_handles.lock);
3347 3347
3348 adapter = kzalloc(sizeof(*adapter), GFP_KERNEL); 3348 adapter = kzalloc(sizeof(*adapter), GFP_KERNEL);
3349 if (!adapter) { 3349 if (!adapter) {
@@ -3427,7 +3427,7 @@ out_free_ad:
3427 3427
3428out: 3428out:
3429 ehea_update_firmware_handles(); 3429 ehea_update_firmware_handles();
3430 up(&ehea_fw_handles.lock); 3430 mutex_unlock(&ehea_fw_handles.lock);
3431 return ret; 3431 return ret;
3432} 3432}
3433 3433
@@ -3446,7 +3446,7 @@ static int __devexit ehea_remove(struct of_device *dev)
3446 3446
3447 flush_scheduled_work(); 3447 flush_scheduled_work();
3448 3448
3449 down(&ehea_fw_handles.lock); 3449 mutex_lock(&ehea_fw_handles.lock);
3450 3450
3451 ibmebus_free_irq(adapter->neq->attr.ist1, adapter); 3451 ibmebus_free_irq(adapter->neq->attr.ist1, adapter);
3452 tasklet_kill(&adapter->neq_tasklet); 3452 tasklet_kill(&adapter->neq_tasklet);
@@ -3457,7 +3457,7 @@ static int __devexit ehea_remove(struct of_device *dev)
3457 kfree(adapter); 3457 kfree(adapter);
3458 3458
3459 ehea_update_firmware_handles(); 3459 ehea_update_firmware_handles();
3460 up(&ehea_fw_handles.lock); 3460 mutex_unlock(&ehea_fw_handles.lock);
3461 3461
3462 return 0; 3462 return 0;
3463} 3463}
@@ -3544,7 +3544,7 @@ int __init ehea_module_init(void)
3544 memset(&ehea_fw_handles, 0, sizeof(ehea_fw_handles)); 3544 memset(&ehea_fw_handles, 0, sizeof(ehea_fw_handles));
3545 memset(&ehea_bcmc_regs, 0, sizeof(ehea_bcmc_regs)); 3545 memset(&ehea_bcmc_regs, 0, sizeof(ehea_bcmc_regs));
3546 3546
3547 sema_init(&ehea_fw_handles.lock, 1); 3547 mutex_init(&ehea_fw_handles.lock);
3548 sema_init(&ehea_bcmc_regs.lock, 1); 3548 sema_init(&ehea_bcmc_regs.lock, 1);
3549 3549
3550 ret = check_module_parm(); 3550 ret = check_module_parm();