Statistics
| Branch: | Revision:

root / hw / pci_host.c @ 59df4c11

History | View | Annotate | Download (4.9 kB)

# Date Author Comment
5256d8bf 03/28/2011 07:34 pm Isaku Yamahata

pci: use devfn for pci_find_device() instead of (slot, fn) pair

(slot, fn) pair is somewhat confusing because of ARI.
So use devfn for pci_find_device() instead of (slot, fn).

Signed-off-by: Isaku Yamahata <>
Signed-off-by: Michael S. Tsirkin <>

c646f74f 12/11/2010 11:32 pm Gleb Natapov

Add get_fw_dev_path callback for system bus.

Prints out mmio or pio used to access child device.

Signed-off-by: Gleb Natapov <>
Signed-off-by: Blue Swirl <>

6bef0436 12/11/2010 05:24 pm Alexander Graf

Make simple io mem handler endian aware

As an alternative to the 3 individual handlers, there is also a simplified
io mem hook function. To be consistent, let's add an endianness parameter
there too.

Signed-off-by: Alexander Graf <>
Signed-off-by: Blue Swirl <>

6ebf5905 12/11/2010 05:24 pm Alexander Graf

pci-host: Delegate bswap to mmio layer

The only reason we have bswap versions of the pci host code is that
most pci host devices are little endian. The ppc e500 is the only
odd one here, being big endian.

So let's directly pass the endianness down to the mmio layer and not...

4dcf7d87 03/23/2010 10:59 am Aurelien Jarno

pci_host: fix breakage

This has been broken by commit 952760bb7bce7fbfe0afcf04fee268745f297b87

Signed-off-by: Aurelien Jarno <>

952760bb 03/21/2010 09:47 pm Blue Swirl

Compile pci_host only once

Convert pci_host_conf_register_mmio_noswap(x) to
pci_host_conf_register_mmio(x, 0).

Convert pci_host_conf_register_mmio(x) to
pci_host_conf_register_mmio(x, 1) for big endian hosts, all cases
happen to be BE.

Signed-off-by: Blue Swirl <>

70539e18 03/07/2010 05:48 pm Blue Swirl

Update to a hopefully more future proof FSF address

See also 8167ee883931cb20c6264fc19d040ce2dc6ceaaa,
530e7615ce3c01882e582c84dc6304ab98a3d5c5 and
fad6cb1a565bb73f83fc0e2654489457b489e436.

Signed-off-by: Blue Swirl <>

9f6f0423 02/14/2010 04:10 pm Michael S. Tsirkin

pci_host: rewrite using rwhandler

Save a ton of code by switching pcihost to use rwhandler.

Signed-off-by: Michael S. Tsirkin <>

0b987f19 01/10/2010 10:54 pm Blue Swirl

PCI: Fix a typo

Fixes build with PCI_DEBUG defined.

Signed-off-by: Blue Swirl <>

42331e9f 12/01/2009 05:51 pm Isaku Yamahata

pci_host: remove unnecessary & 0xff.

This patch removes unnecessary & 0xff in pci_dev_find_by_addr().

Signed-off-by: Isaku Yamahata <>
Signed-off-by: Michael S. Tsirkin <>

f08b32fe 12/01/2009 05:51 pm Isaku Yamahata

pci: shorten pci_host_{conf, data}_register_xxx function a bit.

pci_host_data_register_io_memory and its variants are too long a bit.
So shorten them. Now they are
pci_host_{conf, data}_register_{mmio, mmio_noswap, ioport}()

Signed-off-by: Isaku Yamahata <>...

8d6514f8 12/01/2009 05:51 pm Isaku Yamahata

pci: rename (pci_/pcie_mmcfg_)addr_to_dev

This patch renames pci_addr_to_dev(), pcie_mmcfg_addr_to_dev()
to pci_dev_find_by_addr(), pcie_dev_find_by_mmcfg_addr()
as "Michael S. Tsirkin" <> suggested.

Signed-off-by: Isaku Yamahata <>...

7ac901cd 12/01/2009 05:51 pm Isaku Yamahata

pci: remove pci_addr_to_config() by open code

This patch removes pci_addr_to_config() and open code it
as suggested by Michael S. Tsirkin <>.

Signed-off-by: Isaku Yamahata <>
Signed-off-by: Michael S. Tsirkin <>

4677d8ed 12/01/2009 05:51 pm Michael S. Tsirkin

pci: simplify (pci_/pcie_mmcfg_)data_read()

Remove switch on length: we don't care about
high bits for value, so just return all ones
if no device. And add one assert().

Signed-off-by: Michael S. Tsirkin <>
Acked-by: Isaku Yamahata <>

766347cc 11/09/2009 04:43 pm Isaku Yamahata

pci: move pci host stuff from pci.c to pci_host.c

Move pci host stuff from pci.c to pci_host.c.
And add some comments.
Later pcie host bridge functions will be defined in pcie_host.c
not to bloat pci.c.

Signed-off-by: Isaku Yamahata <>...

ce195fb5 11/09/2009 04:43 pm Isaku Yamahata

pci_host: change the signature of pci_data_{read, write}.

change the first argument, void opaque to PCIBus *s
of the pci_data_{read, write}.
They aren't used as direct callback so the argument type
don't have to be void
. So change it to the right type....

a455783b 11/09/2009 04:43 pm Isaku Yamahata

pci_host: consolidate pci config address access.

consolidate pci_config address access into pci_host.c

Signed-off-by: Isaku Yamahata <>
Signed-off-by: Anthony Liguori <>

4f5e19e6 11/09/2009 04:43 pm Isaku Yamahata

pci_host.h: move functions in pci_host.h into .c file.

split static functions in pci_host.h into pci_host.c and
pci_host_template.h.
Later a structures declared in pci_host.h, PCIHostState, will be used.
However pci_host.h doesn't allow to include itself easily. This patches...