Philipp Deppenwiese | d8fe443 | 2016-03-18 00:52:54 +0100 | [diff] [blame] | 1 | /* intelmetool |
| 2 | * |
| 3 | * Copyright (C) 2013-2015 Damien Zammit <damien@zamaudio.com> |
| 4 | * |
| 5 | * This program is free software; you can redistribute it and/or |
| 6 | * modify it under the terms of the GNU General Public License as |
| 7 | * published by the Free Software Foundation; either version 2 of |
| 8 | * the License, or any later version. |
| 9 | * |
| 10 | * This program is distributed in the hope that it will be useful, |
| 11 | * but WITHOUT ANY WARRANTY; without even the implied warranty of |
| 12 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the |
| 13 | * GNU General Public License for more details. |
| 14 | */ |
| 15 | |
| 16 | #include <inttypes.h> |
| 17 | #include <stdlib.h> |
| 18 | #include <fcntl.h> |
| 19 | #include <sys/mman.h> |
| 20 | #include <stdio.h> |
| 21 | |
| 22 | #ifndef __DARWIN__ |
| 23 | extern int fd_mem; |
Paul Menzel | 1e7911e | 2016-12-27 15:24:02 +0100 | [diff] [blame] | 24 | extern void *map_physical(off_t phys_addr, size_t len); |
Philipp Deppenwiese | d8fe443 | 2016-03-18 00:52:54 +0100 | [diff] [blame] | 25 | extern void unmap_physical(void *virt_addr, size_t len); |
Paul Menzel | 1e7911e | 2016-12-27 15:24:02 +0100 | [diff] [blame] | 26 | extern void *map_physical_exact(off_t phys_addr, void *mapto, size_t len); |
Philipp Deppenwiese | d8fe443 | 2016-03-18 00:52:54 +0100 | [diff] [blame] | 27 | #endif |