diff options
Diffstat (limited to 'drivers/dma-buf/dma-resv.c')
-rw-r--r-- | drivers/dma-buf/dma-resv.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/dma-buf/dma-resv.c b/drivers/dma-buf/dma-resv.c index 1c8f2581cb09..1187e5e80ede 100644 --- a/drivers/dma-buf/dma-resv.c +++ b/drivers/dma-buf/dma-resv.c | |||
@@ -200,7 +200,7 @@ int dma_resv_reserve_shared(struct dma_resv *obj, unsigned int num_fences) | |||
200 | max = max(old->shared_count + num_fences, | 200 | max = max(old->shared_count + num_fences, |
201 | old->shared_max * 2); | 201 | old->shared_max * 2); |
202 | } else { | 202 | } else { |
203 | max = 4; | 203 | max = max(4ul, roundup_pow_of_two(num_fences)); |
204 | } | 204 | } |
205 | 205 | ||
206 | new = dma_resv_list_alloc(max); | 206 | new = dma_resv_list_alloc(max); |