1. 10 5月, 2016 1 次提交
    • T
      ALSA: hda - Fix broken reconfig · addacd80
      Takashi Iwai 提交于
      The HD-audio reconfig function got broken in the recent kernels,
      typically resulting in a failure like:
        snd_hda_intel 0000:00:1b.0: control 3:0:0:Playback Channel Map:0 is already present
      
      This is because of the code restructuring to move the PCM and control
      instantiation into the codec drive probe, by the commit [bcd96557:
      ALSA: hda - Build PCMs and controls at codec driver probe].  Although
      the commit above removed the calls of snd_hda_codec_build_pcms() and
      *_build_controls() at the controller driver probe, the similar calls
      in the reconfig were still left forgotten.  This caused the
      conflicting and duplicated PCMs and controls.
      
      The fix is trivial: just remove these superfluous calls from
      reconfig_codec().
      
      Fixes: bcd96557 ('ALSA: hda - Build PCMs and controls at codec driver probe')
      Reported-by: NJochen Henneberg <jh@henneberg-systemdesign.com>
      Cc: <stable@vger.kernel.org> # v4.1+
      Signed-off-by: NTakashi Iwai <tiwai@suse.de>
      addacd80
  2. 15 10月, 2015 1 次提交
  3. 23 3月, 2015 2 次提交
    • T
      ALSA: hda - Move a part of hda_codec stuff into hdac_device · 7639a06c
      Takashi Iwai 提交于
      Now some codes and functionalities of hda_codec struct are moved to
      hdac_device struct.  A few basic attributes like the codec address,
      vendor ID number, FG numbers, etc are moved to hdac_device, and they
      are accessed like codec->core.addr.  The basic verb exec functions are
      moved, too.
      Signed-off-by: NTakashi Iwai <tiwai@suse.de>
      7639a06c
    • T
      ALSA: hda - Move some codes up to hdac_bus struct · d068ebc2
      Takashi Iwai 提交于
      A few basic codes for communicating over HD-audio bus are moved to
      struct hdac_bus now.  It has only command and get_response ops in
      addition to the unsolicited event handling.
      
      Note that the codec-side tracing support is disabled temporarily
      during this transition due to the code shuffling.  It will be
      re-enabled later once when all pieces are settled down.
      Signed-off-by: NTakashi Iwai <tiwai@suse.de>
      d068ebc2
  4. 03 3月, 2015 1 次提交
  5. 15 12月, 2014 1 次提交
  6. 29 10月, 2014 1 次提交
  7. 17 9月, 2014 1 次提交
    • R
      ALSA: hda - Replace strnicmp with strncasecmp · 8bb1ffdf
      Rasmus Villemoes 提交于
      The kernel used to contain two functions for length-delimited,
      case-insensitive string comparison, strnicmp with correct semantics
      and a slightly buggy strncasecmp. The latter is the POSIX name, so
      strnicmp was renamed to strncasecmp, and strnicmp made into a wrapper
      for the new strncasecmp to avoid breaking existing users.
      
      To allow the compat wrapper strnicmp to be removed at some point in
      the future, and to avoid the extra indirection cost, do
      s/strnicmp/strncasecmp/g.
      Signed-off-by: NRasmus Villemoes <linux@rasmusvillemoes.dk>
      Signed-off-by: NTakashi Iwai <tiwai@suse.de>
      8bb1ffdf
  8. 25 2月, 2014 6 次提交
    • T
      ALSA: hda - Replace with standard printk · 4e76a883
      Takashi Iwai 提交于
      Use dev_err() and co for messages from HD-audio controller and codec
      drivers.  The codec drivers are mostly bound with codec objects, so
      some helper macros, codec_err(), codec_info(), etc, are provided.
      They merely wrap the corresponding dev_xxx().
      
      There are a few places still calling snd_printk() and its variants
      as they are called without the codec or device context.
      Signed-off-by: NTakashi Iwai <tiwai@suse.de>
      4e76a883
    • T
      ALSA: hda - Enable sysfs attributes without CONFIG_SND_HDA_RECONFIG · b989d044
      Takashi Iwai 提交于
      Some sysfs attributes like init_pin_configs or vendor_name are really
      basic and should be available no matter whether the codec driver is
      re-configurable or not.  Put them out of #ifdef
      CONFIG_SND_HDA_RECONFIG and allow the read-only accesses.
      Signed-off-by: NTakashi Iwai <tiwai@suse.de>
      b989d044
    • T
      ALSA: hda - Add sysfs to codec object, too · 648a8d27
      Takashi Iwai 提交于
      We have currently sysfs attributes for each hwdep, but basically these
      should belong to the codec itself, per se.  Let's add them to the
      codec object while keeping them for hwdep as is for compatibility.
      
      While we are at it, split the sysfs-related stuff into a separate
      source file, hda_sysfs.c, and keep only the stuff necessary for hwdep
      in hda_hwdep.c.
      Signed-off-by: NTakashi Iwai <tiwai@suse.de>
      648a8d27
    • T
      ALSA: hda - Create own device struct for each codec · 13aeaf68
      Takashi Iwai 提交于
      As the HD-audio is treated individually in each codec driver, it's
      more convenient to assign an own struct device to each codec object.
      Then we'll be able to use dev_err() more easily for each codec, for
      example.
      
      For achieving it, this patch just creates an object "hdaudioCxDy".
      It belongs to sound class instead of creating a new bus, just for
      simplicity, at this stage.  No pm ops is implemented in the device
      struct level but currently it's merely a container.  The PCM and hwdep
      devices are now children of this codec device.
      Signed-off-by: NTakashi Iwai <tiwai@suse.de>
      13aeaf68
    • T
      ALSA: hwdep: Take private_data as drvdata for sysfs · f806bdb2
      Takashi Iwai 提交于
      For referring to a different object from sysfs ops, take hwdep
      private_data as stored via dev_set_drvdata() at creating the device
      object.  In that way, the same sysfs ops can be used by different
      device types.
      Signed-off-by: NTakashi Iwai <tiwai@suse.de>
      f806bdb2
    • T
      ALSA: Create sysfs attribute files via groups · caa751ba
      Takashi Iwai 提交于
      Instead of calling each time device_create_file(), create the groups
      of sysfs attribute files at once in a normal way.  Add a new helper
      function, snd_get_device(), to return the associated device object,
      so that we can handle the sysfs addition locally.
      
      Since the sysfs file addition is done differently now,
      snd_add_device_sysfs_file() helper function is removed.
      Signed-off-by: NTakashi Iwai <tiwai@suse.de>
      caa751ba
  9. 15 2月, 2014 1 次提交
  10. 08 1月, 2014 2 次提交
  11. 19 12月, 2013 1 次提交
  12. 21 7月, 2013 1 次提交
  13. 12 1月, 2013 2 次提交
  14. 07 12月, 2012 1 次提交
  15. 30 8月, 2012 1 次提交
  16. 09 8月, 2012 1 次提交
  17. 01 11月, 2011 2 次提交
  18. 29 9月, 2011 1 次提交
    • T
      ALSA: hda - Allow patching with any vendor/subsystem ids · ef940b04
      Takashi Iwai 提交于
      In the ugly real world, there area really broken devices that don't set
      codec SSID correctly.  In such a case, the ID can be random, thus the
      patching won't work reliably.
      
      For applying the patch forcibly to such a device, the driver will skip
      the vendor and/or subsystem ID checks when zero or a negative number is
      given in [codec] section.
      Signed-off-by: NTakashi Iwai <tiwai@suse.de>
      ef940b04
  19. 26 7月, 2010 1 次提交
  20. 28 1月, 2010 1 次提交
  21. 27 12月, 2009 1 次提交
  22. 16 12月, 2009 1 次提交
    • A
      tree-wide: convert open calls to remove spaces to skip_spaces() lib function · e7d2860b
      André Goddard Rosa 提交于
      Makes use of skip_spaces() defined in lib/string.c for removing leading
      spaces from strings all over the tree.
      
      It decreases lib.a code size by 47 bytes and reuses the function tree-wide:
         text    data     bss     dec     hex filename
        64688     584     592   65864   10148 (TOTALS-BEFORE)
        64641     584     592   65817   10119 (TOTALS-AFTER)
      
      Also, while at it, if we see (*str && isspace(*str)), we can be sure to
      remove the first condition (*str) as the second one (isspace(*str)) also
      evaluates to 0 whenever *str == 0, making it redundant. In other words,
      "a char equals zero is never a space".
      
      Julia Lawall tried the semantic patch (http://coccinelle.lip6.fr) below,
      and found occurrences of this pattern on 3 more files:
          drivers/leds/led-class.c
          drivers/leds/ledtrig-timer.c
          drivers/video/output.c
      
      @@
      expression str;
      @@
      
      ( // ignore skip_spaces cases
      while (*str &&  isspace(*str)) { \(str++;\|++str;\) }
      |
      - *str &&
      isspace(*str)
      )
      Signed-off-by: NAndré Goddard Rosa <andre.goddard@gmail.com>
      Cc: Julia Lawall <julia@diku.dk>
      Cc: Martin Schwidefsky <schwidefsky@de.ibm.com>
      Cc: Jeff Dike <jdike@addtoit.com>
      Cc: Ingo Molnar <mingo@elte.hu>
      Cc: Thomas Gleixner <tglx@linutronix.de>
      Cc: "H. Peter Anvin" <hpa@zytor.com>
      Cc: Richard Purdie <rpurdie@rpsys.net>
      Cc: Neil Brown <neilb@suse.de>
      Cc: Kyle McMartin <kyle@mcmartin.ca>
      Cc: Henrique de Moraes Holschuh <hmh@hmh.eng.br>
      Cc: David Howells <dhowells@redhat.com>
      Cc: <linux-ext4@vger.kernel.org>
      Cc: Samuel Ortiz <samuel@sortiz.org>
      Cc: Patrick McHardy <kaber@trash.net>
      Cc: Takashi Iwai <tiwai@suse.de>
      Signed-off-by: NAndrew Morton <akpm@linux-foundation.org>
      Signed-off-by: NLinus Torvalds <torvalds@linux-foundation.org>
      e7d2860b
  23. 11 11月, 2009 1 次提交
    • T
      ALSA: hda - Add power on/off counter · a2f6309e
      Takashi Iwai 提交于
      Added the power on/off counter and expose via sysfs files.
      The sysfs files, power_on_acct and power_off_acct, are created under
      each codec hwdep sysfs directory (e.g. /sys/class/sound/hwC0D0).
      The files show the msec length of the codec power-on and power-off,
      respectively.
      Signed-off-by: NTakashi Iwai <tiwai@suse.de>
      a2f6309e
  24. 24 6月, 2009 1 次提交
    • T
      ALSA: hda - Add patch module option · 4ea6fbc8
      Takashi Iwai 提交于
      Added the patch module option to apply a "patch" as a firmware to
      modify pin configurations or give additional hints to the driver
      before actually initializing and configuring the codec.
      
      This can be used as a workaround when the BIOS doesn't give sufficient
      information or give wrong information that doesn't match with the real
      hardware setup, until it's fixed statically in the driver via a quirk.
      Signed-off-by: NTakashi Iwai <tiwai@suse.de>
      4ea6fbc8
  25. 16 5月, 2009 1 次提交
  26. 13 3月, 2009 1 次提交
  27. 03 3月, 2009 2 次提交
  28. 23 2月, 2009 2 次提交
  29. 20 2月, 2009 1 次提交