Whamcloud - gitweb
LU-1346 libcfs: cleanup macros in kp30.h
[fs/lustre-release.git] / lnet / klnds / ralnd / ralnd.h
index fbea48d..8b92cdc 100644 (file)
@@ -26,6 +26,8 @@
 /*
  * Copyright (c) 2004, 2010, Oracle and/or its affiliates. All rights reserved.
  * Use is subject to license terms.
+ *
+ * Copyright (c) 2012, Intel Corporation.
  */
 /*
  * This file is part of Lustre, http://www.lustre.org/
@@ -45,7 +47,6 @@
 #include <linux/unistd.h>
 #include <linux/uio.h>
 
-#include <asm/system.h>
 #include <asm/uaccess.h>
 #include <asm/io.h>
 
@@ -112,7 +113,7 @@ typedef struct
         cfs_list_t             rad_ready_conns;/* connections ready to tx/rx */
         cfs_list_t             rad_new_conns; /* new connections to complete */
         cfs_waitq_t            rad_waitq;     /* scheduler waits here */
-        cfs_spinlock_t         rad_lock;      /* serialise */
+       spinlock_t              rad_lock;       /* serialise */
         void                  *rad_scheduler; /* scheduling thread */
         unsigned int           rad_nphysmap;  /* # phys mappings */
         unsigned int           rad_nppphysmap;/* # phys pages mapped */
@@ -130,7 +131,7 @@ typedef struct
         kra_device_t      kra_devices[RANAL_MAXDEVS]; /* device/ptag/cq */
         int               kra_ndevs;           /* # devices */
 
-        cfs_rwlock_t      kra_global_lock;     /* stabilize peer/conn ops */
+       rwlock_t          kra_global_lock;      /* stabilize peer/conn ops */
 
         cfs_list_t       *kra_peers;           /* hash table of all my known peers */
         int               kra_peer_hash_size;  /* size of kra_peers */
@@ -146,16 +147,16 @@ typedef struct
 
         long              kra_new_min_timeout; /* minimum timeout on any new conn */
         cfs_waitq_t       kra_reaper_waitq;    /* reaper sleeps here */
-        cfs_spinlock_t    kra_reaper_lock;     /* serialise */
+       spinlock_t        kra_reaper_lock;     /* serialise */
 
         cfs_list_t        kra_connd_peers;     /* peers waiting for a connection */
         cfs_list_t        kra_connd_acceptq;   /* accepted sockets to handshake */
         cfs_waitq_t       kra_connd_waitq;     /* connection daemons sleep here */
-        cfs_spinlock_t    kra_connd_lock;      /* serialise */
+       spinlock_t        kra_connd_lock;       /* serialise */
 
         cfs_list_t        kra_idle_txs;        /* idle tx descriptors */
         __u64             kra_next_tx_cookie;  /* RDMA completion cookie */
-        cfs_spinlock_t    kra_tx_lock;         /* serialise */
+       spinlock_t        kra_tx_lock;          /* serialise */
 } kra_data_t;
 
 #define RANAL_INIT_NOTHING         0
@@ -309,7 +310,7 @@ typedef struct kra_conn
         unsigned int        rac_close_recvd;   /* I've received CLOSE */
         unsigned int        rac_state;         /* connection state */
         unsigned int        rac_scheduled;     /* being attented to */
-        cfs_spinlock_t      rac_lock;          /* serialise */
+       spinlock_t          rac_lock;           /* serialise */
         kra_device_t       *rac_device;        /* which device */
         RAP_PVOID           rac_rihandle;      /* RA endpoint */
         kra_msg_t          *rac_rxmsg;         /* incoming message (FMA prefix) */
@@ -451,7 +452,7 @@ extern kra_peer_t *kranal_find_peer_locked (lnet_nid_t nid);
 extern void kranal_post_fma (kra_conn_t *conn, kra_tx_t *tx);
 extern int kranal_del_peer (lnet_nid_t nid);
 extern void kranal_device_callback (RAP_INT32 devid, RAP_PVOID arg);
-extern int kranal_thread_start (int(*fn)(void *arg), void *arg);
+extern int kranal_thread_start(int(*fn)(void *arg), void *arg, char *name);
 extern int kranal_connd (void *arg);
 extern int kranal_reaper (void *arg);
 extern int kranal_scheduler (void *arg);