Statistics
| Branch: | Revision:

root / hw / ac97.c @ 43997225

History | View | Annotate | Download (36.8 kB)

# Date Author Comment
5b723926 04/17/2012 03:57 pm Marc-André Lureau

hw/ac97: the volume mask is not only 0x1f

It's a case by case (see Table 66. AC ?97 Baseline Audio Register Map)

Signed-off-by: Marc-Andr? Lureau <>
Signed-off-by: malc <>

19677a38 04/17/2012 03:57 pm Marc-André Lureau

hw/ac97: add support for volume control

Combine output volume with Master and PCM registers values.
Use default values in mixer_reset ().
Set volume on post-load to update backend values.

v4,v5:
- fix some code style

Signed-off-by: Marc-Andr? Lureau <>...

ed2997cd 04/17/2012 03:57 pm Marc-André Lureau

hw/ac97: remove USE_MIXER code

That code doesn't compile. The interesting bits for volume control are
going to be rewritten in the following patch.

Signed-off-by: Marc-Andr? Lureau <>
Signed-off-by: malc <>

83f7d43a 02/15/2012 05:39 pm Andreas Färber

qom: Unify type registration

Replace device_init() with generalized type_init().

While at it, unify naming convention: type_init([$prefix_]register_types)
Also, type_init() is a function, so add preceding blank line where
necessary and don't put a semicolon after the closing brace....

cf4dc461 02/07/2012 08:11 pm malc

Restore consistent formatting

Signed-off-by: malc <>

39bffca2 02/03/2012 06:41 pm Anthony Liguori

qdev: register all types natively through QEMU Object Model

This was done in a mostly automated fashion. I did it in three steps and then
rebased it into a single step which avoids repeatedly touching every file in
the tree.

The first step was a sed-based addition of the parent type to the subclass...

40021f08 01/27/2012 06:50 pm Anthony Liguori

pci: convert to QEMU Object Model

Signed-off-by: Anthony Liguori <>

6b620ca3 01/13/2012 06:55 pm Paolo Bonzini

prepare for future GPLv2+ relicensing

All files under GPLv2 will get GPLv2+ changes starting tomorrow.
event_notifier.c and exec-obsolete.h were only ever touched by Red Hat
employees and can be relicensed now.

Signed-off-by: Paolo Bonzini <>...

25a21c94 11/07/2011 06:57 pm Gerd Hoffmann

ac97: don't override the pci subsystem id

This patch removes the code lines which set the subsystem id for the
emulated ac97 card to 8086:0000. Due to the device id being zero the
subsystem id isn't vaild anyway. With the patch applied the sound card
gets the default qemu subsystem id (1af4:1100) instead....

93f43c48 11/01/2011 11:52 pm Eduard - Gabriel Munteanu

ac97: Use PCI DMA stub functions

This updates the ac97 device emulation to use the explicit PCI DMA
functions, instead of directly calling physical memory access functions.

Signed-off-by: Eduard - Gabriel Munteanu <>
Signed-off-by: David Gibson <>...

817e0b6f 09/19/2011 09:22 pm Michael S. Tsirkin

pci: interrupt pin documentation update

Fix up some erroneous comments in code:
interrupt pins are named A-D, the
interrupt pin register is always readonly
and isn't zeroed out on reset.

Signed-off-by: Michael S. Tsirkin <>

e824b2cc 08/08/2011 06:22 pm Avi Kivity

pci: rename pci_register_bar_region() to pci_register_bar()

Reviewed-by: Richard Henderson <>
Reviewed-by: Anthony Liguori <>
Signed-off-by: Avi Kivity <>
Signed-off-by: Anthony Liguori <>

83c406d9 08/08/2011 06:15 pm Avi Kivity

ac97: convert to memory API

fixes BAR sizing as well.

Reviewed-by: Richard Henderson <>
Reviewed-by: Anthony Liguori <>
Signed-off-by: Avi Kivity <>
Signed-off-by: Anthony Liguori <>

befeac45 06/15/2011 06:27 pm Michael S. Tsirkin

Merge remote-tracking branch 'origin/master' into pci

Conflicts:
hw/virtio-pci.c

0647b949 06/12/2011 10:33 am Isaku Yamahata

hw/ac97.c: convert to PCIDeviceInfo to initialize ids

use PCIDeviceInfo to initialize ids.

Signed-off-by: Isaku Yamahata <>
Signed-off-by: Michael S. Tsirkin <>

7ba4cbbf 05/08/2011 12:59 pm Stefan Weil

ac97: Remove unused local variables

cppcheck report:
hw/ac97.c:1004: style:
Variable 'written' is assigned a value that is never used
hw/ac97.c:1072: style:
Variable 'written' is assigned a value that is never used

Signed-off-by: Stefan Weil <>...

b80d4a98 07/11/2010 08:00 pm Isaku Yamahata

pci: don't overwrite multi functio bit in pci header type.

Don't overwrite pci header type.
Otherwise, multi function bit which pci_init_header_type() sets
appropriately is lost.
Anyway PCI_HEADER_TYPE_NORMAL is zero, so it is unnecessary to zero
which is already zero cleared....

4468fb63 12/23/2009 04:35 pm Michael S. Tsirkin

ac97: symbolic names for pci registers

No functional changes. I verified that the generated binary
does not change.

Signed-off-by: Michael S. Tsirkin <>
Acked-by: Juan Quintela <>
Acked-by: Glauber Costa <>

be73cfe2 12/03/2009 06:05 pm Juan Quintela

savevm: Port to qdev.vmsd all devices that have qdev

Signed-off-by: Juan Quintela <>
Signed-off-by: Anthony Liguori <>

a90ffa49 12/03/2009 05:41 pm Juan Quintela

ac97: port to vmstate

Signed-off-by: Juan Quintela <>
Signed-off-by: Anthony Liguori <>

0148d177 12/03/2009 05:41 pm Juan Quintela

ac97: sizeof needs %zd

This change makes DEBUG_AC97 to compile again

Signed-off-by: Juan Quintela <>
Signed-off-by: Anthony Liguori <>

7626f39f 12/03/2009 05:41 pm Juan Quintela

ac97: recalculate active after loadvm

Signed-off-by: Juan Quintela <>
Signed-off-by: Anthony Liguori <>

3b6b2126 12/03/2009 05:41 pm Juan Quintela

ac97: up savevm version and remove active from state

Signed-off-by: Juan Quintela <>
Signed-off-by: Anthony Liguori <>

6e355d90 11/09/2009 04:43 pm Isaku Yamahata

pci: introduce pcibus_t to represent pci bus address/size instead of uint32_t

This patch is preliminary for 64 bit BAR support.
Introduce dedicated type, pcibus_t, to represent pci bus address/size
instead of uint32_t.
Later this type will be changed to uint64_t....

0392a017 11/09/2009 04:43 pm Isaku Yamahata

pci: s/PCI_ADDRESS_SPACE_/PCI_BASE_ADDRESS_SPACE_/ to match pci_regs.h

make constants for pci base address match pci_regs.h by
renaming PCI_ADDRESS_SPACE_xxx to PCI_BASE_ADDRESS_SPACE_xxx.

Signed-off-by: Isaku Yamahata <>
Acked-by: Michael S. Tsirkin <>...

81a322d4 08/28/2009 04:43 am Gerd Hoffmann

qdev: add return value to init() callbacks.

Sorry folks, but it has to be. One more of these invasive qdev patches.

We have a serious design bug in the qdev interface: device init
callbacks can't signal failure because the init() callback has no
return value. This patch fixes it....

10ee2aaa 08/22/2009 12:51 pm Juan Quintela

Remove unneded ac97 indirection accessing its state

Searching for "inspiration" to convert another device to qdev, I got
ac97. Once I understood a bit of qdev, found that ac97 used a not needed
indirection. To protect the unaware, just fixed it.

Later, Juan....

f3519986 07/17/2009 01:28 am Gerd Hoffmann

qdev: es1370+ac97 description

Signed-off-by: Gerd Hoffmann <>
Signed-off-by: Anthony Liguori <>

0c3271c5 07/10/2009 11:32 pm Anthony Liguori

Indent ac97 and es1370 according to audio formatting

For the sake of consistency. I pulled in the wrong patches from Gerd when
he did the qdev conversion.

Signed-off-by: Anthony Liguori <>

d88a76d1 07/09/2009 03:07 pm Gerd Hoffmann

qdev: convert ac97.

Signed-off-by: Gerd Hoffmann <>

a08d4367 06/29/2009 10:18 pm Jan Kiszka

Revert "Introduce reset notifier order"

This reverts commit 8217606e6edb49591b4a6fd5a0d1229cebe470a9 (and
updates later added users of qemu_register_reset), we solved the
problem it originally addressed less invasively.

Signed-off-by: Jan Kiszka <>...

d999f7e0 06/20/2009 04:13 am malc

Restore consistent formatting of audio devices

28c2c264 06/16/2009 11:18 pm Avi Kivity

Rename pci_register_io_region() to pci_register_bar()

This function is used to manage a PCI BAR, so make the more generic
pci_register_io_region() available to other uses.

Signed-off-by: Avi Kivity <>
Signed-off-by: Anthony Liguori <>

8217606e 05/22/2009 06:50 pm Jan Kiszka

Introduce reset notifier order

Add the parameter 'order' to qemu_register_reset and sort callbacks on
registration. On system reset, callbacks with lower order will be
invoked before those with higher order. Update all existing users to the
standard order 0....

1a7dafce 05/14/2009 02:20 am malc

Remove any pretense that there can be more than one AudioState

22d83b14 05/12/2009 02:33 pm Paul Brook

Push AUD_init down to devices

Now we can safely call AUD_init multiple times we can push it down to
individual audio devices, rather than having to pass it from the board
init.

Signed-off-by: Paul Brook <>

6407f373 05/03/2009 10:03 pm Isaku Yamahata

use PCI_HEADER_TYPE.

use symbolic value instead of 0x0e and related value.

Signed-off-by: Isaku Yamahata <>

173a543b 02/01/2009 09:26 pm blueswir1

Add and use #defines for PCI device classes

This patch adds and uses #defines for PCI device classes and subclases,
using a new pci_config_set_class() function, similar to the recently
added pci_config_set_vendor_id() and pci_config_set_device_id().

Change since v1: fixed compilation of hw/sun4u.c...

deb54399 01/26/2009 05:37 pm aliguori

Define PCI vendor and device IDs in pci.h (Stuart Brady)

This patch defines PCI vendor and device IDs in pci.h (matching those
from Linux's pci_ids.h), and uses those definitions where appropriate.

Change from v1:
Introduces pci_config_set_vendor_id() / pci_config_set_device_id()...

b1503cda 12/22/2008 10:33 pm malc

Use the ARRAY_SIZE() macro where appropriate.

Change from v1:
Avoid changing the existing coding style in certain files.

Signed-off-by: Stuart Brady <>

git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@6120 c046a42c-6fe2-441c-8c8c-71466251a162

1ea879e5 12/04/2008 12:48 am malc

Make audio violate POSIX less

git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@5864 c046a42c-6fe2-441c-8c8c-71466251a162

279a6544 06/21/2008 08:14 pm malc

Add calls to pci_device_save/load

git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@4766 c046a42c-6fe2-441c-8c8c-71466251a162

2c44375d 06/08/2008 04:07 am malc

Do not scare users with ominous error messages from AUD_open*

Apparently Windows Server 2003 sets the frequency for either mc or pi
voice to zero, which in turn triggers a call to audio_bug from this
chain:

open_voice -> AUD_open_in -> audio_bug (audio_validate_settings):...

e5c9a13e 01/14/2008 06:27 am balrog

PCI AC97 emulation by malc.

git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@3918 c046a42c-6fe2-441c-8c8c-71466251a162