[libvirt] [PATCH v2 1/6] conf: add 'isa' controller type

Roman Bogorodskiy bogorodskiy at gmail.com
Sun Mar 3 14:04:38 UTC 2019


  Ján Tomko wrote:

> On Sun, Feb 17, 2019 at 05:04:00PM +0400, Roman Bogorodskiy wrote:
> >Introduce 'isa' controller type. The only supported model
> >now is 'isa-bridge'. In domain XML it looks this way:
> >
> >    ...
> >    <controller type='isa' index='1' model='isa-bridge'>
> >      <address type='pci' domain='0x0000' bus='0x00' slot='0x01'
> >               function='0x0'/>
> >    </controller>
> >    ...
> >
> >Currently, this is needed for the bhyve driver to allow choosing a
> >specific PCI address for that. In bhyve, this controller is used to
> >attach serial ports and a boot ROM.
> >
> >Signed-off-by: Roman Bogorodskiy <bogorodskiy at gmail.com>
> >---
> > docs/schemas/domaincommon.rng  | 13 +++++++++++++
> > src/conf/domain_conf.c         | 10 ++++++++++
> > src/conf/domain_conf.h         |  9 +++++++++
> 
> This esentially implements the parser and formatter for the controller,
> so the XML to XML test addition should be a part of it.

In this case I'm inclined to squash three patches together: this one is
fairly small (will be even smaller with the model attr dropped), and
the automatic addition of the isa controller is also fairly small.

> > src/qemu/qemu_command.c        |  1 +
> > src/qemu/qemu_domain.c         |  2 ++
> > src/qemu/qemu_domain_address.c |  1 +
> > src/vbox/vbox_common.c         |  1 +
> > 7 files changed, 37 insertions(+)
> >
> >diff --git a/docs/schemas/domaincommon.rng b/docs/schemas/domaincommon.rng
> >index ba80440c72..2bf67eaa5a 100644
> >--- a/docs/schemas/domaincommon.rng
> >+++ b/docs/schemas/domaincommon.rng
> >@@ -2201,6 +2201,19 @@
> >               </attribute>
> >             </optional>
> >           </group>
> >+          <!-- isa has an optional attribute "model" -->
> 
> I sincerely hope nobody will ever need to specify the model for an ISA
> controller.
> 
> >+          <group>
> >+            <attribute name="type">
> >+              <value>isa</value>
> >+            </attribute>
> 
> >+            <optional>
> >+              <attribute name="model">
> >+                <choice>
> >+                  <value>isa-bridge</value>
> >+                </choice>
> >+              </attribute>
> >+            </optional>
> 
> This would not be needed then.
> 
> >+          </group>
> >           <!-- pci has an optional attribute "model" -->
> >           <group>
> >             <attribute name="type">



Roman Bogorodskiy
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 455 bytes
Desc: not available
URL: <http://listman.redhat.com/archives/libvir-list/attachments/20190303/33312d20/attachment-0001.sig>


More information about the libvir-list mailing list