[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [PATCH 2/2] xen/pci: Gate all MSI code in common code with CONFIG_HAS_PCI_MSI


  • To: Julien Grall <julien@xxxxxxx>
  • From: Roger Pau Monné <roger.pau@xxxxxxxxxx>
  • Date: Tue, 6 Apr 2021 17:58:36 +0200
  • Arc-authentication-results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=citrix.com; dmarc=pass action=none header.from=citrix.com; dkim=pass header.d=citrix.com; arc=none
  • Arc-message-signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector9901; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=t3AELijsXTbU/SU33N79QG74GLplaaw6uFX0h98XSnU=; b=JfyfBENEQ+S2g5uTGrm+Nxkk0h31KoyjdrEW60UA7IXeO//V8GLpcA0MBgOM5kHh2CxLKEu4i9toQ4ho+RBbDGRU8oyr+2Y7v0oSIdG5lKh+63igldz/B8NcvD5ga6clrH4GeF+4Lo8ewk6cC+qsld9zRJ3jAE3pzKoNYEiDefxOfAsdpf5SkFj7zL5lK7FfyxHSsziJJVbvqO/tNQUx+l4i+lSz5u1Osngkx+vdOe0QLrv6c97k+rtkSSF6oybiqAX+i8PS/6IDoFPmfCtqKC4cPQWRAMXL03/2YiWs3KBZnT0XoVXNs/LdaG5hVCBtbMEREk3jjxnvH1lSWqodgA==
  • Arc-seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=XuSonDJZQXFhXWjslLy4Inca9JiP5tlxuLaf4ITJc2CsE90F2plMIuhEyU5FRfxH+YBCSezu6uDLHR0317qXhyVNmbVYPfP+cr+4VjjNMdZGrJXL18xp3aOb9GpgzdcoV5L4V0CGAX25jHzsR/fIa+AFjvFimuvbnjoRAtG8d0HdttK4IDkLJ1/l0PWoMbNePqI8zwbX5gkLohxGLNLdHTfKPCOGGU8Ti7Cb+zB/F0oLrxz9QHXPdRD2/amQ5RVUR9lxqFAvjMyUMBx0h7M+i9eKhea+xiRXnEIaPNznzcTxt6OVVHkHELtg9K+2vzq9Np3ECLLGpBfnbbATN81pRA==
  • Authentication-results: esa1.hc3370-68.iphmx.com; dkim=pass (signature verified) header.i=@citrix.onmicrosoft.com
  • Cc: Rahul Singh <rahul.singh@xxxxxxx>, <xen-devel@xxxxxxxxxxxxxxxxxxxx>, <bertrand.marquis@xxxxxxx>, Jan Beulich <jbeulich@xxxxxxxx>, Paul Durrant <paul@xxxxxxx>, Andrew Cooper <andrew.cooper3@xxxxxxxxxx>, George Dunlap <george.dunlap@xxxxxxxxxx>, Ian Jackson <iwj@xxxxxxxxxxxxxx>, Stefano Stabellini <sstabellini@xxxxxxxxxx>, Wei Liu <wl@xxxxxxx>, Daniel De Graaf <dgdegra@xxxxxxxxxxxxx>
  • Delivery-date: Tue, 06 Apr 2021 15:58:59 +0000
  • Ironport-hdrordr: A9a23:9z8zlK8FrOsevAYjj8puk+FocL1zdoIgy1knxilNYDRvWIixi9 2ukPMH1RX9lTYWXzUalcqdPbSbKEmyybdc2qNUGbu5RgHptC+TLI9k5Zb/2DGIIUHD38Zn/+ Nbf6B6YeecMXFTkdv67A6kE9wp3dmA9+SSif3Dymp2JDsKV4hLxW5Ce2GmO2dxQxRLAod8OZ qH/8xcpyehf3N/VLXAOlAuWe/fq9rX0K/8aRkdCBI9rCWIhzWk6Ln1eiLooys2eTVJ3Lsk7C z5gxX0j5/TyM2T5z398yvo75pQkMb80dcrPqKxo+UcNzmEsHfLWK1PQLuH1QpFxd2HyFFvq9 XUpgdlAsIb0QKsQkiQgT/Anzbtyywv7XiK8y7pvVLGrdbiTDw3T+pt7LgpCyfx0EYrsNFi3K 8j5Qvw3PA2fHCw7hjV3NTGWwpnkUC5uxMZ4JYupkdSTJcEb/tppZEflXklYasoJj7w64wsDY BVfafhzctRGGnqC0zxjy1ExdyhWWkLBRGWQkQOkdz96UkpoFlJi2Qf38ARhXEG6dYUTIRF/f 3NN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+Un8mv+ R+BAUtR/UGrCIjgo0x2jWzTaKygntNqSog3RhX0nj32oan52/HG1phKgOxuOQOYQVu
  • Ironport-sdr: fteQswJ78KTZ9QL94QN5Rzjc6lPFNlFgdXknH2zzYq7ACdzqlYXasp/p+BAE3zJXWZu83t7ZaB AfgEBe2i6UMi1GrBxJKjHXAKWS1N3hS78rQL5yB4Xj2nOEmJlziIqwddJz+BMt5EZOodsUNIWx rkx6IpuyzHyiQ1e3XXr5s+Ky5GFA+hVcRvOPGRdhHvWiY0Xi3xcldRv/bNNlWDOznH+AgVxcoQ YpQz3TNkOgN4wC90N8zYfaq69TSJtx7an92L91t+YlgI8BGykimZ8rHdSgtAr5SQN3QE+RwBmb yP0=
  • List-id: Xen developer discussion <xen-devel.lists.xenproject.org>

On Tue, Apr 06, 2021 at 04:09:34PM +0100, Julien Grall wrote:
> 
> 
> On 06/04/2021 15:59, Roger Pau Monné wrote:
> > On Tue, Apr 06, 2021 at 03:30:01PM +0100, Julien Grall wrote:
> > > So I think we want to be able to compile out the code if not used. That
> > > said, I think providing stub would be better to avoid multiple #ifdef in 
> > > the
> > > same function.
> > 
> > I think providing stubs is the way to go, that should allow to remove
> > the unneeded code without having to explicitly drop MSI support. As
> > said before, I think it's fine to provide those unimplemented for Arm
> > ATM, can be filled later if there's more pressing PCI work to do
> > first.
> 
> We should remove unneeded and *avoid* allocation. Providing stub for
> existing functions will only address the first problem.
> 
> For the allocation (see alloc_pdev()) , we will need to move it in separate
> function and gate them to prevent the allocation.
> 
> It would be wrong to gate the code with #ifdef CONFIG_X86. So I think
> Rahul's idea to provide the new #ifdef is correct.

I think all this needs to be in the commit message then, because from
my reading of the current message it seems like MSI code is only
removed because MSI support is not implemented on Arm, rather than Arm
not requiring such strict tracking of MSI accesses and MSI interrupt
setup. Likely the naming of the option needs to be adjusted also
together with the reduction of it's scope to stuff that explicitly
needs to be removed in the preprocessor opposed to adding arch
specific stubs.

Thanks, Roger.



 


Rackspace

Lists.xenproject.org is hosted with RackSpace, monitoring our
servers 24x7x365 and backed by RackSpace's Fanatical Support®.