Message ID | 20240311-qapi-firmware-json-v3-2-ceea6e35eb4a@linutronix.de (mailing list archive) |
---|---|
State | New, archived |
Headers | show |
Series | docs/interop/firmware.json: scripts/qapi-gen.py compatibility | expand |
Thomas Weißschuh <thomas.weissschuh@linutronix.de> writes: > Only a small subset of all architectures supported by qemu make use of > firmware files. Introduce and use a new enum to represent this. > > This also removes the dependency of firmware.json on the global qapi > definitions. > > Suggested-by: Daniel P. Berrangé <berrange@redhat.com> > Signed-off-by: Thomas Weißschuh <thomas.weissschuh@linutronix.de> > --- > docs/interop/firmware.json | 20 +++++++++++++++++--- > 1 file changed, 17 insertions(+), 3 deletions(-) > > diff --git a/docs/interop/firmware.json b/docs/interop/firmware.json > index 0e619e8780e7..54cae6a51b43 100644 > --- a/docs/interop/firmware.json > +++ b/docs/interop/firmware.json > @@ -14,11 +14,13 @@ > # = Firmware > ## > > -{ 'include' : 'machine.json' } > - > { 'pragma': { > 'documentation-exceptions': [ > + 'FirmwareArchitecture', Comment on the previous patch applies. > 'FirmwareFormat' > + ], > + 'member-name-exceptions': [ > + 'FirmwareArchitecture' Needed for x86_64. Fine. > ] } } > > ## > @@ -64,6 +66,18 @@ > { 'enum' : 'FirmwareDevice', > 'data' : [ 'flash', 'kernel', 'memory' ] } > > +## > +# @FirmwareArchitecture: > +# > +# Enumerations of architectures for which Qemu uses additional firmware files. > +# The values are a subset of the enum SysEmuTarget. > +# > +# Since: 8.3 > +## > +{ 'enum' : 'FirmwareArchitecture', > + 'data' : [ 'aarch64', 'arm', 'i386', 'loongarch64', 'x86_64' ] } > + > + > ## > # @FirmwareTarget: > # > @@ -85,7 +99,7 @@ > # Since: 3.0 > ## > { 'struct' : 'FirmwareTarget', > - 'data' : { 'architecture' : 'SysEmuTarget', > + 'data' : { 'architecture' : 'FirmwareArchitecture', > 'machines' : [ 'str' ] } } > > ##
diff --git a/docs/interop/firmware.json b/docs/interop/firmware.json index 0e619e8780e7..54cae6a51b43 100644 --- a/docs/interop/firmware.json +++ b/docs/interop/firmware.json @@ -14,11 +14,13 @@ # = Firmware ## -{ 'include' : 'machine.json' } - { 'pragma': { 'documentation-exceptions': [ + 'FirmwareArchitecture', 'FirmwareFormat' + ], + 'member-name-exceptions': [ + 'FirmwareArchitecture' ] } } ## @@ -64,6 +66,18 @@ { 'enum' : 'FirmwareDevice', 'data' : [ 'flash', 'kernel', 'memory' ] } +## +# @FirmwareArchitecture: +# +# Enumerations of architectures for which Qemu uses additional firmware files. +# The values are a subset of the enum SysEmuTarget. +# +# Since: 8.3 +## +{ 'enum' : 'FirmwareArchitecture', + 'data' : [ 'aarch64', 'arm', 'i386', 'loongarch64', 'x86_64' ] } + + ## # @FirmwareTarget: # @@ -85,7 +99,7 @@ # Since: 3.0 ## { 'struct' : 'FirmwareTarget', - 'data' : { 'architecture' : 'SysEmuTarget', + 'data' : { 'architecture' : 'FirmwareArchitecture', 'machines' : [ 'str' ] } } ##
Only a small subset of all architectures supported by qemu make use of firmware files. Introduce and use a new enum to represent this. This also removes the dependency of firmware.json on the global qapi definitions. Suggested-by: Daniel P. Berrangé <berrange@redhat.com> Signed-off-by: Thomas Weißschuh <thomas.weissschuh@linutronix.de> --- docs/interop/firmware.json | 20 +++++++++++++++++--- 1 file changed, 17 insertions(+), 3 deletions(-)