Results 1 to 10 of 13

Thread: Solving upstream sound issues with DP55WG Motherboard

Hybrid View

  1. #1
    Join Date
    Aug 2005
    Beans
    368

    Solving upstream sound issues with DP55WG Motherboard

    Alsa is the sound subsystem of the Linux kernel.
    Many sound cards do not work out of the box and require us to specify a 'model'. What we can do is add information to the Linux kernel (in Alsa) that our sound card follows a specific model. It is quite elemental, and we just need to add a single line to the kernel source.

    Let's try out with the sound card of the DP55WG motherboard.
    We will be a bit pedantic so that others may replicate with their own hardware.

    bdudek writes:
    Code:
    Ubuntu 10.10 x86_64
    Intel DP55WG Motherboard
    
    aplay -l
    card 0: Intel [HDA Intel], device 0: ALC889 Analog [ALC889 Analog]
    Subdevices: 1/1
    Subdevice #0: subdevice #0
    card 0: Intel [HDA Intel], device 1: ALC889 Digital [ALC889 Digital]
    Subdevices: 1/1
    Subdevice #0: subdevice #0
    
    
    /etc/modprobe.d/alsa-base.conf
    options snd-hda-intel model=6stack-dig
    
    Works fine. You can select either Analog or Digital SPDIF from the Hardware Tab in Sound Preferences.
    What we know now is that the sound card uses the ALC889 codec, and we already tried and found that the model should be '6stack-dig'.

    The relevant file in the Linux kernel is
    http://git.alsa-project.org/?p=alsa-...ltek.c;hb=HEAD

    and we need to add somewhere a line that looks like

    Code:
    SND_PCI_QUIRK(0x103c, 0x2a09, "HP", ALC880_5ST),
    at the proper place. The value for the two hex numbers will come from 'alsa-info.sh'.

    bdudek, can you run on your system

    Code:
    wget www.alsa-project.org/alsa-info.sh -O alsa-info.sh && bash ./alsa-info.sh
    This extracts your sound card details, along with the PCI/SUBSYSTEM IDs. These are the numbers that we put in that SND_PCI_QUIRK() line above.
    The alsa-info.sh command has an option to send the details to alsa-project.org and publish a public URL. You can send the URL here.

    Once we have the PCI/SUBSYSTEM IDs, we can make the one-line patch, and test it with the latest Alsa (and removing the model= hint from the alsa configuration file). If sound works fine, we submit the patch.

  2. #2
    Join Date
    May 2008
    Location
    USA
    Beans
    13
    Distro
    Ubuntu 11.04 Natty Narwhal

    Re: Solving upstream sound issues with DP55WG Motherboard

    I have uploaded the output to http://www.alsa-project.org/db/?f=79...197f93631b8609 I have 2 minor problems. The first is the levels seem to be too high on the spdif output. I always have to adjust them down a bit. The second is when switching from analogue to spdif both are active for one or two uses of the sound system. An example would be, open gnome file manager and place your mouse over an MP3 file right after changing from analogue to spdif. You will get sound from both the analogue output as well as the spdif output when rhythmbox does it's preview. Move the mouse off the file and then back onto the file again and then the analogue output will turn off. This is repeatable and can take one or two cycles for it to happen. The same happens when going back to analogue from spdif.
    Last edited by bdudek; December 8th, 2010 at 11:46 AM.

  3. #3
    Join Date
    Aug 2005
    Beans
    368

    Re: Solving upstream sound issues with DP55WG Motherboard

    Quote Originally Posted by bdudek View Post
    I have uploaded the output to http://www.alsa-project.org/db/?f=79...197f93631b8609 I have 2 minor problems. The first is the levels seem to be too high on the spdif output. I always have to adjust them down a bit. The second is when switching from analogue to spdif both are active for one or two uses of the sound system. An example would be, open gnome file manager and place your mouse over an MP3 file right after changing from analogue to spdif. You will get sound from both the analogue output as well as the spdif output when rhythmbox does it's preview. Move the mouse off the file and then back onto the file again and then the analogue output will turn off. This is repeatable and can take one or two cycles for it to happen. The same happens when going back to analogue from spdif.
    Regarding the SPDIF output level, could this be an issue with the default output level of the device (i.e. TV or sound system)?
    You can dig a bit deeper here if you try the HDA Analyser,
    http://www.alsa-project.org/main/index.php/HDA_Analyzer
    You give it as input the output of 'alsa-info.sh'. If you run it with 'sudo', then you can change values from the 'pins', such as decibel levels.

    The second issue probably refers to a bug or feature in Pulseaudio or even Nautilus. Pulseaudio is a higher layer over Alsa, and there might be some caching involved within Nautilus (file manager).

    Reading the alsa-info.sh output, it shows that you have two main audio cards, the one embedded on the motherboard (Intel) and the one from the NVidia card. I assume you try to get the motherboard sound card to work.
    It looks that both your motherboard sound card and the sound card from NVidia have digital outputs. Verify that you use the motherboard digital output.

    There is a concern, with '[ 14.828401] hda_codec: ALC889: SKU not ready 0x411111f0'. Google shows several recent hits on this. Since your system is working, we can bypass this.

    Alsa-info.sh says that your vendor ID for the m/b sound card is '10ec0889'.

    Now, when you read
    http://git.alsa-project.org/?p=alsa-...ltek.c;hb=HEAD
    there are references to 10ec0889, and there is a line for
    Code:
        { .id = 0x10ec0889, .name = "ALC889", .patch = patch_alc882 },
    which means that when you select 'model=auto' (or do not specify a model line), this is the default setting. And is wrong for you.

    So, could you please change 'model=6stack-dig' to 'model=auto', reboot, and retrieve a new (the original) alsa-info.sh; This will be useful to compare what's going on.

  4. #4
    Join Date
    May 2008
    Location
    USA
    Beans
    13
    Distro
    Ubuntu 11.04 Natty Narwhal

    Re: Solving upstream sound issues with DP55WG Motherboard

    I made the change to /etc/modprobe.d/alsa-base.conf. The last line is now "options snd-hda-intel model=auto". Tried a sound file with no success on either analogue or SPDIF. Then I ran the alsa-info.sh command line that you provided and the information you requested is at http://www.alsa-project.org/db/?f=3b...f88e1c876f184f

    You also mention the NVidia Sound cards. I have a EVGA 01G-P3-1465-AR GeForce GTX 465 (Fermi) 1GB 256-bit GDDR5 PCI Express 2.0 x16 HDCP Ready SLI Support video card. It has 2 DVI-I and one HDMI out. I don't remember off hand what connectors were on the board itself.

    I do plan to try the HDA Analyser next. Another side note is that I have not checked to make sure that my BIOS is up to date. If you think that could also be an issue I will pursue.

    I checked the output of the alsa-info.sh and found one big difference in the outputs displayed below:

    6stack-dig
    =============

    Node 0x06 [Audio Output] wcaps 0x211: Stereo Digital
    Control: name="IEC958 Playback Con Mask", index=0, device=0
    Control: name="IEC958 Playback Pro Mask", index=0, device=0
    Control: name="IEC958 Playback Default", index=0, device=0
    Control: name="IEC958 Playback Switch", index=0, device=0
    Control: name="IEC958 Default PCM Playback Switch", index=0, device=0
    Device: name="ALC889 Digital", type="SPDIF", device=1
    Converter: stream=0, channel=0
    Digital:
    Digital category: 0x0
    PCM:
    rates [0x5f0]: 32000 44100 48000 88200 96000 192000
    bits [0xe]: 16 20 24
    formats [0x1]: PCM


    auto
    =============

    Node 0x06 [Audio Output] wcaps 0x211: Stereo Digital
    Converter: stream=0, channel=0
    Digital: Enabled
    Digital category: 0x0
    PCM:
    rates [0x5f0]: 32000 44100 48000 88200 96000 192000
    bits [0xe]: 16 20 24
    formats [0x1]: PCM
    Last edited by bdudek; December 8th, 2010 at 07:14 PM. Reason: More data

  5. #5
    Join Date
    Aug 2005
    Beans
    368

    Re: Solving upstream sound issues with DP55WG Motherboard

    Regarding the NVidia, the HDMI output carries audio, and Linux uses Alsa to perform the audio output. ATI and NVidia have a feature to support output of audio through the DVI port, when connected to the HDMI input of a device (such as a TV).

    Back to the motherboard sound card. The following patch performs the 'model=6stack-dig' setting,

    Code:
    diff --git a/alsa-kernel/pci/hda/patch_realtek.c b/alsa-kernel/pci/hda/patch_rea
    index cd2d3a5..ad137d7 100644
    --- a/alsa-kernel/pci/hda/patch_realtek.c
    +++ b/alsa-kernel/pci/hda/patch_realtek.c
    @@ -9833,6 +9833,7 @@ static struct snd_pci_quirk alc882_cfg_tbl[] = {
            SND_PCI_QUIRK(0x1071, 0x8227, "Mitac 82801H", ALC883_MITAC),
            SND_PCI_QUIRK(0x1071, 0x8253, "Mitac 8252d", ALC883_MITAC),
            SND_PCI_QUIRK(0x1071, 0x8258, "Evesham Voyaeger", ALC883_LAPTOP_EAPD),
    +       SND_PCI_QUIRK(0x10ec, 0x0889, "Intel DP55WG", ALC882_6ST_DIG),
            SND_PCI_QUIRK(0x10f1, 0x2350, "TYAN-S2350", ALC888_6ST_DELL),
            SND_PCI_QUIRK(0x108e, 0x534d, NULL, ALC883_3ST_6ch),
            SND_PCI_QUIRK(0x1458, 0xa002, "Gigabyte P35 DS3R", ALC882_6ST_DIG),
    What you do,
    1. Grab the latest Alsa snapshot from http://ftp.kernel.org/pub/linux/kern...apshot.tar.bz2
    These are daily snapshots.
    2. Expand it (tar xvfj ...) and apply the patch above.
    You can use 'patch' to apply the patch, or you can find the source file and add the line yourself. This is simple.
    3. Compile this Alsa snapshot and install. Use './configure', 'make', and finally 'make install'. You might need to install some development packages. You get a hint as to what is missing from the error messages.
    Since your system has Alsa 1.2.23, it is OK to update the 'alsa-driver' only and keep the system alsa-lib and alsa-utils.
    4. You need to restore the model (either change to 'model=auto' or just comment out the line).
    5. Restart the computer.

    Sound should work. In any case, get a fresh alsa-info.sh output for comparisons. If all go well, the final step is to submit to the Linux kernel.

    If you want to remove this snapshot Alsa from your system, you can reinstall the kernel package, using Synaptic Package Manager.

  6. #6
    Join Date
    May 2008
    Location
    USA
    Beans
    13
    Distro
    Ubuntu 11.04 Natty Narwhal

    Re: Solving upstream sound issues with DP55WG Motherboard

    I copied and pasted the patch above into a file named DP55WG.patch. Then tried to apply the patch. I was unable to apply the patch and received this error:

    $ patch --verbose < DP55WG.patch
    Hmm... Looks like a unified diff to me...
    The text leading up to this was:
    --------------------------
    |diff --git a/alsa-kernel/pci/hda/patch_realtek.c b/alsa-kernel/pci/hda/patch_rea
    |index cd2d3a5..ad137d7 100644
    |--- a/alsa-kernel/pci/hda/patch_realtek.c
    |+++ b/alsa-kernel/pci/hda/patch_realtek.c
    --------------------------
    Patching file patch_realtek.c using Plan A...
    Hunk #1 FAILED at 9833.
    1 out of 1 hunk FAILED -- saving rejects to file patch_realtek.c.rej
    done



    So I applied it manually. Here is what the patch_realtek.c looks like now:

    9834 SND_PCI_QUIRK(0x1071, 0x8253, "Mitac 8252d", ALC883_MITAC),
    9835 SND_PCI_QUIRK(0x1071, 0x8258, "Evesham Voyaeger", ALC883_LAPTOP_EAPD),
    9836 SND_PCI_QUIRK(0x10ec, 0x0889, "Intel DP55WG", ALC882_6ST_DIG),
    9837 SND_PCI_QUIRK(0x10f1, 0x2350, "TYAN-S2350", ALC888_6ST_DELL),
    9838 SND_PCI_QUIRK(0x108e, 0x534d, NULL, ALC883_3ST_6ch),
    9839 SND_PCI_QUIRK(0x1458, 0xa002, "Gigabyte P35 DS3R", ALC882_6ST_DIG),


    Did the "./configure" then the "make"

    I get the message: ALSA modules were successfully compiled.

    and then "sudo make install" and get this warning:

    WARNING!!! The mixer channels for the ALSA driver are muted by default!!!
    ************************************************** ************************
    You would use some ALSA or OSS mixer to set the appropriate volume.


    I commented out the "options snd-hda-intel model=auto" line then rebooted the machine. Now I have no sound cards at all. I run an "aplay -l" for a quick check and here is the output:

    $ aplay -l
    aplay: device_list:235: no soundcards found...
    $

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •