dma-buf: remove shared fence staging in reservation object
No need for that any more. Just replace the list when there isn't enough room any more for the additional fence. Signed-off-by: Christian König <christian.koenig@amd.com> Reviewed-by: Junwei Zhang <Jerry.Zhang@amd.com> Reviewed-by: Huang Rui <ray.huang@amd.com> Link: https://patchwork.kernel.org/patch/10626143/
This commit is contained in:
@@ -68,7 +68,6 @@ struct reservation_object_list {
|
||||
* @seq: sequence count for managing RCU read-side synchronization
|
||||
* @fence_excl: the exclusive fence, if there is one currently
|
||||
* @fence: list of current shared fences
|
||||
* @staged: staged copy of shared fences for RCU updates
|
||||
*/
|
||||
struct reservation_object {
|
||||
struct ww_mutex lock;
|
||||
@@ -76,7 +75,6 @@ struct reservation_object {
|
||||
|
||||
struct dma_fence __rcu *fence_excl;
|
||||
struct reservation_object_list __rcu *fence;
|
||||
struct reservation_object_list *staged;
|
||||
};
|
||||
|
||||
#define reservation_object_held(obj) lockdep_is_held(&(obj)->lock.base)
|
||||
@@ -95,7 +93,6 @@ reservation_object_init(struct reservation_object *obj)
|
||||
__seqcount_init(&obj->seq, reservation_seqcount_string, &reservation_seqcount_class);
|
||||
RCU_INIT_POINTER(obj->fence, NULL);
|
||||
RCU_INIT_POINTER(obj->fence_excl, NULL);
|
||||
obj->staged = NULL;
|
||||
}
|
||||
|
||||
/**
|
||||
@@ -124,7 +121,6 @@ reservation_object_fini(struct reservation_object *obj)
|
||||
|
||||
kfree(fobj);
|
||||
}
|
||||
kfree(obj->staged);
|
||||
|
||||
ww_mutex_destroy(&obj->lock);
|
||||
}
|
||||
|
Reference in New Issue
Block a user