So, I have no strong objection to this set, but I do have a question/comment:
The semicolon-separated-arrays-in-Pcds mechanism is now by far the clunkiest aspect of this set.
I can well see a near future in which we add a core library to consume a static struct from a platform library and do the registration on. At that point, I would like this code to move over to that.
So is there any way we could delete all the Pcd juggling, stick a small static struct and a much simpler iterator into Armada70x0Lib from day one instead?
Regards,
Leif
On Tue, Nov 15, 2016 at 05:29:56PM +0100, Marcin Wojtas wrote:
Hi,
I send v3 of PciEmulation, which base on NonDiscoverablePciDeviceDxe driver: [PATCH v2 0/5] MdeModulePkg: add support for non-discoverable devices
Code is also available in the github: https://github.com/MarvellEmbeddedProcessors/edk2-open-platform/commits/opp-...
According to review comments, PCD usage is improved, as well as redundant includes or packages were removed.
We still do not have boards with new SATA IP, but if this version of PciEmulation is accepted, let's keep it in hand until NonDiscoverablePciDeviceDxe gets merged or sort out some solution in the end of November.
I'm looking forward to your review.
Best regards, Marcin
Changelog v2 -> v3
- Use static globals for PCD-related variables
- Check with 'if' in runtime if they are correct
- Return error on each kind of failure
- Don't use arrays of DmaTypes/DevTypes for registering NonDiscoverableDevices
- Remove redundant protocols, includes, libraries
- Add reviewed-by in patches 2-6
v1 -> v2
- Move to NonDiscoverablePciDeviceDxe
Jan Dąbroś (4): Platforms/Marvell: Enable PciEmulation driver for Armada70x0 platform Platforms/Marvell: Enable USB stack for Armada70x0 platform Platforms/Marvell: Enable two xHCI ports for Armada70x0 board Platforms/Marvell: Enable SATA stack for Armada70x0 platform
Marcin Wojtas (2): Platforms/Marvell: Add PciEmulation driver Platforms/Marvell: Enable SATA port for Armada70x0 board
.../Marvell/PortingGuide/PciEmulation.txt | 46 ++++++++ Platforms/Marvell/Armada/Armada.dsc.inc | 19 ++++ Platforms/Marvell/Armada/Armada70x0.dsc | 10 ++ Platforms/Marvell/Armada/Armada70x0.fdf | 18 ++++ Platforms/Marvell/Marvell.dec | 6 ++ Platforms/Marvell/PciEmulation/PciEmulation.c | 119 +++++++++++++++++++++ Platforms/Marvell/PciEmulation/PciEmulation.inf | 46 ++++++++ 7 files changed, 264 insertions(+) create mode 100644 Documentation/Marvell/PortingGuide/PciEmulation.txt create mode 100644 Platforms/Marvell/PciEmulation/PciEmulation.c create mode 100644 Platforms/Marvell/PciEmulation/PciEmulation.inf
-- 1.8.3.1