public inbox for devel@edk2.groups.io
 help / color / mirror / Atom feed
From: "Marvin Häuser" <Marvin.Haeuser@outlook.com>
To: "edk2-devel@lists.01.org" <edk2-devel@lists.01.org>
Cc: Laszlo Ersek <lersek@redhat.com>
Subject: Re: PciLib/PciExpressLib: 64-bit r/w functions
Date: Sun, 6 Aug 2017 12:46:46 +0000	[thread overview]
Message-ID: <AM4PR06MB14912ED501461A604EDCBF7880B40@AM4PR06MB1491.eurprd06.prod.outlook.com> (raw)
In-Reply-To: <f6db0e77-2e46-6fb3-c623-704c83c4f71c@redhat.com>

Thank you for your reply!

Sorry, I was only thinking of MMIO access when I wrote the mail, should have limited it to PciExpressLib.
I did not hear of any platform supporting MMIO but not 64-bit register r/w, will research that.

Regards,
Marvin.

> -----Original Message-----
> From: Laszlo Ersek [mailto:lersek@redhat.com]
> Sent: Sunday, August 6, 2017 1:35 PM
> To: Marvin Häuser <Marvin.Haeuser@outlook.com>
> Cc: edk2-devel@lists.01.org
> Subject: Re: [edk2] PciLib/PciExpressLib: 64-bit r/w functions
> 
> On 08/05/17 23:38, Marvin H?user wrote:
> > Dear developers,
> >
> > While browsing the KabylakeSiPkg code, I noticed that 64-bit registers are
> read directly via MmioRead64() as there is no PciRead64() function.
> > Is there a specific reason there are no PciRead64() and PciExpressRead64()
> functions or were they simply not needed previously?
> 
> Validity of 64-bit accesses to PCI config space is platform dependent [*] and I
> guess the PciLib designers didn't want to deviate from the common interface
> pattern that PciReadXX() always succeeds (as long as the input parameter is
> valid), regardless of XX.
> 
> [*] The UEFI spec repeats the following paragraph in several places:
> 
>     The I/O operations are carried out exactly as requested. The caller
>     is responsible satisfying any alignment and I/O width restrictions
>     that the PCI controller on a platform might require. For example on
>     some platforms, width requests of EfiPciIoWidthUint64 do not work.
> 
> Thanks
> Laszlo

      reply	other threads:[~2017-08-06 12:44 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2017-08-05 21:38 PciLib/PciExpressLib: 64-bit r/w functions Marvin H?user
2017-08-06 11:34 ` Laszlo Ersek
2017-08-06 12:46   ` Marvin Häuser [this message]

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=AM4PR06MB14912ED501461A604EDCBF7880B40@AM4PR06MB1491.eurprd06.prod.outlook.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