[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Qemu-devel] [PATCH 02/26] Allow qemu_devtree_setprop() to take arbitrar
From: |
David Gibson |
Subject: |
[Qemu-devel] [PATCH 02/26] Allow qemu_devtree_setprop() to take arbitrary values |
Date: |
Wed, 16 Mar 2011 15:56:39 +1100 |
From: David Gibson <address@hidden>
Currently qemu_devtree_setprop() expects the new property value to be
given as a uint32_t *. While property values consisting of u32s are
common, in general they can have any bytestring value.
Therefore, this patch alters the function to take a void * instead,
allowing callers to easily give anything as the property value.
Signed-off-by: David Gibson <address@hidden>
---
device_tree.c | 2 +-
device_tree.h | 2 +-
2 files changed, 2 insertions(+), 2 deletions(-)
diff --git a/device_tree.c b/device_tree.c
index 426a631..21be070 100644
--- a/device_tree.c
+++ b/device_tree.c
@@ -74,7 +74,7 @@ fail:
}
int qemu_devtree_setprop(void *fdt, const char *node_path,
- const char *property, uint32_t *val_array, int size)
+ const char *property, void *val_array, int size)
{
int offset;
diff --git a/device_tree.h b/device_tree.h
index f05c4e7..cecd98f 100644
--- a/device_tree.h
+++ b/device_tree.h
@@ -17,7 +17,7 @@
void *load_device_tree(const char *filename_path, int *sizep);
int qemu_devtree_setprop(void *fdt, const char *node_path,
- const char *property, uint32_t *val_array, int size);
+ const char *property, void *val_array, int size);
int qemu_devtree_setprop_cell(void *fdt, const char *node_path,
const char *property, uint32_t val);
int qemu_devtree_setprop_string(void *fdt, const char *node_path,
--
1.7.1
- [Qemu-devel] [PATCH 03/26] Add a hook to allow hypercalls to be emulated on PowerPC, (continued)
[Qemu-devel] [PATCH 01/26] Clean up PowerPC SLB handling code, David Gibson, 2011/03/16
[Qemu-devel] [PATCH 02/26] Allow qemu_devtree_setprop() to take arbitrary values,
David Gibson <=
[Qemu-devel] [PATCH 04/26] Implement PowerPC slbmfee and slbmfev instructions, David Gibson, 2011/03/16
[Qemu-devel] [PATCH 05/26] Implement missing parts of the logic for the POWER PURR, David Gibson, 2011/03/16
[Qemu-devel] [PATCH 07/26] Clean up slb_lookup() function, David Gibson, 2011/03/16
[Qemu-devel] [PATCH 08/26] Parse SDR1 on mtspr instead of at translate time, David Gibson, 2011/03/16
[Qemu-devel] [PATCH 09/26] Use "hash" more consistently in ppc mmu code, David Gibson, 2011/03/16
[Qemu-devel] [PATCH 10/26] Better factor the ppc hash translation path, David Gibson, 2011/03/16
[Qemu-devel] [PATCH 06/26] Correct ppc popcntb logic, implement popcntw and popcntd, David Gibson, 2011/03/16
[Qemu-devel] [PATCH 11/26] Support 1T segments on ppc, David Gibson, 2011/03/16
[Qemu-devel] [PATCH 12/26] Add POWER7 support for ppc, David Gibson, 2011/03/16
[Qemu-devel] [PATCH 15/26] Virtual hash page table handling on pSeries machine, David Gibson, 2011/03/16