Skip to content

Commit

Permalink
dmaengine: kill some dubious WARN_ONCEs
Browse files Browse the repository at this point in the history
dma_find_channel and dma_issue_pending_all are good places to warn about
improper api usage.  However, warning correctly means synchronizing with
dma_list_mutex, i.e. too much overhead for these fast-path calls.

Reported-by: Ingo Molnar <mingo@elte.hu>
Signed-off-by: Dan Williams <dan.j.williams@intel.com>
  • Loading branch information
Dan Williams committed Jan 19, 2009
1 parent 169d5f6 commit 83436a0
Showing 1 changed file with 0 additions and 6 deletions.
6 changes: 0 additions & 6 deletions drivers/dma/dmaengine.c
Original file line number Diff line number Diff line change
Expand Up @@ -329,9 +329,6 @@ struct dma_chan *dma_find_channel(enum dma_transaction_type tx_type)
struct dma_chan *chan;
int cpu;

WARN_ONCE(dmaengine_ref_count == 0,
"client called %s without a reference", __func__);

cpu = get_cpu();
chan = per_cpu_ptr(channel_table[tx_type], cpu)->chan;
put_cpu();
Expand All @@ -348,9 +345,6 @@ void dma_issue_pending_all(void)
struct dma_device *device;
struct dma_chan *chan;

WARN_ONCE(dmaengine_ref_count == 0,
"client called %s without a reference", __func__);

rcu_read_lock();
list_for_each_entry_rcu(device, &dma_device_list, global_node) {
if (dma_has_cap(DMA_PRIVATE, device->cap_mask))
Expand Down

0 comments on commit 83436a0

Please sign in to comment.