[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [PATCH v3 01/11] vpci: Make vpci registers removal a dedicated function
- To: Oleksandr Andrushchenko <Oleksandr_Andrushchenko@xxxxxxxx>
- From: Roger Pau Monné <roger.pau@xxxxxxxxxx>
- Date: Wed, 27 Oct 2021 11:24:44 +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-AntiSpam-MessageData-ChunkCount:X-MS-Exchange-AntiSpam-MessageData-0:X-MS-Exchange-AntiSpam-MessageData-1; bh=De6mRbBeaXJ5hE46PFVc15Mw24RA1tA2s9Bo9yHTTdo=; b=UgF5fuxfbt3B2qV2Nh40J+gDjBCeXQOQUOXo8dKbN88izl/4k0DZUg2SgTJaYXrHXXv8tN+NyWzL9558qa77a1lB9YdgYgMApAyWFQPd+e/r0ukMxQcVks5b/OxWVj8Xnojejum6jxfZTUn6tZLBbTWa+MpxEheEYZRZZ9zZBW8gjDzVDAqhbL3g1JZSQc5m/lV1V9gJ265VHTF4Q+IltxkYjedoTd02PK68ASW3RI7XoQ3J9LbAmOSSWkXB2gS/Xngpd31wacgI2+LZXAGd+zpTBSG8sMIN/HH5UAlceCA1N4y5OYOQpif4pLpy7dlO5CRLbwzWLPEM30Ab5SDkhA==
- Arc-seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=DAU1XJhJ11R8Oh1gTfhUGqgSkZQf+IyBIxpiZQWwECuKgiaIM7DyNCUDPktg+2aX8DYkzdhQYlRiFGk4kjRhQTzTNdOGgS1D85jBaw6/yrv8auPnIXsLN523680SBA3TmXitC5A4ws3Q1A7jyie5TcrqZOJ2N6Qk9PgTQdRjopj9YOBZQfdbayzG3lWpKF0lAL5Jz5f3G7mbjzOHWX2RC0DulUjxkewVODsFjcG2zLWhkhw5Hbp+fY2KHB2K/QOCeO8gXrqs4luI3cN9GVhbw1lfFF1DZ8HXISbwmKk0T9f8EToeYxteIssn/JMSqOwHPFQLc9RB7rpufqMka+GJpg==
- Authentication-results: esa3.hc3370-68.iphmx.com; dkim=pass (signature verified) header.i=@citrix.onmicrosoft.com
- Cc: "xen-devel@xxxxxxxxxxxxxxxxxxxx" <xen-devel@xxxxxxxxxxxxxxxxxxxx>, "julien@xxxxxxx" <julien@xxxxxxx>, "sstabellini@xxxxxxxxxx" <sstabellini@xxxxxxxxxx>, Oleksandr Tyshchenko <Oleksandr_Tyshchenko@xxxxxxxx>, Volodymyr Babchuk <Volodymyr_Babchuk@xxxxxxxx>, Artem Mygaiev <Artem_Mygaiev@xxxxxxxx>, "jbeulich@xxxxxxxx" <jbeulich@xxxxxxxx>, Bertrand Marquis <bertrand.marquis@xxxxxxx>, Rahul Singh <rahul.singh@xxxxxxx>, Michal Orzel <michal.orzel@xxxxxxx>
- Delivery-date: Wed, 27 Oct 2021 09:25:08 +0000
- Ironport-data: A9a23:GfDF56s8Cik9ZVIGFIej1steCOfnVGZYMUV32f8akzHdYApBsoF/q tZmKWzQP/uNZTGgKIwkPNjn9UsGuMDSnNBmHgdvqHthEHgU+JbJXdiXEBz9bniYRiHhoOOLz Cm8hv3odp1coqr0/0/1WlTZQP0VOZigHtIQMsadUsxKbVIiGHhJZS5LwbZj29cw24fhWmthh PupyyHhEA79s9JLGjp8B5Kr8HuDa9yr5Vv0FnRnDRx6lAe2e0s9VfrzFonoR5fMeaFGH/bSe gr25OrRElU1XfsaIojNfr7TKiXmS1NJVOSEoiI+t6OK2nCuqsGuu0qS2TV1hUp/0l20c95NJ Nplp7zsSAEXYaL2qcscTSUICX1FAZVZ0eqSSZS/mZT7I0zudnLtx7NlDV0sPJ1e8eFyaY1M3 aVGcnZXNEnF3r/ohuLgIgVvrp1LwM3DJoQQt2s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raZyPUZujjO9vBpck/00zB6oeicWkJIMhjS1CEEdOlpMJkoy PsKsdIN71DtkQIjN9uL13gG92mFInEafb8gs5UWXN3ihgYxkwkQap3AEC7mppqIbowUYEUtJ zaVgovEhqhdmRWeIyZiSyCV0LME15oUuR1MwFsTHHizm4LI1q0twRlc0TUrVQAJnB9J5P1+Z zpwPEpvKKTQozox3JpfX3qhEh1qDQGC/hCj0EMAkWDUQhX6VmHJK2Fha++B8FpArjBZdzlfu rqZ1HzkQXDhe8Sohnk+XktsqvrCS91t91KdxJD7TprdR5RqMyD4hqKOZHYTr0q1CMw8s0TLu O128bsicqb8LyMR//U2BoTyOW78k/xYyLiumc1cwZ4=
- Ironport-hdrordr: A9a23:F2Btlqt+uAgRkOFdwrfsGy+O7skDjNV00zEX/kB9WHVpm6yj+v xGUs566faUskd0ZJhEo7q90ca7Lk80maQa3WBzB8bGYOCFghrKEGgK1+KLrwEIcxeUygc379 YDT0ERMrzN5VgRt7eG3OG7eexQvOVuJsqT9JjjJ3QGd3AVV0l5hT0JbTpyiidNNXJ77ZxSLu v72uN34wCOVF4wdcqBCnwMT4H41qf2fMKPW29+O/Y/gjP+9Q+V1A==
- Ironport-sdr: jajpmi9XpV3kCblhCV/013KNh/NqOsrKsXCTYhNX1lvBJaxw/F/MJPZ12JoPvz2/J+2VISKQcJ QEkEemXCXdaReCQ4wmdJs+Zs9atIZYvzKF+EQQVZkOB70Y5mQ5DRY7R/5rTYMoWovd+02sL+3Z IZUhC06PsAaPPUSpDs+CqxJP6ge5Q1ndJNbo0UPVwmLAhy1QZRPyuOw2eEDktoUn21sUbyv6E3 nqE28o5ZwX0brwkdqLBjVmn59gBqO7QxzKpWUNj7FvlDutwUbn/C7ydjb7Z3h4/tRS4A7w7LD4 H/SiQoOJDXTNgsk+X9It31HX
- List-id: Xen developer discussion <xen-devel.lists.xenproject.org>
On Wed, Oct 27, 2021 at 09:12:14AM +0000, Oleksandr Andrushchenko wrote:
> Hi, Roger!
>
> On 13.10.21 14:11, Roger Pau Monné wrote:
> > On Thu, Sep 30, 2021 at 10:52:13AM +0300, Oleksandr Andrushchenko wrote:
> >> From: Oleksandr Andrushchenko <oleksandr_andrushchenko@xxxxxxxx>
> >>
> >> This is in preparation for dynamic assignment of the vpci register
> >> handlers depending on the domain: hwdom or guest.
> >>
> >> Signed-off-by: Oleksandr Andrushchenko <oleksandr_andrushchenko@xxxxxxxx>
> >> Reviewed-by: Michal Orzel <michal.orzel@xxxxxxx>
> >> ---
> >> Since v1:
> >> - constify struct pci_dev where possible
> >> ---
> >> xen/drivers/vpci/vpci.c | 7 ++++++-
> >> xen/include/xen/vpci.h | 2 ++
> >> 2 files changed, 8 insertions(+), 1 deletion(-)
> >>
> >> diff --git a/xen/drivers/vpci/vpci.c b/xen/drivers/vpci/vpci.c
> >> index cbd1bac7fc33..1666402d55b8 100644
> >> --- a/xen/drivers/vpci/vpci.c
> >> +++ b/xen/drivers/vpci/vpci.c
> >> @@ -35,7 +35,7 @@ extern vpci_register_init_t *const __start_vpci_array[];
> >> extern vpci_register_init_t *const __end_vpci_array[];
> >> #define NUM_VPCI_INIT (__end_vpci_array - __start_vpci_array)
> >>
> >> -void vpci_remove_device(struct pci_dev *pdev)
> >> +void vpci_remove_device_registers(const struct pci_dev *pdev)
> > Making this const is kind of misleading, as you end up modifying
> > contents of the pdev, is just that vpci data is stored as a pointer
> > inside the struct so you avoid the effects of the constification.
> Ok, I will remove const
Jan prefers the const, so please leave it.
Thanks, Roger.
|