IB/ehca: Implement modify_port
[firefly-linux-kernel-4.4.55.git] / drivers / infiniband / hw / ehca / ehca_classes.h
index 40404c9e28179558d45feccc83880feb8b4132b5..10fb8fbafa0c4cd31457ae3d511586b0a7e54c20 100644 (file)
@@ -52,6 +52,8 @@ struct ehca_mw;
 struct ehca_pd;
 struct ehca_av;
 
+#include <linux/wait.h>
+
 #include <rdma/ib_verbs.h>
 #include <rdma/ib_user_verbs.h>
 
@@ -104,6 +106,7 @@ struct ehca_shca {
        struct ehca_mr *maxmr;
        struct ehca_pd *pd;
        struct h_galpas galpas;
+       struct mutex modify_mutex;
 };
 
 struct ehca_pd {
@@ -153,7 +156,9 @@ struct ehca_cq {
        spinlock_t cb_lock;
        struct hlist_head qp_hashtab[QP_HASHTAB_LEN];
        struct list_head entry;
-       u32 nr_callbacks;
+       u32 nr_callbacks; /* #events assigned to cpu by scaling code */
+       u32 nr_events;    /* #events seen */
+       wait_queue_head_t wait_completion;
        spinlock_t task_lock;
        u32 ownpid;
        /* mmap counter for resources mapped into user space */