Skip to content

Commit

Permalink
sh: Fix up MAX_DMA_CHANNELS definition when DMA is disabled.
Browse files Browse the repository at this point in the history
MAX_DMA_CHANNELS is tested for the total number of channels in order to
populate an IRQ map. Stub this out completely when no DMA support is
enabled -- as used to be the default behaviour before this was
generalized for use by the dmaengine code.

Signed-off-by: Paul Mundt <lethal@linux-sh.org>
  • Loading branch information
Paul Mundt committed Dec 17, 2009
1 parent 4385af8 commit 2f7bb2d
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions arch/sh/include/asm/dma.h
Original file line number Diff line number Diff line change
Expand Up @@ -19,9 +19,11 @@
#include <asm-generic/dma.h>

#ifdef CONFIG_NR_DMA_CHANNELS
# define MAX_DMA_CHANNELS (CONFIG_NR_DMA_CHANNELS)
# define MAX_DMA_CHANNELS (CONFIG_NR_DMA_CHANNELS)
#elif defined(CONFIG_NR_ONCHIP_DMA_CHANNELS)
# define MAX_DMA_CHANNELS (CONFIG_NR_ONCHIP_DMA_CHANNELS)
#else
# define MAX_DMA_CHANNELS (CONFIG_NR_ONCHIP_DMA_CHANNELS)
# define MAX_DMA_CHANNELS 0
#endif

/*
Expand Down

0 comments on commit 2f7bb2d

Please sign in to comment.