[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [PATCH v2] vpci: add permission checks to map_range()
- To: Roger Pau Monne <roger.pau@xxxxxxxxxx>
- From: Jan Beulich <jbeulich@xxxxxxxx>
- Date: Thu, 27 Jul 2023 09:56:08 +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=x6uRZHeEOxuz1S/2fBVUYkIpbMNhp6erjcMWGv5MTBU=; b=BgUpFzLtDCrBdoGzQDkTVds1GQco2c9PJCj3bxGpVKSsf+khs8LB0EeL31U3wBOzC5+VCQMXZhJj0Q+3Ays49G2u7KAgBICRijQuR8JGtZmQcglO819OokIxgfk8vy5JumSmpn+lUVOdPBGDY2cjsz2gVm7pgKtZjejstQucE0QzrRzm7jJAE5sE+z8Za4mbdTFvarHi2yicLNN8Fk4pnaBURcoav2jG9vFg6OTKiRp7CUoH1ndu8BkM0FmoEQ5eJty9lGTNS97urKU2qdNxpf2klk6E9aRMod38sCpFG4r4w84ewonkz/0HfVaNq5M5/vEDoYHj592tlQ1EJt7JCQ==
- Arc-seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=Dzg0D3pOwl0i/eYnwRJNXWuCFrv1CFsj5lwwrLYe8TtrcWmb2+jNVbKagjKVYRh21QBFhNK2JxDiMu6OmqsaD5U7Cx1F2XjLqvlUTX0hlP220Mu5rfJtgwlHQXrfbskmuRCYQIwWWfwReWdAjXYnlVd+2WbPNtfC3gnJMxmbhiopOB7aegaDS5ZCwt5yAXvvh1sQgmVm+MRvzKQOR/QvZ8zeupjNYGk+q0/juW0G4xJgE+qGFqQdghHTv3ty1EzDHJYSAlKrW1aWH2SkPqK17j9M3n7PB8IguYO2H2TcuvRaf/neqzDG/syJPxGgVITa9HA35/VR2B7SOAOZPoWhNw==
- Authentication-results: dkim=none (message not signed) header.d=none;dmarc=none action=none header.from=suse.com;
- Cc: Andrew Cooper <andrew.cooper3@xxxxxxxxxx>, Wei Liu <wl@xxxxxxx>, xen-devel@xxxxxxxxxxxxxxxxxxxx, "Daniel P. Smith" <dpsmith@xxxxxxxxxxxxxxxxxxxx>
- Delivery-date: Thu, 27 Jul 2023 07:56:16 +0000
- List-id: Xen developer discussion <xen-devel.lists.xenproject.org>
On 26.07.2023 16:01, Roger Pau Monne wrote:
> Just like it's done for the XEN_DOMCTL_memory_mapping hypercall, add
> the permissions checks to vPCI map_range(), which is used to map the
> BARs into the domain p2m.
>
> Adding those checks requires that for x86 PVH hardware domain builder
> the permissions are set before initializing the IOMMU, or else
> attempts to initialize vPCI done as part of IOMMU device setup will
> fail due to missing permissions to create the BAR mappings.
>
> While moving the call to dom0_setup_permissions() convert the panic()
> used for error handling to a printk, the caller will already panic if
> required.
>
> Fixes: 9c244fdef7e7 ('vpci: add header handlers')
> Signed-off-by: Roger Pau Monné <roger.pau@xxxxxxxxxx>
I've committed this, but despite the Fixes: tag I'm not sure this
wants backporting. Thoughts?
Jan
|