qemu-devel
[Top][All Lists]
Advanced

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

Re: [PATCH] pci-ids: sync docs + header


From: Peter Maydell
Subject: Re: [PATCH] pci-ids: sync docs + header
Date: Fri, 30 Sep 2022 10:29:38 +0100

On Fri, 30 Sept 2022 at 08:35, Gerd Hoffmann <kraxel@redhat.com> wrote:
>
> docs/specs/pci-ids.txt and include/hw/pci/pci.h are out of sync,
> fix that.  Try improve the comment which points to pci-ids.txt.
>
> Also drop the list of modern virtio devices and explain how they
> are calculated instead.
>
> Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>
> ---
>  docs/specs/pci-ids.txt | 19 ++++++++++---------
>  include/hw/pci/pci.h   |  7 ++++++-
>  2 files changed, 16 insertions(+), 10 deletions(-)
>
> diff --git a/docs/specs/pci-ids.txt b/docs/specs/pci-ids.txt
> index dd6859d039d0..6be7bc108d66 100644
> --- a/docs/specs/pci-ids.txt
> +++ b/docs/specs/pci-ids.txt
> @@ -22,16 +22,17 @@ maintained as part of the virtio specification.
>  1af4:1004  SCSI host bus adapter device (legacy)
>  1af4:1005  entropy generator device (legacy)
>  1af4:1009  9p filesystem device (legacy)
> +1af4:1012  vsock device (legacy)
> +1af4:1013  pmem device (legacy)
> +1af4:1014  iommu device (legacy)
> +1af4:1015  mem device (legacy)
>
> -1af4:1041  network device (modern)
> -1af4:1042  block device (modern)
> -1af4:1043  console device (modern)
> -1af4:1044  entropy generator device (modern)
> -1af4:1045  balloon device (modern)
> -1af4:1048  SCSI host bus adapter device (modern)
> -1af4:1049  9p filesystem device (modern)
> -1af4:1050  virtio gpu device (modern)
> -1af4:1052  virtio input device (modern)
> +1af4:1040  Start of id range for modern virtio devices.  The pci device
> +           id is is calculated from the virtio device id by adding the
> +           0x1040 offset.  The virtio ids are defined in the virtio
> +           specification.  The linux kernel has a header file with
> +           defines for all virtio ids (linux/virtio_ids.h), qemu has a
> +           copy in include/standard-headers/.

I think you should also specify the end point of this range, in the
same way that the "experimental usage" range has both a defined
start and end point. Otherwise we have no way to know how much
(if any) of the space before 10f0 is available for other uses.

Nits: capitalization: ID, PCI, Linux.

>  1af4:10f0  Available for experimental usage without registration.  Must get
>     to      official ID when the code leaves the test lab (i.e. when seeking

thanks
-- PMM



reply via email to

[Prev in Thread] Current Thread [Next in Thread]