IB/mthca: Semaphore to mutex conversions

Convert semaphores to mutexes in mthca.  Leave firmware command
interface poll_sem and event_sem as semaphores.

Signed-off-by: Roland Dreier <rolandd@cisco.com>
此提交包含在:
Roland Dreier
2006-01-30 16:45:11 -08:00
父節點 e3aa31c517
當前提交 fd9cfdd11b
共有 6 個檔案被更改,包括 37 行新增36 行删除

查看文件

@@ -44,6 +44,8 @@
#include <linux/pci.h>
#include <linux/dma-mapping.h>
#include <linux/timer.h>
#include <linux/mutex.h>
#include <asm/semaphore.h>
#include "mthca_provider.h"
@@ -111,7 +113,7 @@ enum {
struct mthca_cmd {
struct pci_pool *pool;
int use_events;
struct semaphore hcr_sem;
struct mutex hcr_mutex;
struct semaphore poll_sem;
struct semaphore event_sem;
int max_cmds;
@@ -256,7 +258,7 @@ struct mthca_av_table {
};
struct mthca_mcg_table {
struct semaphore sem;
struct mutex mutex;
struct mthca_alloc alloc;
struct mthca_icm_table *table;
};
@@ -301,7 +303,7 @@ struct mthca_dev {
u64 ddr_end;
MTHCA_DECLARE_DOORBELL_LOCK(doorbell_lock)
struct semaphore cap_mask_mutex;
struct mutex cap_mask_mutex;
void __iomem *hcr;
void __iomem *kar;