summaryrefslogtreecommitdiff
path: root/include
diff options
context:
space:
mode:
authorGabe Black <gabeblack@chromium.org>2012-01-12 23:21:36 -0800
committerGerrit <chrome-bot@google.com>2012-01-13 20:11:57 -0800
commit3b736f1c94547ea5afe5b13d4ad6f7565d1a9c24 (patch)
treeac15ce93aefad1566ddf27f9647e0183ca6613f3 /include
parentbbc467e64948383146c3b230798acb37d9e39929 (diff)
Make the memory wipe code handle 64 bit addresses properly
When telling the memory wipe infrastructure about regions it should and shouldn't wipe, some of those addresses may be 64 bits on x86. This change makes the infrastructure pass around those addresses intact instead of truncating them, and then simply ignore the regions that are unaddressable by U-Boot. BUG=None TEST=Built and booted on Lumpy. Built on Kaen Signed-off-by: Gabe Black <gabeblack@google.com> Change-Id: I657cd5480ca9a33614b032bf2a727d1a74d38b48 Reviewed-on: https://gerrit.chromium.org/gerrit/14149 Reviewed-by: Bill Richardson <wfrichar@chromium.org> Reviewed-by: Simon Glass <sjg@chromium.org> Commit-Ready: Gabe Black (Do Not Use) <gabeblack@google.com> Tested-by: Gabe Black (Do Not Use) <gabeblack@google.com>
Diffstat (limited to 'include')
-rw-r--r--include/chromeos/memory_wipe.h7
1 files changed, 4 insertions, 3 deletions
diff --git a/include/chromeos/memory_wipe.h b/include/chromeos/memory_wipe.h
index cc3535a1ba..a9e5301060 100644
--- a/include/chromeos/memory_wipe.h
+++ b/include/chromeos/memory_wipe.h
@@ -21,12 +21,13 @@
#ifndef CHROMEOS_MEMORY_WIPE_H_
#define CHROMEOS_MEMORY_WIPE_H_
+#include <asm/types.h>
#include <linux/types.h>
/* A node in a linked list of edges, each at position "pos". */
typedef struct memory_wipe_edge_t {
struct memory_wipe_edge_t *next;
- uintptr_t pos;
+ phys_addr_t pos;
} memory_wipe_edge_t;
/*
@@ -51,7 +52,7 @@ void memory_wipe_init(memory_wipe_t *wipe);
* @param start The start of the region.
* @param end The end of the region.
*/
-void memory_wipe_add(memory_wipe_t *wipe, uintptr_t start, uintptr_t end);
+void memory_wipe_add(memory_wipe_t *wipe, phys_addr_t start, phys_addr_t end);
/*
* Subtracts a memory region.
@@ -60,7 +61,7 @@ void memory_wipe_add(memory_wipe_t *wipe, uintptr_t start, uintptr_t end);
* @param start The start of the region.
* @param end The end of the region.
*/
-void memory_wipe_sub(memory_wipe_t *wipe, uintptr_t start, uintptr_t end);
+void memory_wipe_sub(memory_wipe_t *wipe, phys_addr_t start, phys_addr_t end);
/*
* Executes the memory wipe.