RDMA/nes: Generate IB_EVENT_PORT_ERR/PORT_ACTIVE events
[firefly-linux-kernel-4.4.55.git] / drivers / infiniband / hw / nes / nes_hw.h
index 1204c3432b6322f23518c42d550746f19d9e4ce6..8a9ea9a4dc5d4288884aa7c33a60a1f23084e1d6 100644 (file)
@@ -1193,6 +1193,8 @@ struct nes_listener {
 
 struct nes_ib_device;
 
+#define NES_EVENT_DELAY msecs_to_jiffies(100)
+
 struct nes_vnic {
        struct nes_ib_device *nesibdev;
        u64 sq_full;
@@ -1247,6 +1249,10 @@ struct nes_vnic {
        u32 lro_max_aggr;
        struct net_lro_mgr lro_mgr;
        struct net_lro_desc lro_desc[NES_MAX_LRO_DESCRIPTORS];
+       struct timer_list event_timer;
+       enum ib_event_type delayed_event;
+       enum ib_event_type last_dispatched_event;
+       spinlock_t port_ibevent_lock;
 };
 
 struct nes_ib_device {