diff options
author | Stefan Tauner <stefan.tauner@alumni.tuwien.ac.at> | 2013-08-14 15:48:44 +0000 |
---|---|---|
committer | Stefan Tauner <stefan.tauner@alumni.tuwien.ac.at> | 2013-08-14 15:48:44 +0000 |
commit | 1e06de6c07849b4fe92ad38d6cc9d4307f1ceb98 (patch) | |
tree | 3d193e98d25da24307824ab8d0939f3538ec2e50 /programmer.h | |
parent | 2a691febad07af468248a5f451347cfdf196b1b3 (diff) | |
download | flashrom-1e06de6c07849b4fe92ad38d6cc9d4307f1ceb98.zip flashrom-1e06de6c07849b4fe92ad38d6cc9d4307f1ceb98.tar.gz |
Automatically unmap physmap()s
Similarly to the previous PCI self-clean up patch this one allows to get rid
of a huge number of programmer shutdown functions and makes introducing
bugs harder. It adds a new function rphysmap() that takes care of unmapping
at shutdown. Callers are changed where it makes sense.
Corresponding to flashrom svn r1714.
Signed-off-by: Stefan Tauner <stefan.tauner@alumni.tuwien.ac.at>
Acked-by: Carl-Daniel Hailfinger <c-d.hailfinger.devel.2006@gmx.net>
Diffstat (limited to 'programmer.h')
-rw-r--r-- | programmer.h | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/programmer.h b/programmer.h index 4db8d58..f9f5241 100644 --- a/programmer.h +++ b/programmer.h @@ -276,6 +276,7 @@ int processor_flash_enable(void); /* physmap.c */ void *physmap(const char *descr, uintptr_t phys_addr, size_t len); +void *rphysmap(const char *descr, uintptr_t phys_addr, size_t len); void *physmap_try_ro(const char *descr, uintptr_t phys_addr, size_t len); void physunmap(void *virt_addr, size_t len); #if CONFIG_INTERNAL == 1 |