From: dann frazier <dann.frazier@canonical.com>
To: Laszlo Ersek <lersek@redhat.com>
Cc: edk2-devel-01 <edk2-devel@lists.01.org>,
Aleksei Kovura <alex3kov@zoho.com>,
Ard Biesheuvel <ard.biesheuvel@linaro.org>,
Dann Frazier <dannf@ubuntu.com>, Eric Dong <eric.dong@intel.com>,
Star Zeng <star.zeng@intel.com>
Subject: Re: [PATCH] MdeModulePkg/AtaAtapiPassThru: disable only BM-DMA at ExitBootServices()
Date: Thu, 26 Oct 2017 13:56:03 -0600 [thread overview]
Message-ID: <CALdTtntz15NjHBHUf=DKiAQ2d+JZTbocYLfCb-QXXkXcSCVy4g@mail.gmail.com> (raw)
In-Reply-To: <20171026154819.20865-1-lersek@redhat.com>
On Thu, Oct 26, 2017 at 9:48 AM, Laszlo Ersek <lersek@redhat.com> wrote:
> Clearing I/O port decoding in the PCI command register at
> ExitBootServices() breaks IDE boot in Windows, on QEMU's "pc" (i440fx)
> machine type. (AHCI boot on "q35" is unaffected.) Windows seems repeatedly
> stuck, apparently waiting for a timeout of sorts.
>
> This is arguably a Windows bug; a native OS driver should not expect the
> firmware to leave the PCI command register in any particular state.
>
> Strictly speaking, we only need to disable BM-DMA at ExitBootServices(),
> in order to abort pending transfers to/from RAM, which is soon to be owned
> by the OS. BM-DMA is also the only bit that's explicitly named by the UEFI
> Driver Writers' Guide, for clearing at ExitBootServices().
>
> I've verified that clearing only BM-DMA fixes the isse (boot time) on
> i440fx, and does not regress q35/AHCI.
Worked for my test case (booting a Win10 install ISO in ~30s). Thanks Laszlo!
Tested-by: dann frazier <dann.frazier@canonical.com>
next prev parent reply other threads:[~2017-10-26 19:52 UTC|newest]
Thread overview: 19+ messages / expand[flat|nested] mbox.gz Atom feed top
2017-10-26 15:48 [PATCH] MdeModulePkg/AtaAtapiPassThru: disable only BM-DMA at ExitBootServices() Laszlo Ersek
2017-10-26 19:56 ` dann frazier [this message]
2017-10-27 3:23 ` Zeng, Star
2017-10-27 12:25 ` Laszlo Ersek
2017-10-27 14:57 ` Aleksei
2017-10-27 16:09 ` Laszlo Ersek
2017-11-22 10:05 ` Ni, Ruiyu
2017-11-22 10:26 ` Zeng, Star
2017-11-23 2:20 ` Ni, Ruiyu
2017-11-23 13:08 ` Laszlo Ersek
2017-11-23 14:58 ` Ni, Ruiyu
2017-11-23 17:19 ` Laszlo Ersek
2017-11-23 23:06 ` Ni, Ruiyu
2017-11-24 0:01 ` Paolo Bonzini
2017-11-24 1:04 ` Ni, Ruiyu
2017-11-24 1:40 ` Yao, Jiewen
2017-11-27 12:29 ` Laszlo Ersek
2017-11-27 12:58 ` Zeng, Star
2017-11-27 13:41 ` Yao, Jiewen
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-list 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='CALdTtntz15NjHBHUf=DKiAQ2d+JZTbocYLfCb-QXXkXcSCVy4g@mail.gmail.com' \
--to=devel@edk2.groups.io \
/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