Hi Leif,
2016-11-17 12:45 GMT+01:00 Leif Lindholm leif.lindholm@linaro.org:
On Thu, Nov 17, 2016 at 12:05:23PM +0100, Marcin Wojtas wrote:
From: Jan Dąbroś jsd@semihalf.com
Import SdMmcPciHcDxe.c from tianocore/edk2 tree at revision a5991c8832c5: "IntelSiliconPkg: Add PCD for Graphics VBT FFS GUID" and rename it as MvSdMmcPciHcDxe.c
Because Marvell Xenon SD/MMC controller isn't fully compatible with SDHCI specification, it demands some quirks on generic driver during initialization and command processing. In order to achieve that, MdeModulePkg/Bus/Pci/SdMmcPciHcDxe/SdMmcPciHcDxe.c is imported and adjusted correctly in following commit. Also in next patch's commit message necessary changes to generic driver are listed.
Xenon SD/MMC controller is present on Marvell Armada70x0 SoCs.
EFI_D_INFO, EFI_D_VERBOSE, EFI_D_WARN and EFI_D_ERROR are replaced with currently recommended values.
Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Jan Dabros jsd@semihalf.com Signed-off-by: Marcin Wojtas mw@semihalf.com
Drivers/SdMmc/MvSdMmcPciHcDxe.c | 1316 +++++++++++++++++++++++++++++++++++++++ 1 file changed, 1316 insertions(+) create mode 100644 Drivers/SdMmc/MvSdMmcPciHcDxe.c
If you're forking the SdMmc driver to reimplement it, you need to copy the whole driver across, not just select pieces of it. If you don't want the maintenance cost of keeping a full forked driver alive, please look into whether your required changes could be conditionally incorporated either within the existing MdeModulePkg/Bus/Pci/SdMmcPciHcDxe/ driver or the EmbeddedPkg/Universal/MmcDxe/ one.
Ok, sure. We tried various ways for submission of the quirks to the block layer (Bus/Sd/SdDxe/SdBlockIo.c / MdeModulePkg/Bus/Sd/EmmcDxe/EmmcBlockIo.c), but all were rejected. Forking entire Pci/SdMmcPciHcDxe/ and not touching upper layers is IMO easier and cleaner, so if you don't mind, the import will be done in next spin.
Best regards, Marcin