PCI quirks with via82xx soundcard / sysfs paths
Hi,
I'm trying to get a via82xx onboard soundcard working in a domU. So far it only works, if I enable permissive mode with:
echo "Y" > /sys/module/pciback/parameters/permissive
I still can't hear any sound, but the modules load fine and i can use the alsamixer. (which most likely is unrelated to xen)
I tried to use xend-pci-quirks.sxp, but the python script fails, because there is no /sys/bus/pci/drivers/pciback/quirks.
Adding the card to /sys/bus/pci/drivers/pciback/permissive fails with:
Error: pci: failed to open/write/close permissive sysfs node: [Errno 13] Permission denied: '/sys/bus/pci/drivers/pciback/permissive'
The part of the documentation dealing with pci quirks and permissive seems to be outdated. See user.pdf page 29/30.
The section about binding works perfectly, though.
I'm running debian amd64 with xen hypervisor and utils at version 3.0-unstable+hg11561-1. Two nic ports (dlink 4-port nic) are reassigned to the domU and work fine.
lspci -n gives the following output (11.5 is the soundcard):
00:00.0 0600: 1106:0204
00:00.1 0600: 1106:1204
00:00.2 0600: 1106:2204
00:00.3 0600: 1106:3204
00:00.4 0600: 1106:4204
00:00.7 0600: 1106:7204
00:01.0 0604: 1106:b188
00:07.0 0c00: 1106:3044 (rev 80)
00:0b.0 0604: 8086:b152
00:0c.0 0280: 1397:2bd0 (rev 02)
00:0d.0 0280: 1397:2bd0 (rev 02)
00:0f.0 0101: 1106:3149 (rev 80)
00:0f.1 0101: 1106:0571 (rev 06)
00:10.0 0c03: 1106:3038 (rev 81)
00:10.1 0c03: 1106:3038 (rev 81)
00:10.2 0c03: 1106:3038 (rev 81)
00:10.3 0c03: 1106:3038 (rev 81)
00:10.4 0c03: 1106:3104 (rev 86)
00:11.0 0601: 1106:3227
00:11.5 0401: 1106:3059 (rev 60)
00:11.6 0780: 1106:3068 (rev 80)
00:12.0 0200: 1106:3065 (rev 78)
00:18.0 0600: 1022:1100
00:18.1 0600: 1022:1101
00:18.2 0600: 1022:1102
00:18.3 0600: 1022:1103
01:00.0 0300: 1106:3108 (rev 01)
02:04.0 0200: 1186:1002 (rev 15)
02:05.0 0200: 1186:1002 (rev 15)
02:06.0 0200: 1186:1002 (rev 15)
02:07.0 0200: 1186:1002 (rev 15)
thanks.
mfg
Signature · 1 line
Mario Manno <[email protected]>
Quoted 6 lines · Mario Manno
I'm trying to get a via82xx onboard soundcard working in a domU. So far it only works, if I enable permissive mode with:
echo "Y" >/sys/module/pciback/parameters/permissive
I still can't hear any sound, but the modules load fine and i can use the alsamixer. (which most likely is unrelated to xen)
Quoted 6 lines
I tried to use xend-pci-quirks.sxp, but the python script fails, because there is no
/sys/bus/pci/drivers/pciback/quirks.Adding the card to
/sys/bus/pci/drivers/pciback/permissivefails with:
Error: pci: failed to open/write/close permissive sysfs node: [Errno 13] Permission denied: '/sys/bus/pci/drivers/pciback/permissive'
Current pciback driver does not have the 'permissive' module option. Since yours does, and does not have the replacement 'permissive' and 'quirks' sysfs files, you must be running an out-of-date domain0 kernel (or at least the pciback module is out of date).
Check the build time of your kernel!
-- Keir
Quoted 6 lines · Keir Fraser
Current pciback driver does not have the 'permissive' module option. Since yours does, and does not have the replacement 'permissive' and 'quirks' sysfs files, you must be running an out-of-date domain0 kernel (or at least the pciback module is out of date).
Check the build time of your kernel!
Thanks a lot,
Imho there is something wrong with the debian dependencies of xen-linux-system; kernel xen and hypervisor/utils versions do not match up.
I upgraded to a debian unstable kernel (2.6.18-2) and now i can use /etc/xen/xend-pci-quirks.sxp
I added the following lines to make the hardware work:
(sundance
(pci_ids ('1186:1002'))
(pci_config_space_fields ('00000054:2:00000000'))
)
(snd_via82xx
(pci_ids ('1106:3059'))
(pci_config_space_fields ('000000c4:2:00000000')))
Signature · 1 line
Mario Manno <[email protected]>
Thanks, I'll check this out and add to the file.
K.
Quoted 9 lines · Mario Manno
I added the following lines to make the hardware work:
(sundance(pci_ids ('1186:1002')) (pci_config_space_fields ('00000054:2:00000000')) ) (snd_via82xx (pci_ids ('1106:3059')) (pci_config_space_fields ('000000c4:2:00000000')))
Quoted 8 lines · Mario Manno
(sundance
(pci_ids ('1186:1002')) (pci_config_space_fields ('00000054:2:00000000')) ) (snd_via82xx (pci_ids ('1106:3059')) (pci_config_space_fields ('000000c4:2:00000000')))
I'd like to put a comment by each permitted register to indicate its device-specific purpose. Unfortunately I can't find any reference to these register offsets in the drivers, which is very weird.
What Linux kernel version do these particular drivers come from?
-- Keir
Quoted 11 lines · Keir Fraser
Quoted 8 lines · Mario Manno
(sundance
(pci_ids ('1186:1002')) (pci_config_space_fields ('00000054:2:00000000')) ) (snd_via82xx (pci_ids ('1106:3059')) (pci_config_space_fields ('000000c4:2:00000000')))
Quoted 5 lines
I'd like to put a comment by each permitted register to indicate its device-specific purpose. Unfortunately I can't find any reference to these register offsets in the drivers, which is very weird.
What Linux kernel version do these particular drivers come from?
Well, i added them because the log messages said so... but the addresses indeed differ from my previous setup (same hypervisor, but debian kernel 2.6.17): Sundance didn't need quirks or permissive and vi82xx complained about more addresses.
==============
dom0# cat /proc/version
Linux version 2.6.18-1-xen-amd64 (Debian 2.6.18-2) ([email protected]) (gcc version 4.1.2 20060920 (prerelease) (Debian 4.1.1-14)) #1 SMP Fri
Sep 29 18:28:20 CEST 2006
domU# cat /proc/version
Linux version 2.6.17-2-xen-amd64 (Debian 2.6.17-9) ([email protected]) (gcc version 4.1.2 20060901 (prerelease) (Debian 4.1.1-13)) #1 SMP Wed
Sep 13 18:35:45 CEST 2006
dom0# dpkg -l
ii linux-image-2.6.17-2-xen-amd64 2.6.17-9 ii linux-image-2.6.18-1-xen-amd64 2.6.18-2 ii xen-hypervisor-3.0-unstable 3.0-unstable+hg11561-1
==============
I just upgraded the domU kernel to 2.6.18 and now i need all of the following values for the onboard soundcard:
'000000c4:2:00000000' # ?? '00000041:1:00000000' # VIA_ACLINK_CTRL '00000042:1:00000000' # VIA_FUNC_ENABLE '00000049:1:00000000' # VIA8233_SPDIF_CTRL
But since i don't even get the soundcard working inside dom0, besides mixer, i would drop this issue altogether. Asterisk will do fine without a soundcard anyways.
Sundance however still works with 0x54.
Signature · 1 line
Mario Manno <[email protected]>