On 10/13/20 11:20 AM, Klaus Herman wrote:
Fixes: bccb20c49df ("hw/core/qdev-properties: Use qemu_strtoul() in
set_pci_host_devaddr()")
Signed-off-by: Klaus Herman <kher...@inbox.lv>
---
hw/core/qdev-properties-system.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/hw/core/qdev-properties-system.c b/hw/core/qdev-properties-system.c
index 49bdd12..e3dca56 100644
--- a/hw/core/qdev-properties-system.c
+++ b/hw/core/qdev-properties-system.c
@@ -903,7 +903,7 @@ static void set_pci_host_devaddr(Object *obj, Visitor *v,
const char *name,
bus = val;
p = (char *)e + 1;
- if (qemu_strtoul(p, &e, 16, &val) < 0 || val > 0x1f || e == p) {
+ if (qemu_strtoul(p, &e, 16, &val) < 0 || val > 0xff || e == p) {
As this is used to check both bus/slot range, I sent a different
approach to fix this issue:
https://lists.gnu.org/archive/html/qemu-devel/2020-10/msg03604.html
goto inval;
}
if (*e == ':') {