We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 9c7e355 commit f3dc1b3Copy full SHA for f3dc1b3
drivers/dma/dmaengine.c
@@ -451,7 +451,8 @@ static int dma_chan_get(struct dma_chan *chan)
451
/* The channel is already in use, update client count */
452
if (chan->client_count) {
453
__module_get(owner);
454
- goto out;
+ chan->client_count++;
455
+ return 0;
456
}
457
458
if (!try_module_get(owner))
@@ -470,11 +471,11 @@ static int dma_chan_get(struct dma_chan *chan)
470
471
goto err_out;
472
473
474
475
+
476
if (!dma_has_cap(DMA_PRIVATE, chan->device->cap_mask))
477
balance_ref_count(chan);
478
-out:
- chan->client_count++;
479
return 0;
480
481
err_out:
0 commit comments