Commit 5ac6da66 authored by Christoph Lameter's avatar Christoph Lameter Committed by Linus Torvalds

[PATCH] Set CONFIG_ZONE_DMA for arches with GENERIC_ISA_DMA

As Andi pointed out: CONFIG_GENERIC_ISA_DMA only disables the ISA DMA
channel management.  Other functionality may still expect GFP_DMA to
provide memory below 16M.  So we need to make sure that CONFIG_ZONE_DMA is
set independent of CONFIG_GENERIC_ISA_DMA.  Undo the modifications to
mm/Kconfig where we made ZONE_DMA dependent on GENERIC_ISA_DMA and set
theses explicitly in each arches Kconfig.

Reviews must occur for each arch in order to determine if ZONE_DMA can be
switched off.  It can only be switched off if we know that all devices
supported by a platform are capable of performing DMA transfers to all of
memory (Some arches already support this: uml, avr32, sh sh64, parisc and
IA64/Altix).

In order to switch ZONE_DMA off conditionally, one would have to establish
a scheme by which one can assure that no drivers are enabled that are only
capable of doing I/O to a part of memory, or one needs to provide an
alternate means of performing an allocation from a specific range of memory
(like provided by alloc_pages_range()) and insure that all drivers use that
call.  In that case the arches alloc_dma_coherent() may need to be modified
to call alloc_pages_range() instead of relying on GFP_DMA.
Signed-off-by: default avatarChristoph Lameter <clameter@sgi.com>
Signed-off-by: default avatarAndrew Morton <akpm@linux-foundation.org>
Signed-off-by: default avatarLinus Torvalds <torvalds@linux-foundation.org>
parent 339ba9b1
...@@ -41,6 +41,10 @@ config GENERIC_CALIBRATE_DELAY ...@@ -41,6 +41,10 @@ config GENERIC_CALIBRATE_DELAY
bool bool
default y default y
config ZONE_DMA
bool
default y
config GENERIC_ISA_DMA config GENERIC_ISA_DMA
bool bool
default y default y
......
...@@ -100,6 +100,10 @@ config GENERIC_BUST_SPINLOCK ...@@ -100,6 +100,10 @@ config GENERIC_BUST_SPINLOCK
config ARCH_MAY_HAVE_PC_FDC config ARCH_MAY_HAVE_PC_FDC
bool bool
config ZONE_DMA
bool
default y
config GENERIC_ISA_DMA config GENERIC_ISA_DMA
bool bool
......
...@@ -60,6 +60,10 @@ config GENERIC_CALIBRATE_DELAY ...@@ -60,6 +60,10 @@ config GENERIC_CALIBRATE_DELAY
config GENERIC_BUST_SPINLOCK config GENERIC_BUST_SPINLOCK
bool bool
config ZONE_DMA
bool
default y
config GENERIC_ISA_DMA config GENERIC_ISA_DMA
bool bool
......
...@@ -38,6 +38,10 @@ config MMU ...@@ -38,6 +38,10 @@ config MMU
bool bool
default y default y
config ZONE_DMA
bool
default y
config SBUS config SBUS
bool bool
......
...@@ -16,6 +16,10 @@ config GENERIC_ISA_DMA ...@@ -16,6 +16,10 @@ config GENERIC_ISA_DMA
bool bool
default y default y
config ZONE_DMA
bool
default y
config GENERIC_HARDIRQS config GENERIC_HARDIRQS
bool bool
default y default y
......
...@@ -439,6 +439,10 @@ config GENERIC_ISA_DMA ...@@ -439,6 +439,10 @@ config GENERIC_ISA_DMA
depends on Q40 || AMIGA_PCMCIA || GG2 depends on Q40 || AMIGA_PCMCIA || GG2
default y default y
config ZONE_DMA
bool
default y
source "drivers/pci/Kconfig" source "drivers/pci/Kconfig"
source "drivers/zorro/Kconfig" source "drivers/zorro/Kconfig"
......
...@@ -8,6 +8,10 @@ mainmenu "Linux/MIPS Kernel Configuration" ...@@ -8,6 +8,10 @@ mainmenu "Linux/MIPS Kernel Configuration"
menu "Machine selection" menu "Machine selection"
config ZONE_DMA
bool
default y
choice choice
prompt "System type" prompt "System type"
default SGI_IP22 default SGI_IP22
......
...@@ -977,6 +977,10 @@ config ISA ...@@ -977,6 +977,10 @@ config ISA
have an IBM RS/6000 or pSeries machine or a PReP machine, say Y. If have an IBM RS/6000 or pSeries machine or a PReP machine, say Y. If
you have an embedded board, consult your board documentation. you have an embedded board, consult your board documentation.
config ZONE_DMA
bool
default y
config GENERIC_ISA_DMA config GENERIC_ISA_DMA
bool bool
depends on PPC64 || POWER4 || 6xx && !CPM2 depends on PPC64 || POWER4 || 6xx && !CPM2
......
...@@ -1177,6 +1177,10 @@ config ISA ...@@ -1177,6 +1177,10 @@ config ISA
have an IBM RS/6000 or pSeries machine or a PReP machine, say Y. If have an IBM RS/6000 or pSeries machine or a PReP machine, say Y. If
you have an embedded board, consult your board documentation. you have an embedded board, consult your board documentation.
config ZONE_DMA
bool
default y
config GENERIC_ISA_DMA config GENERIC_ISA_DMA
bool bool
depends on 6xx && !CPM2 depends on 6xx && !CPM2
......
...@@ -13,6 +13,10 @@ config HIGHMEM ...@@ -13,6 +13,10 @@ config HIGHMEM
bool bool
default y default y
config ZONE_DMA
bool
default y
config GENERIC_ISA_DMA config GENERIC_ISA_DMA
bool bool
default y default y
......
...@@ -232,6 +232,10 @@ config LARGE_ALLOCS ...@@ -232,6 +232,10 @@ config LARGE_ALLOCS
source "mm/Kconfig" source "mm/Kconfig"
config ZONE_DMA
bool
default y
config GENERIC_ISA_DMA config GENERIC_ISA_DMA
bool bool
default y default y
......
...@@ -44,6 +44,10 @@ config MMU ...@@ -44,6 +44,10 @@ config MMU
bool bool
default y default y
config ZONE_DMA
bool
default y
config ISA config ISA
bool bool
......
...@@ -139,10 +139,6 @@ config SPLIT_PTLOCK_CPUS ...@@ -139,10 +139,6 @@ config SPLIT_PTLOCK_CPUS
default "4096" if PARISC && !PA20 default "4096" if PARISC && !PA20
default "4" default "4"
config ZONE_DMA
def_bool y
depends on GENERIC_ISA_DMA
# #
# support for page migration # support for page migration
# #
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment