forked from ~ljy/RK356X_SDK_RELEASE

hc
2023-12-11 6778948f9de86c3cfaf36725a7c87dcff9ba247f
kernel/drivers/infiniband/hw/hfi1/sdma.h
....@@ -1,7 +1,7 @@
11 #ifndef _HFI1_SDMA_H
22 #define _HFI1_SDMA_H
33 /*
4
- * Copyright(c) 2015, 2016 Intel Corporation.
4
+ * Copyright(c) 2015 - 2018 Intel Corporation.
55 *
66 * This file is provided under a dual BSD/GPLv2 license. When using or
77 * redistributing this file, you may do so under either license.
....@@ -61,16 +61,6 @@
6161 #define MAX_DESC 64
6262 /* Hardware limit for SDMA packet size */
6363 #define MAX_SDMA_PKT_SIZE ((16 * 1024) - 1)
64
-
65
-#define SDMA_TXREQ_S_OK 0
66
-#define SDMA_TXREQ_S_SENDERROR 1
67
-#define SDMA_TXREQ_S_ABORTED 2
68
-#define SDMA_TXREQ_S_SHUTDOWN 3
69
-
70
-/* flags bits */
71
-#define SDMA_TXREQ_F_URGENT 0x0001
72
-#define SDMA_TXREQ_F_AHG_COPY 0x0002
73
-#define SDMA_TXREQ_F_USE_AHG 0x0004
7464
7565 #define SDMA_MAP_NONE 0
7666 #define SDMA_MAP_SINGLE 1
....@@ -392,6 +382,7 @@
392382 u64 progress_int_cnt;
393383
394384 /* private: */
385
+ seqlock_t waitlock;
395386 struct list_head dmawait;
396387
397388 /* CONFIG SDMA for now, just blindly duplicate */
....@@ -415,6 +406,7 @@
415406 struct list_head flushlist;
416407 struct cpumask cpu_mask;
417408 struct kobject kobj;
409
+ u32 msix_intr;
418410 };
419411
420412 int sdma_init(struct hfi1_devdata *dd, u8 port);
....@@ -849,16 +841,16 @@
849841 dd, SDMA_MAP_SINGLE, tx, addr, len);
850842 }
851843
852
-struct iowait;
844
+struct iowait_work;
853845
854846 int sdma_send_txreq(struct sdma_engine *sde,
855
- struct iowait *wait,
847
+ struct iowait_work *wait,
856848 struct sdma_txreq *tx,
857849 bool pkts_sent);
858850 int sdma_send_txlist(struct sdma_engine *sde,
859
- struct iowait *wait,
851
+ struct iowait_work *wait,
860852 struct list_head *tx_list,
861
- u32 *count);
853
+ u16 *count_out);
862854
863855 int sdma_ahg_alloc(struct sdma_engine *sde);
864856 void sdma_ahg_free(struct sdma_engine *sde, int ahg_index);
....@@ -1010,7 +1002,7 @@
10101002 */
10111003 struct sdma_map_elem {
10121004 u32 mask;
1013
- struct sdma_engine *sde[0];
1005
+ struct sdma_engine *sde[];
10141006 };
10151007
10161008 /**
....@@ -1032,7 +1024,7 @@
10321024 u32 mask;
10331025 u8 actual_vls;
10341026 u8 vls;
1035
- struct sdma_map_elem *map[0];
1027
+ struct sdma_map_elem *map[];
10361028 };
10371029
10381030 int sdma_map_init(