LCOV - code coverage report
Current view: top level - drivers/gpu/drm/i915 - i915_sw_fence_work.h (source / functions) Hit Total Coverage
Test: combined.info Lines: 0 3 0.0 %
Date: 2022-04-01 14:58:12 Functions: 0 0 -
Branches: 0 0 -

           Branch data     Line data    Source code
       1                 :            : /* SPDX-License-Identifier: MIT */
       2                 :            : 
       3                 :            : /*
       4                 :            :  * Copyright © 2019 Intel Corporation
       5                 :            :  */
       6                 :            : 
       7                 :            : #ifndef I915_SW_FENCE_WORK_H
       8                 :            : #define I915_SW_FENCE_WORK_H
       9                 :            : 
      10                 :            : #include <linux/dma-fence.h>
      11                 :            : #include <linux/spinlock.h>
      12                 :            : #include <linux/workqueue.h>
      13                 :            : 
      14                 :            : #include "i915_sw_fence.h"
      15                 :            : 
      16                 :            : struct dma_fence_work;
      17                 :            : 
      18                 :            : struct dma_fence_work_ops {
      19                 :            :         const char *name;
      20                 :            :         int (*work)(struct dma_fence_work *f);
      21                 :            :         void (*release)(struct dma_fence_work *f);
      22                 :            : };
      23                 :            : 
      24                 :            : struct dma_fence_work {
      25                 :            :         struct dma_fence dma;
      26                 :            :         spinlock_t lock;
      27                 :            : 
      28                 :            :         struct i915_sw_fence chain;
      29                 :            :         struct i915_sw_dma_fence_cb cb;
      30                 :            : 
      31                 :            :         struct work_struct work;
      32                 :            :         const struct dma_fence_work_ops *ops;
      33                 :            : };
      34                 :            : 
      35                 :            : void dma_fence_work_init(struct dma_fence_work *f,
      36                 :            :                          const struct dma_fence_work_ops *ops);
      37                 :            : int dma_fence_work_chain(struct dma_fence_work *f, struct dma_fence *signal);
      38                 :            : 
      39                 :          0 : static inline void dma_fence_work_commit(struct dma_fence_work *f)
      40                 :            : {
      41                 :          0 :         i915_sw_fence_commit(&f->chain);
      42                 :          0 : }
      43                 :            : 
      44                 :            : #endif /* I915_SW_FENCE_WORK_H */

Generated by: LCOV version 1.14