Re: virtio capabilities

2019-12-17 Thread Michael S. Tsirkin
On Wed, Dec 18, 2019 at 04:19:57PM +1100, Alexey Kardashevskiy wrote: > > > On 13/12/2019 19:36, Michael S. Tsirkin wrote: > > On Fri, Dec 13, 2019 at 07:29:40PM +1100, Alexey Kardashevskiy wrote: > >> > >> > >> On 13/12/2019 18:24, Michael S. Tsirkin wrote: > >>> On Fri, Dec 13, 2019 at 05:05:05

Re: virtio capabilities

2019-12-17 Thread Alexey Kardashevskiy
On 13/12/2019 19:36, Michael S. Tsirkin wrote: > On Fri, Dec 13, 2019 at 07:29:40PM +1100, Alexey Kardashevskiy wrote: >> >> >> On 13/12/2019 18:24, Michael S. Tsirkin wrote: >>> On Fri, Dec 13, 2019 at 05:05:05PM +1100, Alexey Kardashevskiy wrote: Hi! I am having an issue with ca

Re: virtio capabilities

2019-12-13 Thread Michael S. Tsirkin
On Fri, Dec 13, 2019 at 07:29:40PM +1100, Alexey Kardashevskiy wrote: > > > On 13/12/2019 18:24, Michael S. Tsirkin wrote: > > On Fri, Dec 13, 2019 at 05:05:05PM +1100, Alexey Kardashevskiy wrote: > >> Hi! > >> > >> I am having an issue with capabilities (hopefully the chunk formatting > >> won't

Re: virtio capabilities

2019-12-13 Thread Alexey Kardashevskiy
On 13/12/2019 18:24, Michael S. Tsirkin wrote: > On Fri, Dec 13, 2019 at 05:05:05PM +1100, Alexey Kardashevskiy wrote: >> Hi! >> >> I am having an issue with capabilities (hopefully the chunk formatting >> won't break). >> >> The problem is that when virtio_pci_find_capability() reads >> pci_fin

Re: virtio capabilities

2019-12-12 Thread Michael S. Tsirkin
On Fri, Dec 13, 2019 at 05:05:05PM +1100, Alexey Kardashevskiy wrote: > Hi! > > I am having an issue with capabilities (hopefully the chunk formatting > won't break). > > The problem is that when virtio_pci_find_capability() reads > pci_find_capability(dev, PCI_CAP_ID_VNDR), 0 is returned; if rep

virtio capabilities

2019-12-12 Thread Alexey Kardashevskiy
Hi! I am having an issue with capabilities (hopefully the chunk formatting won't break). The problem is that when virtio_pci_find_capability() reads pci_find_capability(dev, PCI_CAP_ID_VNDR), 0 is returned; if repeated, it returns a valid number (0x84). Timing seems to matter. pci_cfg_read trace

[Qemu-devel] [PATCH v3 07/25] virtio: find version 1.0 virtio capabilities

2015-07-01 Thread Gerd Hoffmann
virtio 1.0 specifies the location of the various virtio regions using pci capabilities. Look them up and store the results. Signed-off-by: Gerd Hoffmann --- src/hw/virtio-pci.c | 56 + src/hw/virtio-pci.h | 8 2 files changed, 64 ins

Re: [Qemu-devel] [PATCH v2 07/22] virtio: find version 1.0 virtio capabilities

2015-07-01 Thread Michael S. Tsirkin
On Wed, Jul 01, 2015 at 02:49:54PM +0200, Gerd Hoffmann wrote: > Hi, > > > > > > > Yes, seabios always allocates both mem and io. > > > > What if it can't? E.g. too many devices. > > First tries to move 64bit bars above 64g. Guess we better should > exclude virtio devices here (like we do fo

Re: [Qemu-devel] [PATCH v2 07/22] virtio: find version 1.0 virtio capabilities

2015-07-01 Thread Gerd Hoffmann
Hi, > > > > Yes, seabios always allocates both mem and io. > > What if it can't? E.g. too many devices. First tries to move 64bit bars above 64g. Guess we better should exclude virtio devices here (like we do for xhci already). Failing that it'll panic. cheers, Gerd

Re: [Qemu-devel] [PATCH v2 07/22] virtio: find version 1.0 virtio capabilities

2015-07-01 Thread Michael S. Tsirkin
On Wed, Jul 01, 2015 at 02:24:02PM +0200, Gerd Hoffmann wrote: > Hi, > > > Hmm this seems to violate this rule in the spec: > > > > > > The driver SHOULD use the first instance of each virtio structure type > > they can support. > > > > "can support" here means that bios was able to a

Re: [Qemu-devel] [PATCH v2 07/22] virtio: find version 1.0 virtio capabilities

2015-07-01 Thread Gerd Hoffmann
Hi, > Hmm this seems to violate this rule in the spec: > > > The driver SHOULD use the first instance of each virtio structure type > they can support. > > "can support" here means that bios was able to allocate > it during enumeration. > > For example there could be both IO and

Re: [Qemu-devel] [PATCH v2 07/22] virtio: find version 1.0 virtio capabilities

2015-07-01 Thread Michael S. Tsirkin
On Tue, Jun 30, 2015 at 10:38:58AM +0200, Gerd Hoffmann wrote: > virtio 1.0 specifies the location of the various virtio regions > using pci capabilities. Look them up and store the results. > > Signed-off-by: Gerd Hoffmann > --- > src/hw/virtio-pci.c | 55 > +++

[Qemu-devel] [PATCH v2 07/22] virtio: find version 1.0 virtio capabilities

2015-06-30 Thread Gerd Hoffmann
virtio 1.0 specifies the location of the various virtio regions using pci capabilities. Look them up and store the results. Signed-off-by: Gerd Hoffmann --- src/hw/virtio-pci.c | 55 + src/hw/virtio-pci.h | 8 2 files changed, 63 ins

[Qemu-devel] [PATCH 06/18] virtio: find version 1.0 virtio capabilities

2015-06-29 Thread Gerd Hoffmann
virtio 1.0 specifies the location of the various virtio regions using pci capabilities. Look them up and store the results. Signed-off-by: Gerd Hoffmann --- src/hw/virtio-pci.c | 55 + src/hw/virtio-pci.h | 8 2 files changed, 63 ins