qom: Use qlit to represent property defaults
Get series with b4
b4 am [email protected]Versions newest first · linked by author and title
- v3 Latest19 patches 9 repliesIn review
- v28 patches 45 repliesSuperseded
- v18 patches 2 repliesSuperseded
Changes in v3 from the cover letter
* qnum/qlit patches:
* Variable naming in qnum code
* Coding style changes in qnum code
* Split "qlit: Support all types of QNums"
in smaller patches
* Replace QLIT_QNUM with QLIT_QNUM_INT
* Extend test cases, move most of the new test case code to check-qlit.c
* Remove qnum_get_value() and qlit_get_type() function
* Removed kernel-doc conversion patch, to reduce noise in series review
* qom patches:
* Split "qom: Use qlit to represent property defaults" in smaller patches, hopefully making review easier
* Small changes in UUID property code (See
"qom: Don't ignore defval on UUID property" and
"qom: Fix documentation of UUID property type")
Patches in v3 No applies recorded yet
| # | Subject and files | Size | Replies | Applied |
|---|---|---|---|---|
| 1/19 | qnum: Make qnum_get_double() get const pointerinclude/ qobject/ | +2 | 0 replies | |
| 2/19 | qnum: Make num_x/num_y variables at qnum_is_equal() constqobject/ | +2 | 0 replies | |
| 3/19 | qnum: QNumValue type for QNum value literalsinclude/ qobject/ tests/ | +76 | 0 replies | |
| 4/19 | qnum: qnum_value_is_equal() functioninclude/ qobject/ | +17 | 0 replies | |
| 5/19 | qlit: Use qnum_value_is_equal() when comparing QNumsqobject/ tests/ | +21 | 0 replies | |
| 6/19 | qlit: Rename QLIT_QNUM to QLIT_QNUM_INTinclude/ tests/ tests/ | +21 | 0 replies | |
| 7/19 | qlit: Use QNumValue to represent QNumsinclude/ qobject/ | +5 | 0 replies | |
| 8/19 | qlit: Move qlit_equal_qobject() reference values to arraytests/ | +19 | 3 replies | |
| 9/19 | qlit: Add more test literals to qlit_equal_qobject() test casetests/ | +16 | 0 replies | |
| 10/19 | qlit: Support all types of QNumsinclude/ tests/ | +9 | 4 replies | |
| 11/19 | qom: field_prop_set_default_value() helperqom/ | +16 | 2 replies | |
| 12/19 | qom: Replace defval value in Property with QLitObjecthw/ include/ include/ +4 more | +54 | 0 replies | |
| 13/19 | qom: Fix documentation of UUID property typehw/ | +1 | 0 replies | |
| 14/19 | qom: Don't ignore defval on UUID propertyhw/ include/ | +8 | 0 replies | |
| 15/19 | qom: Make object_property_set_default() publicinclude/ qom/ | +12 | 0 replies | |
| 16/19 | qom: Make PropertyInfo.set_default_value optionalinclude/ qom/ | +13 | 0 replies | |
| 17/19 | qom: Delete field_prop_set_default_value_*int()hw/ include/ qom/ | +0 | 0 replies | |
| 18/19 | qom: Delete set_default_uuid()hw/ | +0 | 0 replies | |
| 19/19 | qom: Delete set_default_value_bool()qom/ | +0 | 0 replies |
Reviews trailers per patch
2 of 19 patches have a Reviewed-by or Acked-by.
| Patch | Marc-André Lureau |
|---|---|
| 1/19 | R-b |
| 2/19 | |
| 3/19 | |
| 4/19 | |
| 5/19 | |
| 6/19 | |
| 7/19 | |
| 8/19 | |
| 9/19 | |
| 10/19 | |
| 11/19 | |
| 12/19 | |
| 13/19 | |
| 14/19 | |
| 15/19 | R-b |
| 16/19 | |
| 17/19 | |
| 18/19 | |
| 19/19 |
Trailers given in replies are filled; those carried in the patches from earlier versions are outlined with dashes.
Cover letter [PATCH v3 00/19] qom: Use qlit to represent property defaults
Based-on: [email protected]
Git branch: https://gitlab.com/ehabkost/qemu/-/commits/work/qdev-qlit-defaults
This extend qlit.h to support all QNum types (signed int, unsigned int, and double), and use QLitObject to represent field property defaults.
It allows us to get rid of most type-specific .set_default_value functions for QOM property types.
The only remaining .set_default_value function in the code is field_prop_set_default_value_enum(). This will take a bit more work because the default is currently stored as int, but parsed as string, so it will be addressed in a separate series.
Changes v2 -> v3:
* qnum/qlit patches:
* Variable naming in qnum code
* Coding style changes in qnum code
* Split "qlit: Support all types of QNums"
in smaller patches
* Replace QLIT_QNUM with QLIT_QNUM_INT
* Extend test cases, move most of the new test case code to check-qlit.c
* Remove qnum_get_value() and qlit_get_type() function
* Removed kernel-doc conversion patch, to reduce noise in series review
* qom patches:
* Split "qom: Use qlit to represent property defaults" in smaller patches, hopefully making review easier
* Small changes in UUID property code (See
"qom: Don't ignore defval on UUID property" and
"qom: Fix documentation of UUID property type")
Changes v1 -> v2:
* Rebase to latest version of field properties series
* Fix unit test failure
* Coding style changes
Eduardo Habkost (19):
qnum: Make qnum_get_double() get const pointer
qnum: Make num_x/num_y variables at qnum_is_equal() const
qnum: QNumValue type for QNum value literals
qnum: qnum_value_is_equal() function
qlit: Use qnum_value_is_equal() when comparing QNums
qlit: Rename QLIT_QNUM to QLIT_QNUM_INT
qlit: Use QNumValue to represent QNums
qlit: Move qlit_equal_qobject() reference values to array
qlit: Add more test literals to qlit_equal_qobject() test case
qlit: Support all types of QNums
qom: field_prop_set_default_value() helper
qom: Replace defval value in Property with QLitObject
qom: Fix documentation of UUID property type
qom: Don't ignore defval on UUID property
qom: Make object_property_set_default() public
qom: Make PropertyInfo.set_default_value optional
qom: Delete field_prop_set_default_value_*int()
qom: Delete set_default_uuid()
qom: Delete set_default_value_bool()
include/hw/qdev-properties-system.h | 4 +- include/qapi/qmp/qlit.h | 11 ++- include/qapi/qmp/qnum.h | 26 +++++- include/qom/field-property-internal.h | 7 +- include/qom/field-property.h | 30 +++---- include/qom/object.h | 11 +++ include/qom/property-types.h | 18 ++-- hw/core/qdev-properties-system.c | 13 +-- qobject/qlit.c | 5 +- qobject/qnum.c | 113 ++++++++++++++------------ qom/field-property.c | 36 ++++++-- qom/object.c | 2 +- qom/property-types.c | 37 ++------- tests/check-qjson.c | 30 +++---- tests/check-qlit.c | 72 +++++++++++++--- tests/check-qnum.c | 14 ++-- 16 files changed, 253 insertions(+), 176 deletions(-)
Signature · 1 line
2.28.0