読者です 読者をやめる 読者になる 読者になる

はわわーっ

はわわわわっ

linuxでサウンドを再生したい

linux

メモ。

yomi@ubuntu:~$ sudo aplay -l
**** List of PLAYBACK Hardware Devices ****
card 0: HDMI [HDA Intel HDMI], device 3: HDMI 0 [HDMI 0]
  Subdevices: 1/1
  Subdevice #0: subdevice #0
card 0: HDMI [HDA Intel HDMI], device 7: HDMI 1 [HDMI 1]
  Subdevices: 1/1
  Subdevice #0: subdevice #0
card 0: HDMI [HDA Intel HDMI], device 8: HDMI 2 [HDMI 2]
  Subdevices: 1/1
  Subdevice #0: subdevice #0
card 1: PCH [HDA Intel PCH], device 0: ALC1150 Analog [ALC1150 Analog]
  Subdevices: 1/1
  Subdevice #0: subdevice #0
card 1: PCH [HDA Intel PCH], device 1: ALC1150 Digital [ALC1150 Digital]
  Subdevices: 1/1
  Subdevice #0: subdevice #0
yomi@ubuntu:~$ sudo aplay -L
null
    Discard all samples (playback) or generate zero samples (capture)
hdmi:CARD=HDMI,DEV=0
    HDA Intel HDMI, HDMI 0
    HDMI Audio Output
hdmi:CARD=HDMI,DEV=1
    HDA Intel HDMI, HDMI 1
    HDMI Audio Output
hdmi:CARD=HDMI,DEV=2
    HDA Intel HDMI, HDMI 2
    HDMI Audio Output
dmix:CARD=HDMI,DEV=3
    HDA Intel HDMI, HDMI 0
    Direct sample mixing device
dmix:CARD=HDMI,DEV=7
    HDA Intel HDMI, HDMI 1
    Direct sample mixing device
dmix:CARD=HDMI,DEV=8
    HDA Intel HDMI, HDMI 2
    Direct sample mixing device
dsnoop:CARD=HDMI,DEV=3
    HDA Intel HDMI, HDMI 0
    Direct sample snooping device
dsnoop:CARD=HDMI,DEV=7
    HDA Intel HDMI, HDMI 1
    Direct sample snooping device
dsnoop:CARD=HDMI,DEV=8
    HDA Intel HDMI, HDMI 2
    Direct sample snooping device
hw:CARD=HDMI,DEV=3
    HDA Intel HDMI, HDMI 0
    Direct hardware device without any conversions
hw:CARD=HDMI,DEV=7
    HDA Intel HDMI, HDMI 1
    Direct hardware device without any conversions
hw:CARD=HDMI,DEV=8
    HDA Intel HDMI, HDMI 2
    Direct hardware device without any conversions
plughw:CARD=HDMI,DEV=3
    HDA Intel HDMI, HDMI 0
    Hardware device with all software conversions
plughw:CARD=HDMI,DEV=7
    HDA Intel HDMI, HDMI 1
    Hardware device with all software conversions
plughw:CARD=HDMI,DEV=8
    HDA Intel HDMI, HDMI 2
    Hardware device with all software conversions
default:CARD=PCH
    HDA Intel PCH, ALC1150 Analog
    Default Audio Device
sysdefault:CARD=PCH
    HDA Intel PCH, ALC1150 Analog
    Default Audio Device
front:CARD=PCH,DEV=0
    HDA Intel PCH, ALC1150 Analog
    Front speakers
surround40:CARD=PCH,DEV=0
    HDA Intel PCH, ALC1150 Analog
    4.0 Surround output to Front and Rear speakers
surround41:CARD=PCH,DEV=0
    HDA Intel PCH, ALC1150 Analog
    4.1 Surround output to Front, Rear and Subwoofer speakers
surround50:CARD=PCH,DEV=0
    HDA Intel PCH, ALC1150 Analog
    5.0 Surround output to Front, Center and Rear speakers
surround51:CARD=PCH,DEV=0
    HDA Intel PCH, ALC1150 Analog
    5.1 Surround output to Front, Center, Rear and Subwoofer speakers
surround71:CARD=PCH,DEV=0
    HDA Intel PCH, ALC1150 Analog
    7.1 Surround output to Front, Center, Side, Rear and Woofer speakers
iec958:CARD=PCH,DEV=0
    HDA Intel PCH, ALC1150 Digital
    IEC958 (S/PDIF) Digital Audio Output
dmix:CARD=PCH,DEV=0
    HDA Intel PCH, ALC1150 Analog
    Direct sample mixing device
dmix:CARD=PCH,DEV=1
    HDA Intel PCH, ALC1150 Digital
    Direct sample mixing device
dsnoop:CARD=PCH,DEV=0
    HDA Intel PCH, ALC1150 Analog
    Direct sample snooping device
dsnoop:CARD=PCH,DEV=1
    HDA Intel PCH, ALC1150 Digital
    Direct sample snooping device
hw:CARD=PCH,DEV=0
    HDA Intel PCH, ALC1150 Analog
    Direct hardware device without any conversions
hw:CARD=PCH,DEV=1
    HDA Intel PCH, ALC1150 Digital
    Direct hardware device without any conversions
plughw:CARD=PCH,DEV=0
    HDA Intel PCH, ALC1150 Analog
    Hardware device with all software conversions
plughw:CARD=PCH,DEV=1
    HDA Intel PCH, ALC1150 Digital
    Hardware device with all software conversions
yomi@ubuntu:~$ sudo aplay -D plughw:CARD=HDMI,DEV=8 /usr/share/sounds/alsa/Front_Left.wav 
Playing WAVE '/usr/share/sounds/alsa/Front_Left.wav' : Signed 16 bit Little Endian, Rate 48000 Hz, Mono

これで再生できた。出力はHDMI


同じことをxenのdom0でやると再生できなくなる。
とりあえずstraceしてみた。

yomi@ubuntu:~$ sudo strace -f aplay -D plughw:CARD=HDMI,DEV=8 /usr/share/sounds/alsa/Front_Left.wav 
execve("/usr/bin/aplay", ["aplay", "-D", "plughw:CARD=HDMI,DEV=8", "/usr/share/sounds/alsa/Front_Lef"...], [/* 15 vars */]) = 0
brk(0)                                  = 0x842000
access("/etc/ld.so.nohwcap", F_OK)      = -1 ENOENT (No such file or directory)
mmap(NULL, 8192, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_ANONYMOUS, -1, 0) = 0x7f508ca7f000
access("/etc/ld.so.preload", R_OK)      = -1 ENOENT (No such file or directory)
open("/etc/ld.so.cache", O_RDONLY|O_CLOEXEC) = 3
fstat(3, {st_mode=S_IFREG|0644, st_size=36027, ...}) = 0
mmap(NULL, 36027, PROT_READ, MAP_PRIVATE, 3, 0) = 0x7f508ca76000
close(3)                                = 0
access("/etc/ld.so.nohwcap", F_OK)      = -1 ENOENT (No such file or directory)
open("/lib/x86_64-linux-gnu/librt.so.1", O_RDONLY|O_CLOEXEC) = 3
read(3, "\177ELF\2\1\1\0\0\0\0\0\0\0\0\0\3\0>\0\1\0\0\0P#\0\0\0\0\0\0"..., 832) = 832
fstat(3, {st_mode=S_IFREG|0644, st_size=31792, ...}) = 0
mmap(NULL, 2129016, PROT_READ|PROT_EXEC, MAP_PRIVATE|MAP_DENYWRITE, 3, 0) = 0x7f508c657000
mprotect(0x7f508c65e000, 2093056, PROT_NONE) = 0
mmap(0x7f508c85d000, 8192, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_FIXED|MAP_DENYWRITE, 3, 0x6000) = 0x7f508c85d000
close(3)                                = 0
access("/etc/ld.so.nohwcap", F_OK)      = -1 ENOENT (No such file or directory)
open("/usr/lib/x86_64-linux-gnu/libasound.so.2", O_RDONLY|O_CLOEXEC) = 3
read(3, "\177ELF\2\1\1\0\0\0\0\0\0\0\0\0\3\0>\0\1\0\0\0\200\237\2\0\0\0\0\0"..., 832) = 832
fstat(3, {st_mode=S_IFREG|0644, st_size=982640, ...}) = 0
mmap(NULL, 3078056, PROT_READ|PROT_EXEC, MAP_PRIVATE|MAP_DENYWRITE, 3, 0) = 0x7f508c367000
mprotect(0x7f508c450000, 2093056, PROT_NONE) = 0
mmap(0x7f508c64f000, 32768, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_FIXED|MAP_DENYWRITE, 3, 0xe8000) = 0x7f508c64f000
close(3)                                = 0
access("/etc/ld.so.nohwcap", F_OK)      = -1 ENOENT (No such file or directory)
open("/lib/x86_64-linux-gnu/libpthread.so.0", O_RDONLY|O_CLOEXEC) = 3
read(3, "\177ELF\2\1\1\0\0\0\0\0\0\0\0\0\3\0>\0\1\0\0\0po\0\0\0\0\0\0"..., 832) = 832
fstat(3, {st_mode=S_IFREG|0755, st_size=141574, ...}) = 0
mmap(NULL, 4096, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_ANONYMOUS, -1, 0) = 0x7f508ca75000
mmap(NULL, 2217264, PROT_READ|PROT_EXEC, MAP_PRIVATE|MAP_DENYWRITE, 3, 0) = 0x7f508c149000
mprotect(0x7f508c162000, 2093056, PROT_NONE) = 0
mmap(0x7f508c361000, 8192, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_FIXED|MAP_DENYWRITE, 3, 0x18000) = 0x7f508c361000
mmap(0x7f508c363000, 13616, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_FIXED|MAP_ANONYMOUS, -1, 0) = 0x7f508c363000
close(3)                                = 0
access("/etc/ld.so.nohwcap", F_OK)      = -1 ENOENT (No such file or directory)
open("/lib/x86_64-linux-gnu/libc.so.6", O_RDONLY|O_CLOEXEC) = 3
read(3, "\177ELF\2\1\1\0\0\0\0\0\0\0\0\0\3\0>\0\1\0\0\0\320\37\2\0\0\0\0\0"..., 832) = 832
fstat(3, {st_mode=S_IFREG|0755, st_size=1845024, ...}) = 0
mmap(NULL, 3953344, PROT_READ|PROT_EXEC, MAP_PRIVATE|MAP_DENYWRITE, 3, 0) = 0x7f508bd83000
mprotect(0x7f508bf3e000, 2097152, PROT_NONE) = 0
mmap(0x7f508c13e000, 24576, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_FIXED|MAP_DENYWRITE, 3, 0x1bb000) = 0x7f508c13e000
mmap(0x7f508c144000, 17088, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_FIXED|MAP_ANONYMOUS, -1, 0) = 0x7f508c144000
close(3)                                = 0
access("/etc/ld.so.nohwcap", F_OK)      = -1 ENOENT (No such file or directory)
open("/lib/x86_64-linux-gnu/libm.so.6", O_RDONLY|O_CLOEXEC) = 3
read(3, "\177ELF\2\1\1\0\0\0\0\0\0\0\0\0\3\0>\0\1\0\0\0\20V\0\0\0\0\0\0"..., 832) = 832
fstat(3, {st_mode=S_IFREG|0644, st_size=1071552, ...}) = 0
mmap(NULL, 3166568, PROT_READ|PROT_EXEC, MAP_PRIVATE|MAP_DENYWRITE, 3, 0) = 0x7f508ba7d000
mprotect(0x7f508bb82000, 2093056, PROT_NONE) = 0
mmap(0x7f508bd81000, 8192, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_FIXED|MAP_DENYWRITE, 3, 0x104000) = 0x7f508bd81000
close(3)                                = 0
access("/etc/ld.so.nohwcap", F_OK)      = -1 ENOENT (No such file or directory)
open("/lib/x86_64-linux-gnu/libdl.so.2", O_RDONLY|O_CLOEXEC) = 3
read(3, "\177ELF\2\1\1\0\0\0\0\0\0\0\0\0\3\0>\0\1\0\0\0\320\16\0\0\0\0\0\0"..., 832) = 832
fstat(3, {st_mode=S_IFREG|0644, st_size=14664, ...}) = 0
mmap(NULL, 4096, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_ANONYMOUS, -1, 0) = 0x7f508ca74000
mmap(NULL, 2109744, PROT_READ|PROT_EXEC, MAP_PRIVATE|MAP_DENYWRITE, 3, 0) = 0x7f508b879000
mprotect(0x7f508b87c000, 2093056, PROT_NONE) = 0
mmap(0x7f508ba7b000, 8192, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_FIXED|MAP_DENYWRITE, 3, 0x2000) = 0x7f508ba7b000
close(3)                                = 0
mmap(NULL, 4096, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_ANONYMOUS, -1, 0) = 0x7f508ca73000
mmap(NULL, 8192, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_ANONYMOUS, -1, 0) = 0x7f508ca71000
arch_prctl(ARCH_SET_FS, 0x7f508ca71740) = 0
mprotect(0x7f508c13e000, 16384, PROT_READ) = 0
mprotect(0x7f508ba7b000, 4096, PROT_READ) = 0
mprotect(0x7f508bd81000, 4096, PROT_READ) = 0
mprotect(0x7f508c361000, 4096, PROT_READ) = 0
mprotect(0x7f508c85d000, 4096, PROT_READ) = 0
mprotect(0x7f508c64f000, 28672, PROT_READ) = 0
mprotect(0x60d000, 4096, PROT_READ)     = 0
mprotect(0x7f508ca81000, 4096, PROT_READ) = 0
munmap(0x7f508ca76000, 36027)           = 0
set_tid_address(0x7f508ca71a10)         = 1491
set_robust_list(0x7f508ca71a20, 24)     = 0
futex(0x7fff5d89e450, FUTEX_WAIT_BITSET_PRIVATE|FUTEX_CLOCK_REALTIME, 1, NULL, 7f508ca71740) = -1 EAGAIN (Resource temporarily unavailable)
rt_sigaction(SIGRTMIN, {0x7f508c14f9f0, [], SA_RESTORER|SA_SIGINFO, 0x7f508c159340}, NULL, 8) = 0
rt_sigaction(SIGRT_1, {0x7f508c14fa80, [], SA_RESTORER|SA_RESTART|SA_SIGINFO, 0x7f508c159340}, NULL, 8) = 0
rt_sigprocmask(SIG_UNBLOCK, [RTMIN RT_1], NULL, 8) = 0
getrlimit(RLIMIT_STACK, {rlim_cur=8192*1024, rlim_max=RLIM64_INFINITY}) = 0
brk(0)                                  = 0x842000
brk(0x863000)                           = 0x863000
open("/usr/lib/locale/locale-archive", O_RDONLY|O_CLOEXEC) = 3
fstat(3, {st_mode=S_IFREG|0644, st_size=2919792, ...}) = 0
mmap(NULL, 2919792, PROT_READ, MAP_PRIVATE, 3, 0) = 0x7f508b5b0000
close(3)                                = 0
ioctl(0, SNDCTL_TMR_TIMEBASE or SNDRV_TIMER_IOCTL_NEXT_DEVICE or TCGETS, {B38400 opost isig icanon echo ...}) = 0
stat("/usr/share/alsa/alsa.conf", {st_mode=S_IFREG|0644, st_size=9182, ...}) = 0
open("/usr/share/alsa/alsa.conf", O_RDONLY) = 3
fstat(3, {st_mode=S_IFREG|0644, st_size=9182, ...}) = 0
mmap(NULL, 4096, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_ANONYMOUS, -1, 0) = 0x7f508ca7e000
read(3, "#\n#  ALSA library configuration "..., 4096) = 4096
read(3, "rgs [ CARD DEV SUBDEV ]\n\t@args.C"..., 4096) = 4096
read(3, "ery.hw {\n\ttype hw\n}\n\ntimer.defau"..., 4096) = 990
read(3, "", 4096)                       = 0
read(3, "", 4096)                       = 0
close(3)                                = 0
munmap(0x7f508ca7e000, 4096)            = 0
futex(0x7f508ba7c0d0, FUTEX_WAKE_PRIVATE, 2147483647) = 0
access("/usr/share/alsa/alsa.conf.d/", R_OK) = 0
stat("/usr/share/alsa/alsa.conf.d/", {st_mode=S_IFDIR|0755, st_size=4096, ...}) = 0
openat(AT_FDCWD, "/usr/share/alsa/alsa.conf.d/", O_RDONLY|O_NONBLOCK|O_DIRECTORY|O_CLOEXEC) = 3
getdents(3, /* 3 entries */, 32768)     = 80
getdents(3, /* 0 entries */, 32768)     = 0
close(3)                                = 0
access("/etc/asound.conf", R_OK)        = -1 ENOENT (No such file or directory)
access("/home/yomi/.asoundrc", R_OK)    = -1 ENOENT (No such file or directory)
open("/dev/snd/controlC0", O_RDONLY|O_CLOEXEC) = 3
fcntl(3, F_SETFD, FD_CLOEXEC)           = 0
ioctl(3, SNDRV_CTL_IOCTL_CARD_INFO or UI_DEV_CREATE, 0x7fff5d89db40) = 0
close(3)                                = 0
open("/dev/snd/controlC0", O_RDWR|O_CLOEXEC) = 3
fcntl(3, F_SETFD, FD_CLOEXEC)           = 0
ioctl(3, SNDRV_CTL_IOCTL_PVERSION or USBDEVFS_CONTROL, 0x7fff5d89dce4) = 0
ioctl(3, SNDRV_CTL_IOCTL_CARD_INFO or UI_DEV_CREATE, 0x7fff5d89dd70) = 0
close(3)                                = 0
open("/dev/snd/controlC0", O_RDWR|O_CLOEXEC) = 3
fcntl(3, F_SETFD, FD_CLOEXEC)           = 0
ioctl(3, SNDRV_CTL_IOCTL_PVERSION or USBDEVFS_CONTROL, 0x7fff5d89dcd4) = 0
ioctl(3, SNDRV_CTL_IOCTL_PCM_PREFER_SUBDEVICE, 0x7fff5d89dd3c) = 0
open("/dev/snd/pcmC0D8p", O_RDWR|O_NONBLOCK|O_CLOEXEC) = 4
fcntl(4, F_SETFD, FD_CLOEXEC)           = 0
close(3)                                = 0
ioctl(4, AGPIOC_ACQUIRE or APM_IOC_STANDBY or SNDRV_PCM_IOCTL_INFO, 0x7fff5d89dbe0) = 0
fcntl(4, F_GETFL)                       = 0x8802 (flags O_RDWR|O_NONBLOCK|O_LARGEFILE)
ioctl(4, AGPIOC_INFO or SNDRV_PCM_IOCTL_PVERSION, 0x7fff5d89db30) = 0
clock_gettime(CLOCK_MONOTONIC, {239, 864439529}) = 0
ioctl(4, AGPIOC_SETUP or SNDRV_PCM_IOCTL_TTSTAMP, 0x7fff5d89db34) = 0
mmap(NULL, 4096, PROT_READ, MAP_SHARED, 4, 0x80000000) = 0x7f508ca7e000
mmap(NULL, 4096, PROT_READ|PROT_WRITE, MAP_SHARED, 4, 0x81000000) = 0x7f508ca7d000
fcntl(4, F_GETFL)                       = 0x8802 (flags O_RDWR|O_NONBLOCK|O_LARGEFILE)
fcntl(4, F_SETFL, O_RDWR|O_LARGEFILE)   = 0
ioctl(4, AGPIOC_ACQUIRE or APM_IOC_STANDBY or SNDRV_PCM_IOCTL_INFO, 0x7fff5d89e330) = 0
rt_sigaction(SIGINT, {0x40a960, [INT], SA_RESTORER|SA_RESTART, 0x7f508bdb9c30}, {SIG_DFL, [], 0}, 8) = 0
rt_sigaction(SIGTERM, {0x40a960, [TERM], SA_RESTORER|SA_RESTART, 0x7f508bdb9c30}, {SIG_DFL, [], 0}, 8) = 0
rt_sigaction(SIGABRT, {0x40a960, [ABRT], SA_RESTORER|SA_RESTART, 0x7f508bdb9c30}, {SIG_DFL, [], 0}, 8) = 0
rt_sigaction(SIGUSR1, {0x409f70, [USR1], SA_RESTORER|SA_RESTART, 0x7f508bdb9c30}, {SIG_DFL, [], 0}, 8) = 0
open("/usr/share/sounds/alsa/Front_Left.wav", O_RDONLY) = 3
read(3, "RIFF(+\2\0WAVEfmt \20\0\0\0\1\0\1\0", 24) = 24
read(3, "\200\273", 2)                  = 2
read(3, "\0\0\0w\1\0\2\0\20\0", 10)     = 10
read(3, "data\4+\2\0", 8)               = 8
open("/usr/share/locale/locale.alias", O_RDONLY|O_CLOEXEC) = 5
fstat(5, {st_mode=S_IFREG|0644, st_size=2570, ...}) = 0
mmap(NULL, 4096, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_ANONYMOUS, -1, 0) = 0x7f508ca7c000
read(5, "# Locale name alias data base.\n#"..., 4096) = 2570
read(5, "", 4096)                       = 0
close(5)                                = 0
munmap(0x7f508ca7c000, 4096)            = 0
open("/usr/share/locale/en_US/LC_MESSAGES/alsa-utils.mo", O_RDONLY) = -1 ENOENT (No such file or directory)
open("/usr/share/locale/en/LC_MESSAGES/alsa-utils.mo", O_RDONLY) = -1 ENOENT (No such file or directory)
open("/usr/share/locale-langpack/en_US/LC_MESSAGES/alsa-utils.mo", O_RDONLY) = -1 ENOENT (No such file or directory)
open("/usr/share/locale-langpack/en/LC_MESSAGES/alsa-utils.mo", O_RDONLY) = -1 ENOENT (No such file or directory)
write(2, "Playing WAVE '/usr/share/sounds/"..., 55Playing WAVE '/usr/share/sounds/alsa/Front_Left.wav' : ) = 55
write(2, "Signed 16 bit Little Endian, ", 29Signed 16 bit Little Endian, ) = 29
write(2, "Rate 48000 Hz, ", 15Rate 48000 Hz, )         = 15
write(2, "Mono", 4Mono)                     = 4
write(2, "\n", 1
)                       = 1
ioctl(4, SNDRV_PCM_IOCTL_HW_REFINE, 0x7fff5d89daf0) = 0
ioctl(4, SNDRV_PCM_IOCTL_HW_REFINE, 0x7fff5d89d720) = 0
ioctl(4, SNDRV_PCM_IOCTL_HW_REFINE, 0x7fff5d89d720) = 0
ioctl(4, SNDRV_PCM_IOCTL_HW_REFINE, 0x7fff5d89daf0) = 0
ioctl(4, SNDRV_PCM_IOCTL_HW_REFINE, 0x7fff5d89d720) = 0
ioctl(4, SNDRV_PCM_IOCTL_HW_REFINE, 0x7fff5d89d720) = 0
ioctl(4, SNDRV_PCM_IOCTL_HW_REFINE, 0x7fff5d89daf0) = 0
ioctl(4, SNDRV_PCM_IOCTL_HW_REFINE, 0x7fff5d89d830) = 0
ioctl(4, SNDRV_PCM_IOCTL_HW_REFINE, 0x7fff5d89d460) = 0
ioctl(4, SNDRV_PCM_IOCTL_HW_REFINE, 0x7fff5d89d460) = 0
ioctl(4, SNDRV_PCM_IOCTL_HW_REFINE, 0x7fff5d89d830) = 0
ioctl(4, SNDRV_PCM_IOCTL_HW_REFINE, 0x7fff5d89d830) = 0
ioctl(4, SNDRV_PCM_IOCTL_HW_REFINE, 0x7fff5d89d460) = 0
ioctl(4, SNDRV_PCM_IOCTL_HW_REFINE, 0x7fff5d89d460) = 0
ioctl(4, SNDRV_PCM_IOCTL_HW_REFINE, 0x7fff5d89d830) = 0
ioctl(4, SNDRV_PCM_IOCTL_HW_REFINE, 0x7fff5d89d830) = 0
ioctl(4, SNDRV_PCM_IOCTL_HW_REFINE, 0x7fff5d89d460) = 0
ioctl(4, SNDRV_PCM_IOCTL_HW_REFINE, 0x7fff5d89d460) = 0
ioctl(4, SNDRV_PCM_IOCTL_HW_REFINE, 0x7fff5d89d830) = 0
ioctl(4, SNDRV_PCM_IOCTL_HW_REFINE, 0x7fff5d89d830) = 0
ioctl(4, SNDRV_PCM_IOCTL_HW_REFINE, 0x7fff5d89d460) = 0
ioctl(4, SNDRV_PCM_IOCTL_HW_REFINE, 0x7fff5d89d460) = 0
ioctl(4, SNDRV_PCM_IOCTL_HW_REFINE, 0x7fff5d89d830) = 0
ioctl(4, SNDRV_PCM_IOCTL_HW_REFINE, 0x7fff5d89d830) = 0
ioctl(4, SNDRV_PCM_IOCTL_HW_REFINE, 0x7fff5d89d460) = 0
ioctl(4, SNDRV_PCM_IOCTL_HW_REFINE, 0x7fff5d89d460) = 0
ioctl(4, SNDRV_PCM_IOCTL_HW_REFINE, 0x7fff5d89d830) = 0
ioctl(4, SNDRV_PCM_IOCTL_HW_REFINE, 0x7fff5d89d300) = 0
ioctl(4, SNDRV_PCM_IOCTL_HW_REFINE, 0x7fff5d89cf30) = 0
ioctl(4, SNDRV_PCM_IOCTL_HW_REFINE, 0x7fff5d89cf30) = 0
ioctl(4, SNDRV_PCM_IOCTL_HW_REFINE, 0x7fff5d89d300) = 0
ioctl(4, SNDRV_PCM_IOCTL_HW_REFINE, 0x7fff5d89d300) = 0
ioctl(4, SNDRV_PCM_IOCTL_HW_REFINE, 0x7fff5d89d300) = 0
ioctl(4, SNDRV_PCM_IOCTL_HW_REFINE, 0x7fff5d89d300) = 0
ioctl(4, SNDRV_PCM_IOCTL_HW_REFINE, 0x7fff5d89d590) = 0
ioctl(4, SNDRV_PCM_IOCTL_HW_REFINE, 0x7fff5d89d590) = 0
ioctl(4, SNDRV_PCM_IOCTL_HW_REFINE, 0x7fff5d89d590) = 0
ioctl(4, SNDRV_PCM_IOCTL_HW_REFINE, 0x7fff5d89d590) = 0
ioctl(4, SNDRV_PCM_IOCTL_HW_REFINE, 0x7fff5d89d590) = 0
ioctl(4, SNDRV_PCM_IOCTL_HW_REFINE, 0x7fff5d89d300) = 0
ioctl(4, SNDRV_PCM_IOCTL_HW_REFINE, 0x7fff5d89d300) = 0
ioctl(4, SNDRV_PCM_IOCTL_HW_REFINE, 0x7fff5d89d300) = 0
ioctl(4, SNDRV_PCM_IOCTL_HW_REFINE, 0x7fff5d89d300) = 0
ioctl(4, SNDRV_PCM_IOCTL_HW_REFINE, 0x7fff5d89d300) = 0
ioctl(4, SNDRV_PCM_IOCTL_HW_REFINE, 0x7fff5d89d300) = 0
ioctl(4, SNDRV_PCM_IOCTL_HW_REFINE, 0x7fff5d89d300) = 0
ioctl(4, SNDRV_PCM_IOCTL_HW_REFINE, 0x7fff5d89d300) = 0
ioctl(4, SNDRV_PCM_IOCTL_HW_REFINE, 0x7fff5d89d300) = 0
ioctl(4, SNDRV_PCM_IOCTL_HW_REFINE, 0x7fff5d89d300) = 0
ioctl(4, SNDRV_PCM_IOCTL_HW_REFINE, 0x7fff5d89d590) = 0
ioctl(4, SNDRV_PCM_IOCTL_HW_REFINE, 0x7fff5d89d590) = 0
ioctl(4, SNDRV_PCM_IOCTL_HW_REFINE, 0x7fff5d89d590) = 0
ioctl(4, SNDRV_PCM_IOCTL_HW_REFINE, 0x7fff5d89d590) = 0
ioctl(4, SNDRV_PCM_IOCTL_HW_REFINE, 0x7fff5d89d590) = 0
ioctl(4, SNDRV_PCM_IOCTL_HW_REFINE, 0x7fff5d89d590) = 0
ioctl(4, SNDRV_PCM_IOCTL_HW_REFINE, 0x7fff5d89d590) = 0
ioctl(4, SNDRV_PCM_IOCTL_HW_REFINE, 0x7fff5d89d590) = 0
ioctl(4, SNDRV_PCM_IOCTL_HW_REFINE, 0x7fff5d89d590) = 0
ioctl(4, SNDRV_PCM_IOCTL_HW_REFINE, 0x7fff5d89d590) = 0
ioctl(4, SNDRV_PCM_IOCTL_HW_REFINE, 0x7fff5d89da10) = 0
ioctl(4, SNDRV_PCM_IOCTL_HW_REFINE, 0x7fff5d89da10) = 0
ioctl(4, SNDRV_PCM_IOCTL_HW_REFINE, 0x7fff5d89da10) = 0
ioctl(4, SNDRV_PCM_IOCTL_HW_REFINE, 0x7fff5d89da10) = 0
ioctl(4, SNDRV_PCM_IOCTL_HW_REFINE, 0x7fff5d89d9e0) = 0
ioctl(4, SNDRV_PCM_IOCTL_HW_REFINE, 0x7fff5d89d9e0) = 0
ioctl(4, SNDRV_PCM_IOCTL_HW_REFINE, 0x7fff5d89d9e0) = 0
ioctl(4, SNDRV_PCM_IOCTL_HW_REFINE, 0x7fff5d89d9e0) = 0
ioctl(4, SNDRV_PCM_IOCTL_HW_REFINE, 0x7fff5d89d9e0) = 0
ioctl(4, SNDRV_PCM_IOCTL_HW_REFINE, 0x7fff5d89da30) = 0
ioctl(4, SNDRV_PCM_IOCTL_HW_REFINE, 0x7fff5d89da30) = 0
ioctl(4, SNDRV_PCM_IOCTL_HW_REFINE, 0x7fff5d89da30) = 0
ioctl(4, SNDRV_PCM_IOCTL_HW_REFINE, 0x7fff5d89da30) = 0
ioctl(4, SNDRV_PCM_IOCTL_HW_REFINE, 0x7fff5d89d630) = 0
ioctl(4, SNDRV_PCM_IOCTL_HW_REFINE, 0x7fff5d89d610) = 0
ioctl(4, SNDRV_PCM_IOCTL_HW_PARAMS, 0x7fff5d89d610) = 0
ioctl(4, SNDRV_PCM_IOCTL_SW_PARAMS, 0x7fff5d89d550) = 0
ioctl(4, SNDRV_PCM_IOCTL_CHANNEL_INFO, 0x7fff5d89d4b0) = 0
ioctl(4, SNDRV_PCM_IOCTL_CHANNEL_INFO, 0x7fff5d89d4b0) = 0
mmap(NULL, 65536, PROT_READ|PROT_WRITE, MAP_SHARED, 4, 0) = 0x7f508ca61000
ioctl(4, SNDRV_PCM_IOCTL_PREPARE, 0x1000) = 0
ioctl(4, SNDRV_PCM_IOCTL_SW_PARAMS, 0x7fff5d89ddd0) = 0
read(3, "\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0"..., 8192) = 8192
read(3, "\20#\233!\240 \336\37\244\36c\35\206\34\241\33g\32\305\30\4\27\276\25\362\24$\24\25\23\3\22"..., 8192) = 8192
read(3, "E\0\266\0\0\1\354\0\251\0W\0\267\377\327\376\303\375O\374\301\372:\371y\367\241\365,\364g\363"..., 8192) = 8192
read(3, "|\356J\357\355\357\265\360\215\361Z\362D\363'\364\356\364\305\365\253\366\222\367w\370Y\371I\3726\373"..., 8192) = 8192
ioctl(4, SNDRV_PCM_IOCTL_START, 0x1000) = 0
read(3, "\225\377\221\377\221\377\202\377\200\377\223\377\234\377\236\377\235\377\227\377\221\377\210\377\205\377\222\377\233\377\234\377"..., 8192) = 8192
ioctl(4, SNDRV_PCM_IOCTL_HWSYNC, 0)     = 0
poll([{fd=4, events=POLLOUT|POLLERR|POLLNVAL}], 1, 4294967295^CProcess 1491 detached
 <detached ...>
Aborted by signal Interrupt...
aplay: pcm_write:1939: write error: Interrupted system call

/dev/snd/pcmC0D8pにioctlしてからpollしてるところで反応が返ってこなくなってた。
xenがなんかやっちゃってるのかなー。