qemu-devel.nongnu.org archive mirror
 help / color / mirror / Atom feed
From: Gerd Hoffmann <kraxel@redhat.com>
To: Alexey Korolev <alexey.korolev@endace.com>
Cc: sfd@endace.com, yamahata@valinux.co.jp, seabios@seabios.org,
	qemu-devel@nongnu.org, "Michael S. Tsirkin" <mst@redhat.com>
Subject: Re: [Qemu-devel] [BUG] [Seabios] PCI 64bit BARs on Win2008 - unable to start the device. (ACPI lacks the _DSM method)
Date: Thu, 15 Dec 2011 09:48:26 +0100	[thread overview]
Message-ID: <4EE9B45A.2050401@redhat.com> (raw)
In-Reply-To: <4EE8265F.2010703@endace.com>

On 12/14/11 05:30, Alexey Korolev wrote:
> Hi,
>>>
>>> It shouldn't be that hard to add the latter though.  seabios needs two
>>> more pci_region_type (PCI_REGION_TYPE_MEM_64 and
>>> PCI_REGION_TYPE_PREFMEM_64) to track and map 64bit bars separately.  And
>>> a address space window where it can map 64bit bars to.
>> Right. This is a thing I'm thinking about now. I seems that the
>> specifying 0x0 address in 64bit BARS is a bad idea. At least older
>> versions of Linux just hang as soon as requested range does not fit in
>> first 4GB.
>> So the only option would be specifying the particular address range.
>> It seems this works for everything - yet.
> I wonder if there any particular reason to separate prefetchable a
> non-prefetchable memory regions in pciinit? Extra two more regions would
> make code more complex.

Oh yes, there is.  Which reminds me that the whole thing isn't that easy
unfortunaly ...

The reason are pci bridges.  They have two memory regions, one for
prefetchable and one for non-prefetchable memory.  All devices behind a
pci bridge must have the bars within the bridges memory regions, thats
why they are grouped together.

This also implies that a 32bit and a 64bit bar (of the same type) behind
a pci bridge must be mapped next to each other, so moving up 64bit bars
unconditionally isn't going to fly.  Devices behind bridges need some
extra care, only when all bars are 64bit capable they can actually be
mapped above 4G.

cheers,
  Gerd

  parent reply	other threads:[~2011-12-15  8:49 UTC|newest]

Thread overview: 20+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2011-11-30  1:04 [Qemu-devel] [BUG] [Seabios] PCI 64bit BARs on Win2008 - unable to start the device. (ACPI lacks the _DSM method) Alexey Korolev
2011-11-30  7:49 ` Michael S. Tsirkin
2011-12-01  5:19   ` Alexey Korolev
2011-12-01 11:25     ` Gerd Hoffmann
2011-12-01 11:41       ` Gerd Hoffmann
2011-12-05  4:29         ` Alexey Korolev
2011-12-12  8:10           ` Gerd Hoffmann
2011-12-13  4:19             ` Alexey Korolev
2011-12-14  4:30               ` Alexey Korolev
2011-12-14  5:10                 ` Kevin O'Connor
2011-12-15  8:48                 ` Gerd Hoffmann [this message]
2011-12-16  4:41                   ` Alexey Korolev
2011-12-16  9:23                     ` Gerd Hoffmann
2011-12-01  5:49   ` Alexey Korolev
2011-12-01 10:17     ` Michael S. Tsirkin
2011-12-05  4:20       ` Alexey Korolev
2011-12-05  6:31         ` Michael S. Tsirkin
2011-12-06  4:23           ` Alexey Korolev
2011-12-13 11:11             ` [Qemu-devel] [SeaBIOS] " Gerd Hoffmann
2011-12-14  4:31               ` Alexey Korolev

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=4EE9B45A.2050401@redhat.com \
    --to=kraxel@redhat.com \
    --cc=alexey.korolev@endace.com \
    --cc=mst@redhat.com \
    --cc=qemu-devel@nongnu.org \
    --cc=seabios@seabios.org \
    --cc=sfd@endace.com \
    --cc=yamahata@valinux.co.jp \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).