aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--include/exec/memory.h11
-rw-r--r--memory.c10
2 files changed, 0 insertions, 21 deletions
diff --git a/include/exec/memory.h b/include/exec/memory.h
index 51a54c92d5..37f8e78e71 100644
--- a/include/exec/memory.h
+++ b/include/exec/memory.h
@@ -825,17 +825,6 @@ static inline bool memory_region_is_rom(MemoryRegion *mr)
int memory_region_get_fd(MemoryRegion *mr);
/**
- * memory_region_set_fd: Mark a RAM memory region as backed by a
- * file descriptor.
- *
- * This function is typically used after memory_region_init_ram_ptr().
- *
- * @mr: the memory region being queried.
- * @fd: the file descriptor that backs @mr.
- */
-void memory_region_set_fd(MemoryRegion *mr, int fd);
-
-/**
* memory_region_from_host: Convert a pointer into a RAM memory region
* and an offset within it.
*
diff --git a/memory.c b/memory.c
index b2ace20bac..e08fa0ae6c 100644
--- a/memory.c
+++ b/memory.c
@@ -1851,16 +1851,6 @@ int memory_region_get_fd(MemoryRegion *mr)
return fd;
}
-void memory_region_set_fd(MemoryRegion *mr, int fd)
-{
- rcu_read_lock();
- while (mr->alias) {
- mr = mr->alias;
- }
- mr->ram_block->fd = fd;
- rcu_read_unlock();
-}
-
void *memory_region_get_ram_ptr(MemoryRegion *mr)
{
void *ptr;