public inbox for devel@edk2.groups.io
 help / color / mirror / Atom feed
* [PATCH 0/5] ArmPkg et al: remove UncachedMemoryallocationLib
@ 2017-08-25 12:10 Ard Biesheuvel
  2017-08-25 12:10 ` [PATCH 1/5] EmbeddedPkg/DmaLib: add routine to allocate aligned buffers Ard Biesheuvel
                   ` (5 more replies)
  0 siblings, 6 replies; 10+ messages in thread
From: Ard Biesheuvel @ 2017-08-25 12:10 UTC (permalink / raw)
  To: edk2-devel, leif.lindholm; +Cc: Ard Biesheuvel

This series is a followup to 'ArmPkg/ArmDmaLib: remove dependency on
UncachedMemoryAllocationLib' sent out yesterday, and removes library
entirely.

There are two reasons for this:
- UncachedMemoryAllocationLib is often abused by drivers that should
  be using DMA abstractions instead. It is up to the platform to decide
  whether DMA is cache coherent or not, and the fact that non-cache
  coherent DMA may be implemented using uncached allocations should remain
  an implementation detail of the DmaLib instance.

- The code is poorly maintained, only frees its allocations in the destructor,
  and misleads by exposing pool allocate/free entry points that are actually
  backed by page based allocations.

Patches #1 and #2 add a DmaAllocateAlignedBuffer() to DmaLib and both
its implementations. This is required for current users of
UncachedMemoryAllocationLib that rely on minimum alignment to be able
to switch the DmaLib.

Patches #3 and #4 remove a couple of stale references.

Patch #5 actually removes the library and its single remaining implementation.

Ard Biesheuvel (5):
  EmbeddedPkg/DmaLib: add routine to allocate aligned buffers
  ArmPkg/ArmDmaLib: implement DmaAllocateAlignedBuffer()
  BeagleBoardPkg: remove UncachedMemoryAllocationLib resolutions
  Omap35xxPkg: remove bogus UncachedMemoryAllocationLib dependency
  ArmPkg: remove UncachedMemoryAllocationLib

 ArmPkg/ArmPkg.dec                                                          |   4 -
 ArmPkg/ArmPkg.dsc                                                          |   2 -
 ArmPkg/Include/Library/UncachedMemoryAllocationLib.h                       | 665 ------------------
 ArmPkg/Library/ArmDmaLib/ArmDmaLib.c                                       |  42 +-
 ArmPkg/Library/UncachedMemoryAllocationLib/UncachedMemoryAllocationLib.c   | 719 --------------------
 ArmPkg/Library/UncachedMemoryAllocationLib/UncachedMemoryAllocationLib.inf |  50 --
 BeagleBoardPkg/BeagleBoardPkg.dsc                                          |   2 -
 EmbeddedPkg/Include/Library/DmaLib.h                                       |  30 +-
 EmbeddedPkg/Library/NullDmaLib/NullDmaLib.c                                |  48 +-
 Omap35xxPkg/Library/DebugAgentTimerLib/DebugAgentTimerLib.inf              |   1 +
 Omap35xxPkg/Library/OmapDmaLib/OmapDmaLib.inf                              |   1 -
 Omap35xxPkg/Omap35xxPkg.dsc                                                |   2 -
 12 files changed, 112 insertions(+), 1454 deletions(-)
 delete mode 100644 ArmPkg/Include/Library/UncachedMemoryAllocationLib.h
 delete mode 100644 ArmPkg/Library/UncachedMemoryAllocationLib/UncachedMemoryAllocationLib.c
 delete mode 100644 ArmPkg/Library/UncachedMemoryAllocationLib/UncachedMemoryAllocationLib.inf

-- 
2.11.0



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

end of thread, other threads:[~2017-08-31 13:58 UTC | newest]

Thread overview: 10+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2017-08-25 12:10 [PATCH 0/5] ArmPkg et al: remove UncachedMemoryallocationLib Ard Biesheuvel
2017-08-25 12:10 ` [PATCH 1/5] EmbeddedPkg/DmaLib: add routine to allocate aligned buffers Ard Biesheuvel
2017-08-25 12:10 ` [PATCH 2/5] ArmPkg/ArmDmaLib: implement DmaAllocateAlignedBuffer() Ard Biesheuvel
2017-08-25 12:10 ` [PATCH 3/5] BeagleBoardPkg: remove UncachedMemoryAllocationLib resolutions Ard Biesheuvel
2017-08-25 12:10 ` [PATCH 4/5] Omap35xxPkg: remove bogus UncachedMemoryAllocationLib dependency Ard Biesheuvel
2017-08-25 12:10 ` [PATCH 5/5] ArmPkg: remove UncachedMemoryAllocationLib Ard Biesheuvel
2017-08-31 14:00   ` Ard Biesheuvel
2017-08-29 15:44 ` [PATCH 0/5] ArmPkg et al: remove UncachedMemoryallocationLib Leif Lindholm
2017-08-29 15:47   ` Ard Biesheuvel
2017-08-29 16:57     ` Ard Biesheuvel

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