LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Hardware (http://www.linuxquestions.org/questions/linux-hardware-18/)
-   -   Ignoring a USB sound card (http://www.linuxquestions.org/questions/linux-hardware-18/ignoring-a-usb-sound-card-4175435708/)

hunternet93 11-05-2012 07:07 AM

Ignoring a USB sound card
 
I'm trying to find a way to ignore a specific USB audio device that is inbuilt into my laptop. The device is an HP Wireless Audio adapter that causes the snd-usb-audio driver to hang when modprobe'd. I tried some udev rules but have been unable to figure out the proper way to do this. If I blacklist the snd-usb-audio driver, other devices using the same driver such as my USB MIDI controller stop working. I'm running Linux Mint Debian Edition on an HP Envy 15.

malekmustaq 11-05-2012 09:34 AM

This is quite difficult unless maybe if you will furnish us more data. Certainly the most practical way is

> to DISABLE the hardware device from the BIOS/EFI level --this should eliminate the problem completely. If this is not possible there (I am not familiar of HP Envy 15) then

> the ultimate work should be played in the userspace by writing the udev rules correctly --the latter there are those capable of doing that.

Meantime please post to us the output of initial queries lspci and lsusb -v.

Also inform us if you were able (or not able) to disable the device from the BIOS.

What you have with this output?

Code:

--# lsmod | grep snd
and this

Code:

--# udevadm info -a -p  $(udevadm info -q path -n /dev/audio)
I think if you cannot disable that wireless device you can map it into your default to avoid contention of resources.

hunternet93 11-05-2012 10:29 AM

lsusb:
Code:

Bus 004 Device 003: ID 0424:b832 Standard Microsystems Corp.
lsmod | grep snd
Code:

snd_hda_codec_hdmi    30998  1
snd_hda_codec_idt      53749  1
snd_hda_intel          26458  3
snd_hda_codec          83083  3 snd_hda_codec_hdmi,snd_hda_codec_idt,snd_hda_intel
snd_usb_audio          93349  0
snd_pcm_oss            37079  0
snd_mixer_oss          18035  1 snd_pcm_oss
snd_usbmidi_lib        23388  1 snd_usb_audio
snd_hwdep              13189  2 snd_usb_audio,snd_hda_codec
snd_pcm                64168  5 snd_pcm_oss,snd_usb_audio,snd_hda_codec_hdmi,snd_hda_codec,snd_hda_intel
snd_page_alloc        12969  2 snd_pcm,snd_hda_intel
snd_seq_midi          12848  0
snd_seq_midi_event    13316  1 snd_seq_midi
snd_rawmidi            23034  2 snd_usbmidi_lib,snd_seq_midi
snd_seq                45192  2 snd_seq_midi_event,snd_seq_midi
snd_timer              22812  2 snd_pcm,snd_seq
snd_seq_device        13176  3 snd_seq,snd_rawmidi,snd_seq_midi
snd                    53038  20 snd_pcm_oss,snd_usb_audio,snd_hwdep,snd_timer,snd_hda_codec_hdmi,snd_hda_codec_idt,snd_pcm,snd_seq,snd_rawmidi,snd_usbmidi_lib,snd_hda_codec,snd_hda_intel,snd_seq_device,snd_mixer_oss
soundcore              13026  1 snd
usbcore              129466  6 btusb,snd_usb_audio,snd_usbmidi_lib,ehci_hcd,usbhid,xhci_hcd

sudo udevadm info -a -p /devices/pci0000:00/0000:00:1d.0/usb4/4-1/4-1.5/4-1.5:1.0/sound/card0/audio
Code:

  looking at device '/devices/pci0000:00/0000:00:1d.0/usb4/4-1/4-1.5/4-1.5:1.0/sound/card0/audio':
    KERNEL=="audio"
    SUBSYSTEM=="sound"
    DRIVER==""

  looking at parent device '/devices/pci0000:00/0000:00:1d.0/usb4/4-1/4-1.5/4-1.5:1.0/sound/card0':
    KERNELS=="card0"
    SUBSYSTEMS=="sound"
    DRIVERS==""
    ATTRS{id}=="Adapter"
    ATTRS{number}=="0"

  looking at parent device '/devices/pci0000:00/0000:00:1d.0/usb4/4-1/4-1.5/4-1.5:1.0':
    KERNELS=="4-1.5:1.0"
    SUBSYSTEMS=="usb"
    DRIVERS=="snd-usb-audio"
    ATTRS{bInterfaceClass}=="01"
    ATTRS{bInterfaceSubClass}=="01"
    ATTRS{bInterfaceProtocol}=="00"
    ATTRS{bNumEndpoints}=="00"
    ATTRS{supports_autosuspend}=="1"
    ATTRS{bAlternateSetting}==" 0"
    ATTRS{bInterfaceNumber}=="00"
    ATTRS{interface}=="HP Wireless Audio Adapter"

  looking at parent device '/devices/pci0000:00/0000:00:1d.0/usb4/4-1/4-1.5':
    KERNELS=="4-1.5"
    SUBSYSTEMS=="usb"
    DRIVERS=="usb"
    ATTRS{bDeviceSubClass}=="00"
    ATTRS{bDeviceProtocol}=="00"
    ATTRS{devpath}=="1.5"
    ATTRS{idVendor}=="0424"
    ATTRS{speed}=="480"
    ATTRS{bNumInterfaces}==" 4"
    ATTRS{bConfigurationValue}=="1"
    ATTRS{bMaxPacketSize0}=="64"
    ATTRS{busnum}=="4"
    ATTRS{devnum}=="3"
    ATTRS{configuration}==""
    ATTRS{bMaxPower}=="500mA"
    ATTRS{authorized}=="1"
    ATTRS{bmAttributes}=="80"
    ATTRS{bNumConfigurations}=="1"
    ATTRS{maxchild}=="0"
    ATTRS{bcdDevice}=="7528"
    ATTRS{avoid_reset_quirk}=="0"
    ATTRS{quirks}=="0x0"
    ATTRS{version}==" 2.00"
    ATTRS{urbnum}=="34123"
    ATTRS{ltm_capable}=="no"
    ATTRS{manufacturer}=="Standard Microsystems Corp."
    ATTRS{removable}=="fixed"
    ATTRS{idProduct}=="b832"
    ATTRS{bDeviceClass}=="00"
    ATTRS{product}=="HP Wireless Audio Adapter"

  looking at parent device '/devices/pci0000:00/0000:00:1d.0/usb4/4-1':
    KERNELS=="4-1"
    SUBSYSTEMS=="usb"
    DRIVERS=="usb"
    ATTRS{bDeviceSubClass}=="00"
    ATTRS{bDeviceProtocol}=="01"
    ATTRS{devpath}=="1"
    ATTRS{idVendor}=="8087"
    ATTRS{speed}=="480"
    ATTRS{bNumInterfaces}==" 1"
    ATTRS{bConfigurationValue}=="1"
    ATTRS{bMaxPacketSize0}=="64"
    ATTRS{busnum}=="4"
    ATTRS{devnum}=="2"
    ATTRS{configuration}==""
    ATTRS{bMaxPower}=="  0mA"
    ATTRS{authorized}=="1"
    ATTRS{bmAttributes}=="e0"
    ATTRS{bNumConfigurations}=="1"
    ATTRS{maxchild}=="6"
    ATTRS{bcdDevice}=="0000"
    ATTRS{avoid_reset_quirk}=="0"
    ATTRS{quirks}=="0x0"
    ATTRS{version}==" 2.00"
    ATTRS{urbnum}=="158"
    ATTRS{ltm_capable}=="no"
    ATTRS{removable}=="fixed"
    ATTRS{idProduct}=="0024"
    ATTRS{bDeviceClass}=="09"

  looking at parent device '/devices/pci0000:00/0000:00:1d.0/usb4':
    KERNELS=="usb4"
    SUBSYSTEMS=="usb"
    DRIVERS=="usb"
    ATTRS{bDeviceSubClass}=="00"
    ATTRS{bDeviceProtocol}=="00"
    ATTRS{devpath}=="0"
    ATTRS{idVendor}=="1d6b"
    ATTRS{speed}=="480"
    ATTRS{bNumInterfaces}==" 1"
    ATTRS{bConfigurationValue}=="1"
    ATTRS{bMaxPacketSize0}=="64"
    ATTRS{authorized_default}=="1"
    ATTRS{busnum}=="4"
    ATTRS{devnum}=="1"
    ATTRS{configuration}==""
    ATTRS{bMaxPower}=="  0mA"
    ATTRS{authorized}=="1"
    ATTRS{bmAttributes}=="e0"
    ATTRS{bNumConfigurations}=="1"
    ATTRS{maxchild}=="2"
    ATTRS{bcdDevice}=="0306"
    ATTRS{avoid_reset_quirk}=="0"
    ATTRS{quirks}=="0x0"
    ATTRS{serial}=="0000:00:1d.0"
    ATTRS{version}==" 2.00"
    ATTRS{urbnum}=="48"
    ATTRS{ltm_capable}=="no"
    ATTRS{manufacturer}=="Linux 3.6.2 ehci_hcd"
    ATTRS{removable}=="unknown"
    ATTRS{idProduct}=="0002"
    ATTRS{bDeviceClass}=="09"
    ATTRS{product}=="EHCI Host Controller"

  looking at parent device '/devices/pci0000:00/0000:00:1d.0':
    KERNELS=="0000:00:1d.0"
    SUBSYSTEMS=="pci"
    DRIVERS=="ehci_hcd"
    ATTRS{irq}=="20"
    ATTRS{subsystem_vendor}=="0x103c"
    ATTRS{broken_parity_status}=="0"
    ATTRS{class}=="0x0c0320"
    ATTRS{companion}==""
    ATTRS{consistent_dma_mask_bits}=="32"
    ATTRS{dma_mask_bits}=="32"
    ATTRS{local_cpus}=="00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,000000ff"
    ATTRS{device}=="0x1c26"
    ATTRS{uframe_periodic_max}=="100"
    ATTRS{enable}=="1"
    ATTRS{msi_bus}==""
    ATTRS{local_cpulist}=="0-7"
    ATTRS{vendor}=="0x8086"
    ATTRS{subsystem_device}=="0x1688"
    ATTRS{numa_node}=="-1"
    ATTRS{d3cold_allowed}=="1"

  looking at parent device '/devices/pci0000:00':
    KERNELS=="pci0000:00"
    SUBSYSTEMS==""
    DRIVERS==""

No luck on disabling it from BIOS.

The exact issue: when alsamixer, pulseaudio, jack, or any other sound program attempts to use the wireless audio card, it hangs and must be kill -9'ed. I get a flood of messages like
Code:

[10132.292432] 3:1:1: cannot set freq 44100 to ep 0x1
in dmesg. I'm guessing the card expects special configuration from snd-usb-audio, resulting in the hang. I'd like to find a way to disable or ignore the card with extreme prejudice. I'd scrape the chip off the motherboard if it would help. :D

SwellJoe 12-08-2012 09:42 PM

Have you made any progress on this issue, hunternet93?

I'm running into the issue as well; disabling snd-usb-audio via blacklist allows the system to function, but I can't use an external sound device. I posted to the alsa-sound mailing list about the bug, but haven't heard any response, so I don't have high hopes that it will get fixed soon.

hunternet93 12-09-2012 12:29 PM

Quote:

Originally Posted by SwellJoe (Post 4845467)
Have you made any progress on this issue, hunternet93?

I'm running into the issue as well; disabling snd-usb-audio via blacklist allows the system to function, but I can't use an external sound device. I posted to the alsa-sound mailing list about the bug, but haven't heard any response, so I don't have high hopes that it will get fixed soon.

Sadly, no. I'll take another look at the problem, I believe udev is the answer but I haven't figured out the right rule to use.

SwellJoe 12-10-2012 12:42 AM

I started a thread on alsa-devel, at the recommendation of someone on the Fedora bug tracker. I've heard back from a developer, who plans to try to help come up with a temporary solution to disable the problem hardware. That solution hasn't been forthcoming yet, but you can follow that thread on the alsa-devel mailing list archive, here:

http://mailman.alsa-project.org/pipe...er/057729.html

hunternet93 12-11-2012 10:30 PM

Eldad Zack on the alsa-devel mailing list found the solution: [url]http://mailman.alsa-project.org/pipermail/alsa-devel/2012-December/057828.html[url]. It involves patching the kernel, which isn't as hard as it sounds if you haven't done it before. I can provide instructions if necessary.
The patch tells the snd-usb-audio driver to ignore the HP Wireless Audio device, which prevents the hang. I just tested and am able to play sound through a USB audio card without problems. Good luck!


All times are GMT -5. The time now is 03:09 PM.