Hi,
On top of the latest NonDiscoverable (v4) PciEmulation support (all devices work without modifying already accepted patchset) I submit v3 of Xenon SdMmc driver. Improvements after review of v2 have been implemented, also entire SdMmcPciHcDxe was imported to new driver's directory.
There are two big modifications though - DMA operation has been enabled and the diff between original driver and Xenon version has shrunk and is limited only to the initialization process. Other than that, the second controller on Armada 7040 was added to PciEmulation HW description and later enabled. More details can be found in the changelog.
Code is also available in the github: https://github.com/MarvellEmbeddedProcessors/edk2-open-platform/commits/opp-...
We are looking forward to any comments or remarks.
Best regards, Marcin
Changelog: v2 -> v3 - Move driver to Drivers/SdMmc/XenonDxe/ directory - Use 'Retry' instead of 'Timeout', when necessary - Add comments to remaining stalls - Enable DMA and remove PIO-related modifications - Add description of the second controller in PciEmulation (new commit)
v1 -> v2
- Import whole stack from MdeModulePkg/Bus/Pci/SdMmcPciHcDxe/ - Move driver to Drivers/SdMmc/Xenon/ directory - Use Slot number 0 only, since XENON is using only this one - Remove unnecessary delay - Move SD/MMC PHY configuration to MPP lib (additional commit) - Replace comments with defines - Add descriptions to delays - Improve commit logs
Jan Dąbroś (5): Platforms/Marvell: MppLib: Configure SD/MMC PHY Drivers/SdMmc: Import SdMmcPciHcDxe driver Drivers/SdMmc: Replace deprecated debug level macros Drivers/SdMmc: Adjust stack to fulfill Xenon controller demands Platforms/Marvell: Enable SD/MMC stack for Armada70x0 platforms
Marcin Wojtas (2): Platforms/Marvell/PciEmulation: Add second SD/MMC device of Armada70x0 Platforms/Marvell: Enable SD/MMC for Armada70x0 board
Drivers/SdMmc/XenonDxe/MvComponentName.c | 213 +++ Drivers/SdMmc/XenonDxe/MvEmmcDevice.c | 1164 ++++++++++++++ Drivers/SdMmc/XenonDxe/MvSdDevice.c | 1192 ++++++++++++++ Drivers/SdMmc/XenonDxe/MvSdMmcPciHcDxe.c | 1314 ++++++++++++++++ Drivers/SdMmc/XenonDxe/MvSdMmcPciHcDxe.h | 787 +++++++++ Drivers/SdMmc/XenonDxe/MvSdMmcPciHcDxe.inf | 64 + Drivers/SdMmc/XenonDxe/MvSdMmcPciHcDxe.uni | 23 + Drivers/SdMmc/XenonDxe/MvSdMmcPciHcDxeExtra.uni | 19 + Drivers/SdMmc/XenonDxe/MvSdMmcPciHci.c | 1926 +++++++++++++++++++++++ Drivers/SdMmc/XenonDxe/MvSdMmcPciHci.h | 546 +++++++ Drivers/SdMmc/XenonDxe/XenonSdhci.c | 666 ++++++++ Drivers/SdMmc/XenonDxe/XenonSdhci.h | 346 ++++ Platforms/Marvell/Armada/Armada.dsc.inc | 5 + Platforms/Marvell/Armada/Armada70x0.dsc | 1 + Platforms/Marvell/Armada/Armada70x0.fdf | 7 +- Platforms/Marvell/Library/MppLib/MppLib.c | 53 + Platforms/Marvell/Library/MppLib/MppLib.inf | 1 + Platforms/Marvell/PciEmulation/PciEmulation.c | 8 +- 18 files changed, 8330 insertions(+), 5 deletions(-) create mode 100644 Drivers/SdMmc/XenonDxe/MvComponentName.c create mode 100755 Drivers/SdMmc/XenonDxe/MvEmmcDevice.c create mode 100644 Drivers/SdMmc/XenonDxe/MvSdDevice.c create mode 100644 Drivers/SdMmc/XenonDxe/MvSdMmcPciHcDxe.c create mode 100644 Drivers/SdMmc/XenonDxe/MvSdMmcPciHcDxe.h create mode 100644 Drivers/SdMmc/XenonDxe/MvSdMmcPciHcDxe.inf create mode 100644 Drivers/SdMmc/XenonDxe/MvSdMmcPciHcDxe.uni create mode 100644 Drivers/SdMmc/XenonDxe/MvSdMmcPciHcDxeExtra.uni create mode 100644 Drivers/SdMmc/XenonDxe/MvSdMmcPciHci.c create mode 100644 Drivers/SdMmc/XenonDxe/MvSdMmcPciHci.h create mode 100755 Drivers/SdMmc/XenonDxe/XenonSdhci.c create mode 100644 Drivers/SdMmc/XenonDxe/XenonSdhci.h