public inbox for devel@edk2.groups.io
 help / color / mirror / Atom feed
* [PATCH 0/6] ArmPkg EmbeddedPkg: clean up DmaLib implementations
@ 2017-08-30  8:21 Ard Biesheuvel
  2017-08-30  8:21 ` [PATCH 1/6] EmbeddedPkg: rename NullDmaLib to CoherentDmaLib Ard Biesheuvel
                   ` (6 more replies)
  0 siblings, 7 replies; 17+ messages in thread
From: Ard Biesheuvel @ 2017-08-30  8:21 UTC (permalink / raw)
  To: edk2-devel, leif.lindholm; +Cc: Ard Biesheuvel

Currently, we have two DmaLib implementations: a cache coherent one called
'NullDmaLib' residing in EmbeddedPkg, and a non-cache coherent one called
'ArmDmaLib', residinh in ArmPkg.

In both cases, this is slightly awkward: NullDmaLib suggests no functionality
whatsoever, which is slightly misleading because 'nothing' is the correct
action in case of cache coherent DMA, rather than a lack of action. As for
ArmDmalib, this was never specific to ARM, and no longer depends on anything
that ArmPkg provides, so it does not really belong in ArmPkg anymore.

So let's rename them to CoherentDmaLib and NonCoherentDmaLib, respectively,
and move that latter into EmbeddedPkg where it arguably belongs. To align
the two further, add support for non-1:1 DMA mappings to CoherentDmaLib as
well.

Note that the final patch can only be merged after out-of-tree platforms
have switched from ArmDmaLib to NonCoherentDmaLib.

Ard Biesheuvel (6):
  EmbeddedPkg: rename NullDmaLib to CoherentDmaLib
  EmbeddedPkg/CoherentDmaLib: add support for non-1:1 DMA translation
  EmbeddedPkg: implement NonCoherentDmaLib based on ArmDmaLib
  Omap35xxPkg: switch to EmbeddedPkg's NonCoherentDmaLib
  BeagleBoardPkg: switch to generic non-coherent DmaLib
  ArmPkg: remove ArmDmaLib

 ArmPkg/ArmPkg.dsc                                                                                 |   2 -
 ArmPkg/Library/ArmDmaLib/ArmDmaLib.inf                                                            |  49 ---------
 BeagleBoardPkg/BeagleBoardPkg.dsc                                                                 |   2 +-
 EmbeddedPkg/EmbeddedPkg.dec                                                                       |   7 ++
 EmbeddedPkg/EmbeddedPkg.dsc                                                                       |   3 +-
 EmbeddedPkg/Library/{NullDmaLib/NullDmaLib.c => CoherentDmaLib/CoherentDmaLib.c}                  |  10 +-
 EmbeddedPkg/Library/{NullDmaLib/NullDmaLib.inf => CoherentDmaLib/CoherentDmaLib.inf}              |  19 ++--
 ArmPkg/Library/ArmDmaLib/ArmDmaLib.c => EmbeddedPkg/Library/NonCoherentDmaLib/NonCoherentDmaLib.c | 105 +++++++++++---------
 EmbeddedPkg/Library/NonCoherentDmaLib/NonCoherentDmaLib.inf                                       |  50 ++++++++++
 Omap35xxPkg/Omap35xxPkg.dsc                                                                       |   2 +-
 10 files changed, 136 insertions(+), 113 deletions(-)
 delete mode 100644 ArmPkg/Library/ArmDmaLib/ArmDmaLib.inf
 rename EmbeddedPkg/Library/{NullDmaLib/NullDmaLib.c => CoherentDmaLib/CoherentDmaLib.c} (94%)
 rename EmbeddedPkg/Library/{NullDmaLib/NullDmaLib.inf => CoherentDmaLib/CoherentDmaLib.inf} (75%)
 rename ArmPkg/Library/ArmDmaLib/ArmDmaLib.c => EmbeddedPkg/Library/NonCoherentDmaLib/NonCoherentDmaLib.c (82%)
 create mode 100644 EmbeddedPkg/Library/NonCoherentDmaLib/NonCoherentDmaLib.inf

-- 
2.11.0



^ permalink raw reply	[flat|nested] 17+ messages in thread

end of thread, other threads:[~2017-09-01 11:59 UTC | newest]

Thread overview: 17+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2017-08-30  8:21 [PATCH 0/6] ArmPkg EmbeddedPkg: clean up DmaLib implementations Ard Biesheuvel
2017-08-30  8:21 ` [PATCH 1/6] EmbeddedPkg: rename NullDmaLib to CoherentDmaLib Ard Biesheuvel
2017-08-30 10:46   ` Leif Lindholm
2017-08-30 10:52     ` Ard Biesheuvel
2017-08-30 11:37       ` Leif Lindholm
2017-08-30  8:21 ` [PATCH 2/6] EmbeddedPkg/CoherentDmaLib: add support for non-1:1 DMA translation Ard Biesheuvel
2017-08-30 10:51   ` Leif Lindholm
2017-08-30 10:54     ` Ard Biesheuvel
2017-08-30 11:47       ` Leif Lindholm
2017-08-30  8:21 ` [PATCH 3/6] EmbeddedPkg: implement NonCoherentDmaLib based on ArmDmaLib Ard Biesheuvel
2017-08-30 13:05   ` Leif Lindholm
2017-08-30  8:21 ` [PATCH 4/6] Omap35xxPkg: switch to EmbeddedPkg's NonCoherentDmaLib Ard Biesheuvel
2017-08-30  8:21 ` [PATCH 5/6] BeagleBoardPkg: switch to generic non-coherent DmaLib Ard Biesheuvel
2017-08-30  8:21 ` [PATCH 6/6] ArmPkg: remove ArmDmaLib Ard Biesheuvel
2017-08-30 13:06 ` [PATCH 0/6] ArmPkg EmbeddedPkg: clean up DmaLib implementations Leif Lindholm
2017-08-30 13:17   ` Ard Biesheuvel
2017-09-01 12:01     ` Ard Biesheuvel

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox