public inbox for devel@edk2.groups.io
 help / color / mirror / Atom feed
From: Ard Biesheuvel <ard.biesheuvel@linaro.org>
To: Leif Lindholm <leif.lindholm@linaro.org>
Cc: edk2-devel-01 <edk2-devel@lists.01.org>
Subject: Re: [PATCH 1/5] EmbeddedPkg: introduce platform PCI I/O protocol
Date: Wed, 2 Nov 2016 13:29:06 +0000	[thread overview]
Message-ID: <CAKv+Gu_YPgGZbarfTJO0AYUGLeMz-=FUHQQ5J_UFV06X=ctxhQ@mail.gmail.com> (raw)
In-Reply-To: <20161101215422.GM1161@bivouac.eciton.net>

On 1 November 2016 at 21:54, Leif Lindholm <leif.lindholm@linaro.org> wrote:
> On Mon, Oct 31, 2016 at 06:13:06PM +0000, Ard Biesheuvel wrote:
>> Introduce a protocol that can be exposed by a platform for devices that
>> can be driven by a PCI driver, (e.g., AHCI, XHCI), but do not live on a
>> PCI bus. This used to be called 'PCI emulation' but given that we only
>> emulate the PCI config space and nothing else, it tends to be a bit
>> confusing so this introduces the term 'platform PCI I/O' instead.
>>
>> Contributed-under: TianoCore Contribution Agreement 1.0
>> Signed-off-by: Ard Biesheuvel <ard.biesheuvel@linaro.org>
>> ---
>>  EmbeddedPkg/EmbeddedPkg.dec                  |  1 +
>>  EmbeddedPkg/Include/Protocol/PlatformPciIo.h | 74 ++++++++++++++++++++
>
> OK, so perhaps I should have commented on this already on 0/5, but I
> think this belongs in MdeModulePkg. The closest thing to an "embedded"
> user of this code is Juno.
>
>>  2 files changed, 75 insertions(+)
>>
>> diff --git a/EmbeddedPkg/EmbeddedPkg.dec b/EmbeddedPkg/EmbeddedPkg.dec
>> index 2c2cf41103c2..84a6f4d01077 100644
>> --- a/EmbeddedPkg/EmbeddedPkg.dec
>> +++ b/EmbeddedPkg/EmbeddedPkg.dec
>> @@ -69,6 +69,7 @@ [Protocols.common]
>>    gAndroidFastbootPlatformProtocolGuid =  { 0x524685a0, 0x89a0, 0x11e3, {0x9d, 0x4d, 0xbf, 0xa9, 0xf6, 0xa4, 0x03, 0x08}}
>>    gUsbDeviceProtocolGuid =  { 0x021bd2ca, 0x51d2, 0x11e3, {0x8e, 0x56, 0xb7, 0x54, 0x17, 0xc7,  0x0b, 0x44 }}
>>    gPlatformGpioProtocolGuid = { 0x52ce9845, 0x5af4, 0x43e2, {0xba, 0xfd, 0x23, 0x08, 0x12, 0x54, 0x7a, 0xc2 }}
>> +  gPlatformPciIoProtocolGuid = { 0x0d51905b, 0xb77e, 0x452a, {0xa2, 0xc0, 0xec, 0xa0, 0xcc, 0x8d, 0x51, 0x4a }}
>>
>>  [PcdsFeatureFlag.common]
>>    gEmbeddedTokenSpaceGuid.PcdEmbeddedMacBoot|FALSE|BOOLEAN|0x00000001
>> diff --git a/EmbeddedPkg/Include/Protocol/PlatformPciIo.h b/EmbeddedPkg/Include/Protocol/PlatformPciIo.h
>> new file mode 100644
>> index 000000000000..a7bd584049ac
>> --- /dev/null
>> +++ b/EmbeddedPkg/Include/Protocol/PlatformPciIo.h
>> @@ -0,0 +1,74 @@
>> +/** @file
>> +
>> +  Copyright (c) 2016, Linaro, Ltd. All rights reserved.<BR>
>> +
>> +  This program and the accompanying materials
>> +  are licensed and made available under the terms and conditions of the BSD License
>> +  which accompanies this distribution.  The full text of the license may be found at
>> +  http://opensource.org/licenses/bsd-license.php
>> +
>> +  THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
>> +  WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
>> +
>> +**/
>> +
>> +#ifndef __PLATFORM_PCI_IO_H__
>> +#define __PLATFORM_PCI_IO_H__
>> +
>> +#define PLATFORM_PCI_IO_PROTOCOL_GUID \
>> +  { 0x0d51905b, 0xb77e, 0x452a, {0xa2, 0xc0, 0xec, 0xa0, 0xcc, 0x8d, 0x51, 0x4a } }
>> +
>> +//
>> +// Protocol interface structure
>> +//
>> +typedef struct _PLATFORM_PCI_IO PLATFORM_PCI_IO;
>> +
>> +//
>> +// Data Types
>> +//
>> +typedef enum {
>> +  PlatformPciIoDeviceOhci,
>> +  PlatformPciIoDeviceUhci,
>> +  PlatformPciIoDeviceEhci,
>> +  PlatformPciIoDeviceXhci,
>> +  PlatformPciIoDeviceAhci,
>
> SdMmc and Ufs?
>

Indeed. I have added both: SDHCI works in QEMU but I can't really test UFS.


  reply	other threads:[~2016-11-02 13:29 UTC|newest]

Thread overview: 26+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2016-10-31 18:13 [PATCH 0/5] EmbeddedPkg: generic support for reusing PCI drivers for platform devices Ard Biesheuvel
2016-10-31 18:13 ` [PATCH 1/5] EmbeddedPkg: introduce platform PCI I/O protocol Ard Biesheuvel
2016-11-01 21:54   ` Leif Lindholm
2016-11-02 13:29     ` Ard Biesheuvel [this message]
2016-11-02 15:42       ` Leif Lindholm
2016-10-31 18:13 ` [PATCH 2/5] EmbeddedPkg: introduce platform PCI I/O registration library Ard Biesheuvel
2016-11-01 21:57   ` Leif Lindholm
2016-11-02 13:30     ` Ard Biesheuvel
2016-11-02 15:39       ` Leif Lindholm
2016-11-07 14:54       ` Evan Lloyd
2016-10-31 18:13 ` [PATCH 3/5] EmbeddedPkg: implement generic platform PCI I/O driver Ard Biesheuvel
2016-11-01 22:22   ` Leif Lindholm
2016-11-02 13:39     ` Ard Biesheuvel
2016-11-02 16:05       ` Leif Lindholm
2016-10-31 18:13 ` [PATCH 4/5] ArmPkg/CpuDxe: set DmaBufferAlignment according to CWG Ard Biesheuvel
2016-11-01 22:32   ` Leif Lindholm
2016-11-02 13:40     ` Ard Biesheuvel
2016-11-02 16:10       ` Leif Lindholm
2016-11-02 16:17         ` Ard Biesheuvel
2016-11-02 16:21           ` Leif Lindholm
2016-11-02 16:23             ` Ard Biesheuvel
2016-10-31 18:13 ` [PATCH 5/5] EmbeddedPkg/PlatformPciIoDxe: add support for non-coherent DMA Ard Biesheuvel
2016-11-01 22:43   ` Leif Lindholm
2016-11-02 13:43     ` Ard Biesheuvel
2016-11-02 16:17       ` Leif Lindholm
2016-11-01 21:45 ` [PATCH 0/5] EmbeddedPkg: generic support for reusing PCI drivers for platform devices Leif Lindholm

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='CAKv+Gu_YPgGZbarfTJO0AYUGLeMz-=FUHQQ5J_UFV06X=ctxhQ@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