1. 01 8月, 2008 1 次提交
  2. 30 7月, 2008 1 次提交
    • P
      ALSA: Fix limit of 8 PCM devices in SNDRV_CTL_IOCTL_PCM_NEXT_DEVICE · 94239690
      Pawel MOLL 提交于
      When compiled with CONFIG_SND_DYNAMIC_MINORS the ALSA core is fine
      to have more than 8 PCM devices per card, except one place - the
      SNDRV_CTL_IOCTL_PCM_NEXT_DEVICE ioctl, which will not enumerate
      devices > 7. This patch fixes the issue, changing the devices list
      organisation.
      
      Instead of adding new device to the tail, the list is now kept always
      ordered (by card number, then device number). Thus, during enumeration,
      it is easy to discover the fact that there is no more given card's
      devices. The same limit was present in OSS emulation code. It has
      been fixed as well.
      
      Additionally the device field of struct snd_pcm is now int, instead of
      unsigned int, as there is no obvious reason for keeping it unsigned.
      This caused a lot of problems with comparing this value with other
      (almost always signed) variables. There is just one more place where
      device number is unsigned - in struct snd_pcm_info, which should be
      also sorted out in future.
      Signed-off-by: NPawel MOLL <pawel.moll@st.com>
      Signed-off-by: NJaroslav Kysela <perex@perex.cz>
      94239690
  3. 25 9月, 2008 1 次提交
    • T
      ALSA: fix locking in snd_pcm_open*() and snd_rawmidi_open*() · 399ccdc1
      Takashi Iwai 提交于
      The PCM and rawmidi open callbacks have a lock against card->controls_list
      but it takes a wrong one, card->controls_rwsem, instead of a right one
      card->ctl_files_rwlock.  This patch fixes them.
      
      This change also fixes automatically the potential deadlocks due to
      mm->mmap_sem in munmap and copy_from/to_user, reported by Sitsofe
      Wheeler:
      
        A: snd_ctl_elem_user_tlv(): card->controls_rwsem => mm->mmap_sem
        B: snd_pcm_open(): card->open_mutex => card->controls_rwsem
        C: munmap: mm->mmap_sem => snd_pcm_release(): card->open_mutex
      
      The patch breaks the chain.
      Signed-off-by: NTakashi Iwai <tiwai@suse.de>
      399ccdc1
  4. 01 2月, 2008 4 次提交
    • J
      [ALSA] PCM interface - rename SNDRV_PCM_TSTAMP_MMAP to SNDRV_PCM_TSTAMP_ENABLE · 8c121586
      Jaroslav Kysela 提交于
      Change semantics for SNDRV_PCM_TSTAMP_MMAP. Doing timestamping only in
      the interrupt handler might cause that hw_ptr is not related to actual
      timestamp. With this change, grab timestamp at every hw_ptr update to
      have always valid timestamp + ring buffer position pair.
      With this change, SNDRV_PCM_TSTAMP_MMAP was renamed to
      SNDRV_PCM_TSTAMP_ENABLE. It's no regression (I think).
      Signed-off-by: NJaroslav Kysela <perex@perex.cz>
      8c121586
    • T
      [ALSA] Remove sound/driver.h · 9004acc7
      Takashi Iwai 提交于
      This header file exists only for some hacks to adapt alsa-driver
      tree.  It's useless for building in the kernel.  Let's move a few
      lines in it to sound/core.h and remove it.
      With this patch, sound/driver.h isn't removed but has just a single
      compile warning to include it.  This should be really killed in
      future.
      Signed-off-by: NTakashi Iwai <tiwai@suse.de>
      Signed-off-by: NJaroslav Kysela <perex@perex.cz>
      9004acc7
    • T
      [ALSA] Remove PCM sleep_min and tick · 31e8960b
      Takashi Iwai 提交于
      The 'tick' in PCM is set (again) via sw_params.  And, nobody uses
      this feature at all except for a command line option of aplay.
      (This is literally 'nobody', as I checked alsa-lib API calls in all
       programs in major distros.)
      Above all, if we need finer wake-ups for the position update, it's
      basically an issue that the driver should solve, not tuned by each
      application.
      Signed-off-by: NTakashi Iwai <tiwai@suse.de>
      Signed-off-by: NJaroslav Kysela <perex@perex.cz>
      31e8960b
    • T
      [ALSA] Remove PCM xfer_align sw params · d948035a
      Takashi Iwai 提交于
      The xfer_align sw_params parameter has never been used in a sane manner,
      and no one understands what this does exactly.  The current
      implementation looks also buggy because it allows write of shorter size
      than xfer_align.  So, if you do partial writes, the write isn't actually
      aligned at all.
      Removing this parameter will make some pcm_lib_* code more readable
      (and less buggy).
      Signed-off-by: NTakashi Iwai <tiwai@suse.de>
      Signed-off-by: NJaroslav Kysela <perex@perex.cz>
      d948035a
  5. 16 10月, 2007 1 次提交
  6. 09 2月, 2007 3 次提交
  7. 20 12月, 2006 1 次提交
  8. 02 12月, 2006 1 次提交
    • G
      Driver core: convert sound core to use struct device · d80f19fa
      Greg Kroah-Hartman 提交于
      Converts from using struct "class_device" to "struct device" making
      everything show up properly in /sys/devices/ with symlinks from the
      /sys/class directory.
      
      It also makes the struct sound_card to show up as a "real" device
      where all the different sound class devices are placed as childs
      and different card attribute files can hang off of. /sys/class/sound is
      still a flat directory, but the symlink targets of all devices belonging
      to the same card, point the the /sys/devices tree below the new card
      device object.
      
      Thanks to Kay for the updates to this patch.
      Signed-off-by: NKay Sievers <kay.sievers@novell.com>
      Acked-by: NJaroslav Kysela <perex@suse.cz>
      Signed-off-by: NGreg Kroah-Hartman <gregkh@suse.de>
      d80f19fa
  9. 01 10月, 2006 1 次提交
    • T
      [PATCH] maximum latency tracking: ALSA support · 9442e691
      Takashi Iwai 提交于
      Add maximum latency tracking to the ALSA subsystem for PCM playback.  In
      ALSA, the playback application controls the buffer size and thus indirectly
      the period of latency that it can deal with.  This patch uses 75% of the
      total available latency as threshold to announce to the latency subsystem;
      While 75% is a crude heuristic it's a quite reasonable one; the remaining
      25% can be used for all driver processing for the next samples which is
      also proportional to the size of the buffer.
      
      With ogg123 a latency setting of about 4msec was seen (at 44Khz), while
      with the "play" command a much longer maximum tolerable latency was seen.
      Other, more multimedia oriented players as well as games, will have a lot
      smaller buffers to allow better synchronization and those will actually get
      into the latency domains where there is impact on the power management
      rules.
      Signed-off-by: NTakashi Iwai <tiwai@suse.de>
      Signed-off-by: NArjan van de Ven <arjan@linux.intel.com>
      Signed-off-by: NAndrew Morton <akpm@osdl.org>
      Signed-off-by: NLinus Torvalds <torvalds@osdl.org>
      9442e691
  10. 23 9月, 2006 4 次提交
  11. 23 6月, 2006 6 次提交
  12. 28 4月, 2006 2 次提交
  13. 12 4月, 2006 1 次提交
  14. 31 3月, 2006 2 次提交
  15. 22 3月, 2006 3 次提交
  16. 03 1月, 2006 5 次提交
  17. 04 11月, 2005 1 次提交
  18. 12 9月, 2005 1 次提交
  19. 29 5月, 2005 1 次提交