public inbox for devel@edk2.groups.io
 help / color / mirror / Atom feed
From: "Gerd Hoffmann" <kraxel@redhat.com>
To: devel@edk2.groups.io
Cc: min.m.xu@intel.com
Subject: CcProbeLib not working for runtime calls
Date: Wed, 17 Aug 2022 13:04:57 +0200	[thread overview]
Message-ID: <20220817110457.2gvr4yxoxlve5ncz@sirius.home.kraxel.org> (raw)

  Hi,

https://bugzilla.redhat.com/show_bug.cgi?id=2114858

I think the call chain is:

-> linux does efi runtime call
  -> some debug message printed
    -> OvmfPkg/Library/PlatformDebugLibIoPort/DebugLib.c
      -> MdePkg/Library/BaseIoLibIntrinsic (IoWriteFifo8)
        -> OvmfPkg/Library/CcProbeLib (CcProbe)
          -> page fault when trying to access WorkArea

Hmm.

We could probably reserve the workarea page and register it for a
runtime mapping etc.  I suspect that'll only crash the in simliar ways a
little later because the tdx/sev code is not prepared to work on runtime
calls.  I'm also not sure this is possible to make work at all given
that #vc/#ve faults are handled by the linux kernel not ovmf at this
point.

So have CcProbe just return CcGuestTypeNonEncrypted when called at
runtime, hoping that the linux kernel handles #vc / #ve faults properly
should they occur?

take care,
  Gerd


             reply	other threads:[~2022-08-17 11:05 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-08-17 11:04 Gerd Hoffmann [this message]
2022-08-18  1:47 ` [edk2-devel] CcProbeLib not working for runtime calls Min Xu
2022-08-18  4:58   ` Gerd Hoffmann
2022-08-19  3:39     ` Min Xu

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=20220817110457.2gvr4yxoxlve5ncz@sirius.home.kraxel.org \
    --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