[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <CAErSpo6WG2R_8sa=rOmAOci-3iFpDs2NFzNkZYxDnD2oTiMQJg@mail.gmail.com>
Date: Mon, 12 Nov 2012 11:40:50 -0700
From: Bjorn Helgaas <bhelgaas@...gle.com>
To: H Hartley Sweeten <hartleys@...ionengravers.com>
Cc: "linux-kernel@...r.kernel.org" <linux-kernel@...r.kernel.org>,
Stephen Rothwell <sfr@...b.auug.org.au>
Subject: Re: Q: Kconfig option VIRT_TO_BUS
On Mon, Nov 12, 2012 at 9:18 AM, H Hartley Sweeten
<hartleys@...ionengravers.com> wrote:
> Hello all,
>
> Does anyone know what the Kconfig option VIRT_TO_BUS does?
> There are a number of "depends on" that option but it does not
> seem to directly enable any code in the kernel.
virt_to_bus() is a deprecated interface for converting a kernel
virtual address to a bus address. It's deprecated because it's
impossible to implement correctly when there are multiple bus address
spaces, because you don't know which bus address space the caller has
in mind.
See Documentation/DMA-API-HOWTO.txt and
Documentation/bus-virt-phys-mapping.txt for more details about
virt_to_bus() and its replacements (dma_map_*()).
It looks like f057eac0d7ad967138390a9dd7fd8267e1e39d19 added
CONFIG_VIRT_TO_BUS as a way to prevent drivers that use virt_to_bus()
from being built on architectures that can't support virt_to_bus().
Architectures that can't implement virt_to_bus() set
CONFIG_ARCH_NO_VIRT_TO_BUS. It looks like powerpc, sh, and sparc
currently set it, but ia64, x86, and probably other arches should also
set it.
Bjorn
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
Powered by blists - more mailing lists