diff options
| author | Greg KH <gregkh@suse.de> | 2005-09-12 15:10:59 -0400 |
|---|---|---|
| committer | Greg Kroah-Hartman <gregkh@suse.de> | 2005-09-12 15:10:59 -0400 |
| commit | ad2c10f8f00d3fe2e37dd8a107e7cf4ac0459489 (patch) | |
| tree | 5571f6a5784f51efddf9c1ee0408894cd63a460f /arch/um/include/mem.h | |
| parent | 6b7839007098a6b5612d31690e11277d4242e6ae (diff) | |
| parent | 2ade81473636b33aaac64495f89a7dc572c529f0 (diff) | |
Merge ../torvalds-2.6/
Diffstat (limited to 'arch/um/include/mem.h')
| -rw-r--r-- | arch/um/include/mem.h | 12 |
1 files changed, 11 insertions, 1 deletions
diff --git a/arch/um/include/mem.h b/arch/um/include/mem.h index 99d3ad4a03e5..e8ff0d8fa610 100644 --- a/arch/um/include/mem.h +++ b/arch/um/include/mem.h | |||
| @@ -13,7 +13,17 @@ extern int physmem_subst_mapping(void *virt, int fd, __u64 offset, int w); | |||
| 13 | extern int is_remapped(void *virt); | 13 | extern int is_remapped(void *virt); |
| 14 | extern int physmem_remove_mapping(void *virt); | 14 | extern int physmem_remove_mapping(void *virt); |
| 15 | extern void physmem_forget_descriptor(int fd); | 15 | extern void physmem_forget_descriptor(int fd); |
| 16 | extern unsigned long to_phys(void *virt); | 16 | |
| 17 | extern unsigned long uml_physmem; | ||
| 18 | static inline unsigned long to_phys(void *virt) | ||
| 19 | { | ||
| 20 | return(((unsigned long) virt) - uml_physmem); | ||
| 21 | } | ||
| 22 | |||
| 23 | static inline void *to_virt(unsigned long phys) | ||
| 24 | { | ||
| 25 | return((void *) uml_physmem + phys); | ||
| 26 | } | ||
| 17 | 27 | ||
| 18 | #endif | 28 | #endif |
| 19 | 29 | ||
