static int parse_uint32(DeviceState *dev, Property *prop, const char *str)

{

    uint32_t *ptr = qdev_get_prop_ptr(dev, prop);

    const char *fmt;



    /* accept both hex and decimal */

    fmt = strncasecmp(str, "0x",2) == 0 ? "%" PRIx32 : "%" PRIu32;

    if (sscanf(str, fmt, ptr) != 1)

        return -EINVAL;

    return 0;

}

static int parse_uint32(DeviceState *dev, Property *prop, const char *str)

{

    uint32_t *ptr = qdev_get_prop_ptr(dev, prop);

    const char *fmt;



    

    fmt = strncasecmp(str, "0x",2) == 0 ? "%" PRIx32 : "%" PRIu32;

    if (sscanf(str, fmt, ptr) != 1)

        return -EINVAL;

    return 0;

}

    const char *fmt;     if (sscanf(str, fmt, ptr) != 1)     const char *fmt;     if (sscanf(str, fmt, ptr) != 1)     const char *fmt;     fmt = strncasecmp(str, "0x",2) == 0 ? "%" PRIx32 : "%" PRIu32;     if (sscanf(str, fmt, ptr) != 1)     const char *fmt;     if (sscanf(str, fmt, ptr) != 1)
static int FUNC_0(DeviceState *VAR_0, Property *VAR_1, const char *VAR_2)

{

    uint32_t *ptr = qdev_get_prop_ptr(VAR_0, VAR_1);

    const char *VAR_3;



    

    VAR_3 = strncasecmp(VAR_2, "0x",2) == 0 ? "%" PRIx32 : "%" PRIu32;

    if (sscanf(VAR_2, VAR_3, ptr) != 1)

        return -EINVAL;

    return 0;

}

static int FUNC_0(DeviceState *VAR_0, Property *VAR_1, const char *VAR_2)
{ uint32_t *ptr = qdev_get_prop_ptr(VAR_0, VAR_1); const char *VAR_3; VAR_3 = strncasecmp(VAR_2, "0x",2) == 0 ? "%" PRIx32 : "%" PRIu32; if (sscanf(VAR_2, VAR_3, ptr) != 1)
return -EINVAL; return 0; }