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

Re: [PATCH v1 0/3] vPCI capabilities filtering


  • To: Stewart Hildebrand <stewart.hildebrand@xxxxxxx>, xen-devel@xxxxxxxxxxxxxxxxxxxx
  • From: Jan Beulich <jbeulich@xxxxxxxx>
  • Date: Mon, 14 Aug 2023 15:59:44 +0200
  • Arc-authentication-results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=suse.com; dmarc=pass action=none header.from=suse.com; dkim=pass header.d=suse.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-AntiSpam-MessageData-ChunkCount:X-MS-Exchange-AntiSpam-MessageData-0:X-MS-Exchange-AntiSpam-MessageData-1; bh=Q2arC9uBf7LBsN05ErzvbRb1QlLiqzJWuznii/OFnPs=; b=EF6O8huGjl1PUFbVJLxkOUH7o+E3yErpNhM0FnuTlReFBa4svF3tOxif+rMiDj3yhtk3TuL0BDE2iv9Fo8AdHmR86U5u7toa9euC/sZ8hWOxonk9qLPefavGTnm2x5E2KYk54nrFpeKBptm/AZajRlx9kT1tSZt9GFr2Ko9meabFeR1kv+EdH8cCGSBOOm8FR8kRDPZrCUC/DZHm/05gj1NKF2wPJMECa975WMWsLyVZ/MyWE2hZvzuaH1kTzjAz4XP8OZtkVnbHdwA4msZ73TpbTdPSTIeg9vTJQVITkpFqihuLmiOuStqu0saXb3h/wSDjQqvnNY1GjNNjM3vkJA==
  • Arc-seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=CTAo2mVr2SM7rQfB7CcNUqSMD9HDPVOst6y85GYhx91Y5aZDX31jmuJFbnwzkvgySskQR8/Lu2Bjfhck1j13nwcrLUlOE6OJZ+mr9xoh1p7hQUOq0WlsLN6CXT+kLxjT54FiREzAmDLvmfWGWgL+cv7LFIi6CiojQ2aJIx2XSr0Hjbq3KSOpm/MjEFVNYY+wDZPb3aCGgGAOzqggwiY/Gd39KkM9zNu6oTLop0twufTqSvz9Sc8E+zIMd2ZCDO1Jg5CVW8ToVg2L6d0SAIqEJSLiinojmKciy/Fw4/2i8C9cVPHREsajM5Fzu+jy0g2MCGRAlNPMM6IqZUCYI3Uflg==
  • Authentication-results: dkim=none (message not signed) header.d=none;dmarc=none action=none header.from=suse.com;
  • Cc: Roger Pau Monné <roger.pau@xxxxxxxxxx>
  • Delivery-date: Mon, 14 Aug 2023 14:00:05 +0000
  • List-id: Xen developer discussion <xen-devel.lists.xenproject.org>

On 10.08.2023 21:12, Stewart Hildebrand wrote:
> This small series enables vPCI to filter which PCI capabilites we expose to a
> domU. This series adds vPCI register handlers within
> xen/drivers/vpci/header.c:init_bars(), along with some supporting functions.
> 
> Note there are minor rebase conflicts with the in-progress vPCI series [1].
> These conflicts fall into the category of functions and code being added
> adjacent to one another, so are easily resolved. I did not identify any
> dependency on the vPCI locking work, and the two series deal with different
> aspects of emulating the PCI header.
> 
> Future work may involve adding handlers for more registers in the vPCI header,
> such as STATUS, VID/DID, etc.
> 
> [1] https://lists.xenproject.org/archives/html/xen-devel/2023-07/msg01281.html
> 
> Stewart Hildebrand (3):
>   xen/vpci: add vpci_hw_read8 helper
>   xen/vpci: add vpci_read_val helper
>   xen/vpci: header: filter PCI capabilities

I'm not convinced of the split here: Seeing the new helpers in isolation
leaves entirely open what they're to be used for. Plus besides introducing
dead code (even if only transiently), you also introduce cf_check marked
code which isn't really called indirectly from anywhere. Yet we'd like to
keep the amount of these markings down (in the final binary, not so much
in source code).

Jan



 


Rackspace

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