lkml.org 
[lkml]   [2007]   [May]   [23]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [PATCH] Introduce CONFIG_VIRT_TO_BUS
Hi Al,

On Wed, 23 May 2007 08:04:50 +0100 Al Viro <viro@ftp.linux.org.uk> wrote:
>
> On Wed, May 23, 2007 at 05:01:55PM +1000, Stephen Rothwell wrote:
> > Make some offending drivers depend on it and set
> > CONFIG_ARCH_NO_VIRT_TO_BUS for ppc64 so that we don't build those drivers.
>
> Seeing how few targets _do_ have that, I'd invert the that. I.e. have
> HAS_VIRT_TO_BUS in arch/*/Kconfig for the few architectures that have
> that stuff.

NAK :-)

I did a quick look and many architecture have some definition of
virt_to_bus ...

$ grep -w virt_to_bus include/asm*/io.h
include/asm-alpha/io.h:static inline unsigned long virt_to_bus(void *address)
include/asm-alpha/io.h:#define isa_virt_to_bus virt_to_bus
include/asm-avr32/io.h:#define virt_to_bus virt_to_phys
include/asm-blackfin/io.h:#define virt_to_bus virt_to_phys
include/asm-cris/io.h:#define virt_to_bus virt_to_phys
include/asm-h8300/io.h:#define virt_to_bus virt_to_phys
include/asm-i386/io.h:#define virt_to_bus virt_to_phys
include/asm-ia64/io.h:#define virt_to_bus virt_to_phys
include/asm-m32r/io.h:#define virt_to_bus virt_to_phys
include/asm-m68knommu/io.h:#define virt_to_bus virt_to_phys
include/asm-mips/io.h:#define virt_to_bus virt_to_phys
include/asm-parisc/io.h:#define virt_to_bus virt_to_phys
include/asm-powerpc/io.h: * 32 bits still uses virt_to_bus() for it's implementation of DMA
include/asm-powerpc/io.h:static inline unsigned long virt_to_bus(volatile void * address)
include/asm-ppc/io.h:extern inline unsigned long virt_to_bus(volatile void * address)
include/asm-sh64/io.h:#define virt_to_bus virt_to_phys
include/asm-sh/io.h:#define virt_to_bus virt_to_phys
include/asm-sparc64/io.h:#define virt_to_bus virt_to_bus_not_defined_use_pci_map
include/asm-x86_64/io.h:#define virt_to_bus virt_to_phys
include/asm-xtensa/io.h: * virt_to_bus and bus_to_virt are deprecated.
include/asm-xtensa/io.h:#define virt_to_bus(x) virt_to_phys(x)

and I am not in a position to tell whether each architecture wants it or
not. At least the way I have it, each architecture maintainer can turn
it off as they want to. Otherwise I have to edit every architecture's
Kconfig and add HAS_VIRT_TO_BUS to each one.

--
Cheers,
Stephen Rothwell sfr@canb.auug.org.au
http://www.canb.auug.org.au/~sfr/
[unhandled content-type:application/pgp-signature]
\
 
 \ /
  Last update: 2007-05-23 09:27    [W:9.122 / U:0.564 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site