forked from ~ljy/RK356X_SDK_RELEASE

hc
2024-01-05 071106ecf68c401173c58808b1cf5f68cc50d390
kernel/drivers/net/ethernet/cavium/liquidio/octeon_iq.h
....@@ -292,12 +292,18 @@
292292 u32 ctxsize;
293293
294294 /** Time out and callback */
295
- size_t wait_time;
296
- size_t timeout;
295
+ size_t expiry_time;
297296 u32 iq_no;
298297 void (*callback)(struct octeon_device *, u32, void *);
299298 void *callback_arg;
299
+
300
+ int caller_is_done;
301
+ u32 sc_status;
302
+ struct completion complete;
300303 };
304
+
305
+/* max timeout (in milli sec) for soft request */
306
+#define LIO_SC_MAX_TMO_MS 60000
301307
302308 /** Maximum number of buffers to allocate into soft command buffer pool
303309 */
....@@ -319,6 +325,8 @@
319325 (((octeon_dev_ptr)->instr_queue[iq_no]->stats.field) += count)
320326
321327 int octeon_setup_sc_buffer_pool(struct octeon_device *oct);
328
+int octeon_free_sc_done_list(struct octeon_device *oct);
329
+int octeon_free_sc_zombie_list(struct octeon_device *oct);
322330 int octeon_free_sc_buffer_pool(struct octeon_device *oct);
323331 struct octeon_soft_command *
324332 octeon_alloc_soft_command(struct octeon_device *oct,
....@@ -370,6 +378,9 @@
370378 u32 force_db, void *cmd, void *buf,
371379 u32 datasize, u32 reqtype);
372380
381
+void octeon_dump_soft_command(struct octeon_device *oct,
382
+ struct octeon_soft_command *sc);
383
+
373384 void octeon_prepare_soft_command(struct octeon_device *oct,
374385 struct octeon_soft_command *sc,
375386 u8 opcode, u8 subcode,