--- /dev/null
+diff -ur alsa-lib-1.0.28_/src/pcm/pcm_hw.c alsa-lib-1.0.28/src/pcm/pcm_hw.c
+--- alsa-lib-1.0.28_/src/pcm/pcm_hw.c 2014-09-14 21:59:36.900376006 +0300
++++ alsa-lib-1.0.28/src/pcm/pcm_hw.c 2014-09-14 22:01:22.406922865 +0300
+@@ -1285,6 +1285,76 @@
+ }
+ }
+
++/* pandora hack */
++#include "pcm_generic.h"
++
++/* can't #include "pcm_direct.h" :( */
++#define DIRECT_IPC_SEMS 1
++
++struct snd_pcm_direct {
++ snd_pcm_type_t type; /* type (dmix, dsnoop, dshare) */
++ key_t ipc_key; /* IPC key for semaphore and memory */
++ mode_t ipc_perm; /* IPC socket permissions */
++ int ipc_gid; /* IPC socket gid */
++ int semid; /* IPC global semaphore identification */
++ int locked[DIRECT_IPC_SEMS]; /* local lock counter */
++ int shmid; /* IPC global shared memory identification */
++ void *shmptr; /* pointer to shared memory area */
++ snd_pcm_t *spcm; /* slave PCM handle */
++ /* ... */
++};
++
++struct snd_pnd_hack_params {
++ unsigned int frames_min;
++ unsigned int frames_max;
++ unsigned int reserved[14];
++};
++
++int snd_pcm_hw_set_hack_params(snd_pcm_t *pcm, unsigned int frames_min, unsigned int frames_max)
++{
++ struct snd_pnd_hack_params pnd_hack_params;
++ snd_pcm_hw_t *hw;
++ int fd;
++ int err;
++
++ if (pcm == NULL)
++ return -EINVAL;
++
++ while (pcm->type != SND_PCM_TYPE_HW) {
++ snd_pcm_generic_t *gen;
++ struct snd_pcm_direct *direct;
++
++ // printf("name: '%s' %d\n", pcm->name, (int)pcm->type);
++ switch (pcm->type) {
++ case SND_PCM_TYPE_PLUG:
++ case SND_PCM_TYPE_SOFTVOL:
++ gen = pcm->private_data;
++ pcm = gen->slave;
++ break;
++ case SND_PCM_TYPE_DMIX:
++ direct = pcm->private_data;
++ pcm = direct->spcm;
++ break;
++ default:
++ SNDERR("can't handle pcm type %d", (int)pcm->type);
++ return -EINVAL;
++ }
++ }
++
++ hw = pcm->private_data;
++ fd = hw->fd;
++
++ if (frames_min == 0 || frames_min > frames_max)
++ return -EINVAL;
++
++ memset(&pnd_hack_params, 0, sizeof(pnd_hack_params));
++ pnd_hack_params.frames_min = frames_min;
++ pnd_hack_params.frames_max = frames_max;
++
++ err = ioctl(fd, _IOW('A', 0xfe, struct snd_pnd_hack_params), &pnd_hack_params);
++ return err >= 0 ? err : -errno;
++}
++
+ static const snd_pcm_ops_t snd_pcm_hw_ops = {
+ .close = snd_pcm_hw_close,
+ .info = snd_pcm_hw_info,
SUMMARY = "ALSA sound library"
+DESCRIPTION = "ALSA sound library"
HOMEPAGE = "http://www.alsa-project.org"
BUGTRACKER = "https://bugtrack.alsa-project.org/alsa-bug/login_page.php"
SECTION = "libs/multimedia"
-LICENSE = "LGPLv2.1 & GPLv2+"
+LICENSE = "LGPLv2.1 GPLv2+"
LIC_FILES_CHKSUM = "file://COPYING;md5=7fbc338309ac38fefcd64b04bb903e34 \
file://src/socket.c;beginline=1;endline=26;md5=11ff89a8a7a4a690a5c78effe8159545"
ARM_INSTRUCTION_SET = "arm"
SRC_URI = "ftp://ftp.alsa-project.org/pub/lib/${BP}.tar.bz2 \
- file://Check-if-wordexp-function-is-supported.patch \
- file://fix-tstamp-declaration.patch \
- file://0001-pcm-route-Use-get32-for-multi-source-route-calculati.patch \
- file://0001-pcm-rate-fix-hw_ptr-exceed-the-boundary.patch \
- file://0001-pcm-pcm_local.h-include-time.h-to-enable-CLOCK_MONOT.patch \
+ file://Check-if-wordexp-function-is-supported.patch;patch=1 \
+ file://fix-tstamp-declaration.patch;patch=1 \
+ file://0001-pcm-route-Use-get32-for-multi-source-route-calculati.patch;patch=1 \
+ file://0001-pcm-rate-fix-hw_ptr-exceed-the-boundary.patch;patch=1 \
+ file://0001-pcm-pcm_local.h-include-time.h-to-enable-CLOCK_MONOT.patch;patch=1 \
+ file://neon_mixer.patch;patch=1 \
+ file://pandora_hack_params.patch;patch=1 \
"
SRC_URI[md5sum] = "c9e21b88a2b3e6e12ea7ba0f3b271fc3"
SRC_URI[sha256sum] = "3c074b85dde1b30e78ef4995579765833e5b693fbbd8f834c335e080cb734a6d"
${datadir}/alsa/pcm/dmix.conf \
${datadir}/alsa/pcm/dsnoop.conf"
-RDEPENDS_libasound = "alsa-conf-base alsa-conf"
+#RDEPENDS_libasound = "alsa-conf-base alsa-conf"
+RDEPENDS_libasound = "alsa-conf-base"
# upgrade path
RPROVIDES_${PN}-dev = "alsa-dev"
RREPLACES_${PN}-dev = "alsa-dev"