Revision: 18756
          http://sourceforge.net/p/edk2/code/18756
Author:   abiesheuvel
Date:     2015-11-09 13:27:36 +0000 (Mon, 09 Nov 2015)
Log Message:
-----------
ArmCacheMaintenanceLib: disallow whole D-cache maintenance operations

The ARM architecture provides no reliable way to clean or invalidate
the entire data cache at runtime. The reason is that such maintenance
requires the use of set/way maintenance operations, which are suitable
only for the kind of maintenance that is carried out when the cache is
taken offline entirely.

So ASSERT () when any of the CacheMaintenanceLib whole data cache routines
are invoked rather than pretending we can do anything meaningful here.

Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Ard Biesheuvel <[email protected]>
Reviewed-by: Leif Lindholm <[email protected]>

Modified Paths:
--------------
    trunk/edk2/ArmPkg/Library/ArmCacheMaintenanceLib/ArmCacheMaintenanceLib.c

Modified: 
trunk/edk2/ArmPkg/Library/ArmCacheMaintenanceLib/ArmCacheMaintenanceLib.c
===================================================================
--- trunk/edk2/ArmPkg/Library/ArmCacheMaintenanceLib/ArmCacheMaintenanceLib.c   
2015-11-09 13:27:15 UTC (rev 18755)
+++ trunk/edk2/ArmPkg/Library/ArmCacheMaintenanceLib/ArmCacheMaintenanceLib.c   
2015-11-09 13:27:36 UTC (rev 18756)
@@ -14,6 +14,7 @@
 **/
 #include <Base.h>
 #include <Library/ArmLib.h>
+#include <Library/DebugLib.h>
 #include <Library/PcdLib.h>
 
 VOID
@@ -44,7 +45,6 @@
   VOID
   )
 {
-  ArmCleanDataCache();
   ArmInvalidateInstructionCache();
 }
 
@@ -54,7 +54,7 @@
   VOID
   )
 {
-  ArmInvalidateDataCache();
+  ASSERT (FALSE);
 }
 
 VOID *
@@ -75,7 +75,7 @@
   VOID
   )
 {
-  ArmCleanInvalidateDataCache();
+  ASSERT (FALSE);
 }
 
 VOID *
@@ -95,7 +95,7 @@
   VOID
   )
 {
-  ArmCleanDataCache();
+  ASSERT (FALSE);
 }
 
 VOID *


------------------------------------------------------------------------------
Presto, an open source distributed SQL query engine for big data, initially
developed by Facebook, enables you to easily query your data on Hadoop in a 
more interactive manner. Teradata is also now providing full enterprise
support for Presto. Download a free open source copy now.
http://pubads.g.doubleclick.net/gampad/clk?id=250295911&iu=/4140
_______________________________________________
edk2-commits mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/edk2-commits

Reply via email to