Re: [PATCH 13/32] KVM: s390: pci: add basic kvm_zdev structure

Pierre Morel
2021-12-20T17:25:17Z

On 12/17/21 21:26, Matthew Rosato wrote:
> On 12/7/21 3:57 PM, Matthew Rosato wrote:
>> This structure will be used to carry kvm passthrough information
>> related to
>> zPCI devices.
>>
>> Signed-off-by: Matthew Rosato <mjrosato@linux.ibm.com>
>> ---
> ...
>>   static inline bool zdev_enabled(struct zpci_dev *zdev)
>> diff --git a/arch/s390/kvm/Makefile b/arch/s390/kvm/Makefile
>> index b3aaadc60ead..95ea865e5d29 100644
>> --- a/arch/s390/kvm/Makefile
>> +++ b/arch/s390/kvm/Makefile
>> @@ -10,6 +10,6 @@ common-objs = $(KVM)/kvm_main.o $(KVM)/eventfd.o
>> $(KVM)/async_pf.o \
>>   ccflags-y := -Ivirt/kvm -Iarch/s390/kvm
>>   kvm-objs := $(common-objs) kvm-s390.o intercept.o interrupt.o priv.o
>> sigp.o
>> -kvm-objs += diag.o gaccess.o guestdbg.o vsie.o pv.o
>> +kvm-objs += diag.o gaccess.o guestdbg.o vsie.o pv.o pci.o
>
> This should instead be
>
> kvm-objs-$(CONFIG_PCI) += pci.o
>
> I think this makes sense as we aren't about to do PCI passthrough
> support anyway if the host kernel doesn't support PCI (no vfio-pci,
> etc).   This will quiet the kernel test robot complaints about
> CONFIG_PCI_NR_FUNCTIONS seen on the next patch in this series.

hum, then you will need more than this to put all pci references in
priv.c and kvm-s390.c away.

>
>>   obj-$(CONFIG_KVM) += kvm.o

--
Pierre Morel
IBM Lab Boeblingen