[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]

Re: [libvirt] [PATCH] qemu: sound: Support intel 'hda' model



On Mon, Jan 10, 2011 at 12:19:07PM -0500, Cole Robinson wrote:
> In QEMU, the card itself is a PCI device, but it requires
> -device hda-output in order to actually get sound to the host. AIUI this
> is just HDA configuration and does not require stable addressing, so
> is not presently represented in the XML.
> 
> Additionally, qemu supports audio input with '-device hda-duplex', however
> that provides guests access to the host's microphone, so probably isn't
> what we want by default.
> ---
>  docs/formatdomain.html.in                          |    5 +++--
>  docs/schemas/domain.rng                            |    1 +
>  src/conf/domain_conf.c                             |    3 ++-
>  src/conf/domain_conf.h                             |    1 +
>  src/qemu/qemu_command.c                            |   14 +++++++++++++-
>  .../qemuxml2argv-sound-device.args                 |    2 +-
>  .../qemuxml2argvdata/qemuxml2argv-sound-device.xml |    1 +
>  tests/qemuxml2argvdata/qemuxml2argv-sound.args     |    2 +-
>  tests/qemuxml2argvdata/qemuxml2argv-sound.xml      |    1 +
>  9 files changed, 24 insertions(+), 6 deletions(-)
> 
> diff --git a/docs/formatdomain.html.in b/docs/formatdomain.html.in
> index e9fcea1..8c43b74 100644
> --- a/docs/formatdomain.html.in
> +++ b/docs/formatdomain.html.in
> @@ -1663,8 +1663,9 @@ qemu-kvm -net nic,model=? /dev/null
>          The <code>sound</code> element has one mandatory attribute,
>          <code>model</code>, which specifies what real sound device is emulated.
>          Valid values are specific to the underlying hypervisor, though typical
> -        choices are 'es1370', 'sb16', and 'ac97'
> -        (<span class="since">'ac97' only since 0.6.0</span>)
> +        choices are 'es1370', 'sb16', 'ac97', and 'hda'
> +        (<span class="since">
> +         'ac97' only since 0.6.0, 'hda' only since 0.8.8</span>)
>        </dd>
>      </dl>
>  
> diff --git a/docs/schemas/domain.rng b/docs/schemas/domain.rng
> index a524e4b..491a5a5 100644
> --- a/docs/schemas/domain.rng
> +++ b/docs/schemas/domain.rng
> @@ -1489,6 +1489,7 @@
>            <value>es1370</value>
>            <value>pcspk</value>
>            <value>ac97</value>
> +          <value>hda</value>
>          </choice>
>        </attribute>
>        <optional>
> diff --git a/src/conf/domain_conf.c b/src/conf/domain_conf.c
> index c857a89..992435d 100644
> --- a/src/conf/domain_conf.c
> +++ b/src/conf/domain_conf.c
> @@ -225,7 +225,8 @@ VIR_ENUM_IMPL(virDomainSoundModel, VIR_DOMAIN_SOUND_MODEL_LAST,
>                "sb16",
>                "es1370",
>                "pcspk",
> -              "ac97")
> +              "ac97",
> +              "hda")

IIUC, HDA is a generic family of devices, of which QEMU is
only emulating one particular device model - ICH6. If it adds
others (ICH7/8/9/etc) in the future we need to distinguish
them, so I think we should probably call it 'ich6' in the XML,
rather than 'hda'.

Regards,
Daniel


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]