2016-01-15 17:51+0100, Andrew Jones: > Also move pci_config_read into asm/pci.h > > Signed-off-by: Andrew Jones <drjones@xxxxxxxxxx> > --- > +++ b/lib/asm-generic/pci.h > @@ -0,0 +1,4 @@ > +#ifndef _ASM_GENERIC_PCI_H_ > +#define _ASM_GENERIC_PCI_H_ > +#error need architecture specific asm/pci.h > +#endif > +++ b/lib/x86/asm/pci.h > @@ -0,0 +1,19 @@ > +#ifndef ASM_PCI_H > +#define ASM_PCI_H > +/* > + * Copyright (C) 2013, Red Hat Inc, Michael S. Tsirkin <mst@xxxxxxxxxx> > + * > + * This work is licensed under the terms of the GNU LGPL, version 2. > + */ > +#include "libcflat.h" > +#include "pci.h" > +#include "asm/io.h" > + > +static inline uint32_t pci_config_read(pcidevaddr_t dev, uint8_t reg) > +{ > + uint32_t index = reg | (dev << 8) | (0x1 << 31); > + outl(index, 0xCF8); > + return inl(0xCFC); Hm, why can't this be generalized with [1/10]? Thanks. > +} > + > +#endif -- To unsubscribe from this list: send the line "unsubscribe kvm" in the body of a message to majordomo@xxxxxxxxxxxxxxx More majordomo info at http://vger.kernel.org/majordomo-info.html