[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [PATCH v4 06/11] vpci/header: handle p2m range sets per BAR
- To: Oleksandr Andrushchenko <Oleksandr_Andrushchenko@xxxxxxxx>
- From: Jan Beulich <jbeulich@xxxxxxxx>
- Date: Mon, 22 Nov 2021 09:24:32 +0100
- 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=NC9L90SsIa4Al+jIQi0Q07NsoSxvQ7lbRXvkNWuQXo8=; b=EV8/a0sv6/l9TcQarZ0gfRp9eGffkjPAf2O1pbKp5LwoSdXph79mmzTfBNMbsLV2cTpZwKEDqQhCSvJO8/RTH5uCd38BDSqjxdm51EVvscPhhoCb3M5G+JHF/dA/qqfy0TySzQO9QtkMP5+zsrFSWuOqm+8vyb+uZTDoQ220kHZNI3RcRy3l4WSUKWALSSJxVr7uHTJeDJBuYN+h3goGe8rD223BCirAqo9Rwmhjk/U85OIXr5hD/PzXneRPD9s1pKypDxBOlDC6nikIEmY6xpmH8XvvKJUBN4npxBQL268e0nOjgymk+X7objHXpadTTv1gNHeTUOjN4w1uyNAH5g==
- Arc-seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=hPF4YFU6oscSAcyzJFa1c7m8ESe4SDLlhoWOMAd//kc/ABPiiqjoQ27UHJoaN+Bi+efI8IrabBYp4fYZ1Zg9acp1kYTw8JG8fyZBKHqy0ndAkPR60AcI9boImsytxTM51/qprt0XseILFgDdKScCm7MIaChI7UyYO8XQFjBCx7hIxC0VGpllvG2PAqQHT8ujKOYDcGgzirsUS9YnwLRgjZZYQmV1Z5fB7tXut7Pk74sK+WNoMtKvn0e6BgKFiQ2stTphcMTvdwGSBn3Te1XVNnc8sZLyeoAoq+R7nqREqZwTKO1tjfnzyJphWPDNLpaunH7dcP+6aVLNOe3kctwWPw==
- Authentication-results: dkim=none (message not signed) header.d=none;dmarc=none action=none header.from=suse.com;
- Cc: "julien@xxxxxxx" <julien@xxxxxxx>, "sstabellini@xxxxxxxxxx" <sstabellini@xxxxxxxxxx>, Oleksandr Tyshchenko <Oleksandr_Tyshchenko@xxxxxxxx>, Volodymyr Babchuk <Volodymyr_Babchuk@xxxxxxxx>, Artem Mygaiev <Artem_Mygaiev@xxxxxxxx>, "roger.pau@xxxxxxxxxx" <roger.pau@xxxxxxxxxx>, "andrew.cooper3@xxxxxxxxxx" <andrew.cooper3@xxxxxxxxxx>, "george.dunlap@xxxxxxxxxx" <george.dunlap@xxxxxxxxxx>, "paul@xxxxxxx" <paul@xxxxxxx>, Bertrand Marquis <bertrand.marquis@xxxxxxx>, Rahul Singh <rahul.singh@xxxxxxx>, "xen-devel@xxxxxxxxxxxxxxxxxxxx" <xen-devel@xxxxxxxxxxxxxxxxxxxx>
- Delivery-date: Mon, 22 Nov 2021 08:24:49 +0000
- List-id: Xen developer discussion <xen-devel.lists.xenproject.org>
On 19.11.2021 15:09, Oleksandr Andrushchenko wrote:
> On 19.11.21 15:57, Jan Beulich wrote:
>> On 19.11.2021 14:41, Oleksandr Andrushchenko wrote:
>>> On 19.11.21 15:16, Jan Beulich wrote:
>>>> On 05.11.2021 07:56, Oleksandr Andrushchenko wrote:
>>>>> @@ -95,10 +102,25 @@ int vpci_add_handlers(struct pci_dev *pdev)
>>>>> INIT_LIST_HEAD(&pdev->vpci->handlers);
>>>>> spin_lock_init(&pdev->vpci->lock);
>>>>>
>>>>> + header = &pdev->vpci->header;
>>>>> + for ( i = 0; i < ARRAY_SIZE(header->bars); i++ )
>>>>> + {
>>>>> + struct vpci_bar *bar = &header->bars[i];
>>>>> +
>>>>> + bar->mem = rangeset_new(NULL, NULL, 0);
>>>> I don't recall why an anonymous range set was chosen back at the time
>>>> when vPCI was first implemented, but I think this needs to be changed
>>>> now that DomU-s get supported. Whether you do so right here or in a
>>>> prereq patch is secondary to me. It may be desirable to exclude them
>>>> from rangeset_domain_printk() (which would likely require a new
>>>> RANGESETF_* flag), but I think such resources should be associated
>>>> with their domains.
>>> What would be the proper name for such a range set then?
>>> "vpci_bar"?
>> E.g. bb:dd.f:BARn
> Hm, indeed
> I can only see a single flag RANGESETF_prettyprint_hex which tells
> *how* to print, but I can't see any limitation in *what* to print.
> So, do you mean I want some logic to be implemented in
> rangeset_domain_printk so it knows that this entry needs to be skipped
> while printing? RANGESETF_skip_print?
Yes, albeit I'd call the flag e.g. RANGESETF_no_print.
Jan
|