From: "Gerd Hoffmann" <kraxel@redhat.com>
To: Laszlo Ersek <lersek@redhat.com>
Cc: devel@edk2.groups.io, Jiewen Yao <jiewen.yao@intel.com>,
Oliver Steffen <osteffen@redhat.com>,
Ard Biesheuvel <ardb+tianocore@kernel.org>
Subject: Re: [edk2-devel] [PATCH v2 3/4] OvmfPkg/PlatformPei: rewrite page table calculation
Date: Wed, 14 Feb 2024 12:07:20 +0100 [thread overview]
Message-ID: <mdbcxb2rwxwv4yymvrqypkiten6rcg7b4vwyw3dnfggpy3tz7a@ipqu4prvhkrl> (raw)
In-Reply-To: <d0133d88-a312-999f-4d13-3c2f09b8b2cf@redhat.com>
On Wed, Feb 14, 2024 at 11:48:57AM +0100, Laszlo Ersek wrote:
> On 2/14/24 10:32, Gerd Hoffmann wrote:
> > Hi,
> >
> >> (3) I'm slightly disturbed by the fact that here we don't shift the
> >> original MaxAddr by 48 bits, but Level3Pages by 9 bits. Namely, if
> >> Level3Pages was set to 1 by the MAX (i.e., because the >> 39 resulted
> >> in zero), then the input of *this* bit shift is nonsensical. It's a
> >> happenstance that 1 >> 9 is zero too, for Level4Pages, and we're just
> >> exploiting that practical result here.
> >
> > I had it that way initially. Got failures for 32-bit builds in CI,
> > because the compiler used 64-bit math intrinsics somewhere.
>
> Right, I had certainly expected that in advance. You must have missed my
> earlier update on that, still in the v1 thread. My original proposal
> there was indeed problematic in that sense, but a few minutes later I
> posted an update, replacing the bit-shifts inside the MAX() macro
> invocations with RShiftU64() calls:
Happened even with the RShiftU64() calls, must have been something else.
take care,
Gerd
-=-=-=-=-=-=-=-=-=-=-=-
Groups.io Links: You receive all messages sent to this group.
View/Reply Online (#115443): https://edk2.groups.io/g/devel/message/115443
Mute This Topic: https://groups.io/mt/104117101/7686176
Group Owner: devel+owner@edk2.groups.io
Unsubscribe: https://edk2.groups.io/g/devel/unsub [rebecca@openfw.io]
-=-=-=-=-=-=-=-=-=-=-=-
next prev parent reply other threads:[~2024-02-14 11:07 UTC|newest]
Thread overview: 14+ messages / expand[flat|nested] mbox.gz Atom feed top
2024-02-02 10:47 [edk2-devel] [PATCH v2 0/4] OvmfPkg/PlatformPei: scaleability fixes for GetPeiMemoryCap() Gerd Hoffmann
2024-02-02 10:47 ` [edk2-devel] [PATCH v2 1/4] OvmfPkg/PlatformPei: log a warning when memory is tight Gerd Hoffmann
2024-02-05 7:45 ` Laszlo Ersek
2024-02-02 10:47 ` [edk2-devel] [PATCH v2 2/4] OvmfPkg/PlatformPei: consider AP stacks for pei memory cap Gerd Hoffmann
2024-02-05 7:57 ` Laszlo Ersek
2024-02-02 10:47 ` [edk2-devel] [PATCH v2 3/4] OvmfPkg/PlatformPei: rewrite page table calculation Gerd Hoffmann
2024-02-05 8:14 ` Laszlo Ersek
2024-02-05 8:19 ` Laszlo Ersek
2024-02-14 9:32 ` Gerd Hoffmann
2024-02-14 10:48 ` Laszlo Ersek
2024-02-14 11:07 ` Gerd Hoffmann [this message]
2024-02-14 11:58 ` Laszlo Ersek
2024-02-02 10:47 ` [edk2-devel] [PATCH v2 4/4] OvmfPkg/PlatformPei: log pei memory cap details Gerd Hoffmann
2024-02-05 8:27 ` Laszlo Ersek
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=mdbcxb2rwxwv4yymvrqypkiten6rcg7b4vwyw3dnfggpy3tz7a@ipqu4prvhkrl \
--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